diff options
author | Fabio Berger <me@fabioberger.com> | 2017-06-02 22:36:25 +0800 |
---|---|---|
committer | Fabio Berger <me@fabioberger.com> | 2017-06-02 22:36:25 +0800 |
commit | 53af22a844b5666399c83abfb934ad544a27576f (patch) | |
tree | 699e07e8c18269501750f4e78025f73d63b3af93 /test | |
parent | 563d0ca4a2e278a472c3c40db2ce914df9d83a82 (diff) | |
download | dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.tar dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.tar.gz dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.tar.bz2 dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.tar.lz dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.tar.xz dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.tar.zst dexon-0x-contracts-53af22a844b5666399c83abfb934ad544a27576f.zip |
pass numbers to BigNumber unless it's too big for the number type
Diffstat (limited to 'test')
-rw-r--r-- | test/token_wrapper_test.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/token_wrapper_test.ts b/test/token_wrapper_test.ts index b020caa5b..12ae8655c 100644 --- a/test/token_wrapper_test.ts +++ b/test/token_wrapper_test.ts @@ -161,7 +161,7 @@ describe('TokenWrapper', () => { const expectedAllowanceBeforeAllowanceSet = new BigNumber(0); expect(allowanceBeforeSet).to.be.bignumber.equal(expectedAllowanceBeforeAllowanceSet); - const amountInUnits = new BigNumber('50'); + const amountInUnits = new BigNumber(50); const amountInBaseUnits = ZeroEx.toBaseUnitAmount(amountInUnits, token.decimals); await zeroEx.token.setAllowanceAsync(token.address, ownerAddress, spenderAddress, amountInBaseUnits); @@ -176,7 +176,7 @@ describe('TokenWrapper', () => { const ownerAddress = coinbase; const spenderAddress = addressWithoutFunds; - const amountInUnits = new BigNumber('50'); + const amountInUnits = new BigNumber(50); const amountInBaseUnits = ZeroEx.toBaseUnitAmount(amountInUnits, token.decimals); await zeroEx.token.setAllowanceAsync(token.address, ownerAddress, spenderAddress, amountInBaseUnits); @@ -198,7 +198,7 @@ describe('TokenWrapper', () => { const token = tokens[0]; const ownerAddress = coinbase; - const amountInUnits = new BigNumber('50'); + const amountInUnits = new BigNumber(50); const amountInBaseUnits = ZeroEx.toBaseUnitAmount(amountInUnits, token.decimals); await zeroEx.token.setProxyAllowanceAsync(token.address, ownerAddress, amountInBaseUnits); @@ -216,7 +216,7 @@ describe('TokenWrapper', () => { const expectedAllowanceBeforeAllowanceSet = new BigNumber(0); expect(allowanceBeforeSet).to.be.bignumber.equal(expectedAllowanceBeforeAllowanceSet); - const amountInUnits = new BigNumber('50'); + const amountInUnits = new BigNumber(50); const amountInBaseUnits = ZeroEx.toBaseUnitAmount(amountInUnits, token.decimals); await zeroEx.token.setProxyAllowanceAsync(token.address, ownerAddress, amountInBaseUnits); |