diff options
author | Amir Bandeali <abandeali1@gmail.com> | 2017-12-12 14:47:47 +0800 |
---|---|---|
committer | Amir Bandeali <abandeali1@gmail.com> | 2017-12-13 07:05:30 +0800 |
commit | b97f140b78a0420943291af57d122bc90a488112 (patch) | |
tree | 29a3dfac4f8fecddba716171432270bbc53cfff4 /packages/contracts/test/ts/unlimited_allowance_token.ts | |
parent | 1dda4d5f78705d96934a08f00000e9a98a3bbc3d (diff) | |
download | dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.tar dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.tar.gz dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.tar.bz2 dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.tar.lz dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.tar.xz dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.tar.zst dexon-0x-contracts-b97f140b78a0420943291af57d122bc90a488112.zip |
Add gas limits to failing tests
Diffstat (limited to 'packages/contracts/test/ts/unlimited_allowance_token.ts')
-rw-r--r-- | packages/contracts/test/ts/unlimited_allowance_token.ts | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/packages/contracts/test/ts/unlimited_allowance_token.ts b/packages/contracts/test/ts/unlimited_allowance_token.ts index 3b4d2db77..a328563cd 100644 --- a/packages/contracts/test/ts/unlimited_allowance_token.ts +++ b/packages/contracts/test/ts/unlimited_allowance_token.ts @@ -85,7 +85,8 @@ contract('UnlimitedAllowanceToken', (accounts: string[]) => { const amountToTransfer = initOwnerBalance; const initSpenderAllowance = zeroEx.token.UNLIMITED_ALLOWANCE_IN_BASE_UNITS; await zeroEx.token.setAllowanceAsync(tokenAddress, owner, spender, initSpenderAllowance); - await zeroEx.token.transferFromAsync(tokenAddress, owner, spender, spender, amountToTransfer); + await zeroEx.token.transferFromAsync(tokenAddress, owner, spender, spender, amountToTransfer, + {gasLimit: constants.MAX_TOKEN_TRANSFERFROM_GAS}); const newSpenderAllowance = await zeroEx.token.getAllowanceAsync(tokenAddress, owner, spender); expect(initSpenderAllowance).to.be.bignumber.equal(newSpenderAllowance); @@ -96,7 +97,8 @@ contract('UnlimitedAllowanceToken', (accounts: string[]) => { const amountToTransfer = initOwnerBalance; const initSpenderAllowance = initOwnerBalance; await zeroEx.token.setAllowanceAsync(tokenAddress, owner, spender, initSpenderAllowance); - await zeroEx.token.transferFromAsync(tokenAddress, owner, spender, spender, amountToTransfer); + await zeroEx.token.transferFromAsync(tokenAddress, owner, spender, spender, amountToTransfer, + {gasLimit: constants.MAX_TOKEN_TRANSFERFROM_GAS}); const newOwnerBalance = await zeroEx.token.getBalanceAsync(tokenAddress, owner); const newSpenderBalance = await zeroEx.token.getBalanceAsync(tokenAddress, spender); @@ -110,7 +112,8 @@ contract('UnlimitedAllowanceToken', (accounts: string[]) => { const amountToTransfer = initOwnerBalance; const initSpenderAllowance = initOwnerBalance; await zeroEx.token.setAllowanceAsync(tokenAddress, owner, spender, initSpenderAllowance); - await zeroEx.token.transferFromAsync(tokenAddress, owner, spender, spender, amountToTransfer); + await zeroEx.token.transferFromAsync(tokenAddress, owner, spender, spender, amountToTransfer, + {gasLimit: constants.MAX_TOKEN_TRANSFERFROM_GAS}); const newSpenderAllowance = await zeroEx.token.getAllowanceAsync(tokenAddress, owner, spender); expect(newSpenderAllowance).to.be.bignumber.equal(0); |