aboutsummaryrefslogtreecommitdiffstats
path: root/contracts
diff options
context:
space:
mode:
authorJeff Prestes <jeffprestes@gmail.com>2018-08-15 15:15:42 +0800
committerPéter Szilágyi <peterke@gmail.com>2018-08-15 15:15:42 +0800
commit212bba47ff13812ddabb642da463e58cda4ff20f (patch)
tree229ddaf6591d031b782e692fb75ce6bc35dd225d /contracts
parentb52bb31b767a3e31266e6138e24f7226ebbd8882 (diff)
downloadgo-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.tar
go-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.tar.gz
go-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.tar.bz2
go-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.tar.lz
go-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.tar.xz
go-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.tar.zst
go-tangerine-212bba47ff13812ddabb642da463e58cda4ff20f.zip
backends: configurable gas limit to allow testing large contracts (#17358)
* backends: increase gaslimit in order to allow tests of large contracts * backends: increase gaslimit in order to allow tests of large contracts * backends: increase gaslimit in order to allow tests of large contracts
Diffstat (limited to 'contracts')
-rw-r--r--contracts/chequebook/cheque_test.go2
-rw-r--r--contracts/chequebook/gencode.go2
-rw-r--r--contracts/ens/ens_test.go2
3 files changed, 3 insertions, 3 deletions
diff --git a/contracts/chequebook/cheque_test.go b/contracts/chequebook/cheque_test.go
index 6b6b28e65..4bd2e176b 100644
--- a/contracts/chequebook/cheque_test.go
+++ b/contracts/chequebook/cheque_test.go
@@ -46,7 +46,7 @@ func newTestBackend() *backends.SimulatedBackend {
addr0: {Balance: big.NewInt(1000000000)},
addr1: {Balance: big.NewInt(1000000000)},
addr2: {Balance: big.NewInt(1000000000)},
- })
+ }, 10000000)
}
func deploy(prvKey *ecdsa.PrivateKey, amount *big.Int, backend *backends.SimulatedBackend) (common.Address, error) {
diff --git a/contracts/chequebook/gencode.go b/contracts/chequebook/gencode.go
index 45f6d68f3..ddfe8d151 100644
--- a/contracts/chequebook/gencode.go
+++ b/contracts/chequebook/gencode.go
@@ -40,7 +40,7 @@ var (
)
func main() {
- backend := backends.NewSimulatedBackend(testAlloc)
+ backend := backends.NewSimulatedBackend(testAlloc, uint64(100000000))
auth := bind.NewKeyedTransactor(testKey)
// Deploy the contract, get the code.
diff --git a/contracts/ens/ens_test.go b/contracts/ens/ens_test.go
index 6ad844708..411b04197 100644
--- a/contracts/ens/ens_test.go
+++ b/contracts/ens/ens_test.go
@@ -35,7 +35,7 @@ var (
)
func TestENS(t *testing.T) {
- contractBackend := backends.NewSimulatedBackend(core.GenesisAlloc{addr: {Balance: big.NewInt(1000000000)}})
+ contractBackend := backends.NewSimulatedBackend(core.GenesisAlloc{addr: {Balance: big.NewInt(1000000000)}}, 10000000)
transactOpts := bind.NewKeyedTransactor(key)
ensAddr, ens, err := DeployENS(transactOpts, contractBackend)