diff options
author | Brandon Millman <brandon.millman@gmail.com> | 2018-08-10 06:54:17 +0800 |
---|---|---|
committer | Brandon Millman <brandon.millman@gmail.com> | 2018-08-10 07:12:42 +0800 |
commit | cbe639866ec9d6088cc7aa133033d2735524c5a0 (patch) | |
tree | 31dcd5fb2a73d4d6ce33f0c4d495625d53ef7e58 /packages/order-utils/test | |
parent | fcd57d2743e4b6a1363b8071696147a91d2afb00 (diff) | |
download | dexon-0x-contracts-cbe639866ec9d6088cc7aa133033d2735524c5a0.tar.gz dexon-0x-contracts-cbe639866ec9d6088cc7aa133033d2735524c5a0.tar.zst dexon-0x-contracts-cbe639866ec9d6088cc7aa133033d2735524c5a0.zip |
Make feeRate optional with a default of 0
Diffstat (limited to 'packages/order-utils/test')
-rw-r--r-- | packages/order-utils/test/rate_utils_test.ts | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/packages/order-utils/test/rate_utils_test.ts b/packages/order-utils/test/rate_utils_test.ts index 2f321a7db..167a40465 100644 --- a/packages/order-utils/test/rate_utils_test.ts +++ b/packages/order-utils/test/rate_utils_test.ts @@ -17,16 +17,10 @@ describe('rateUtils', () => { takerFee: new BigNumber(20), }); describe('#getFeeAdjustedRateOfOrder', () => { - it('throws when feeRate is zero', async () => { - const feeRate = constants.ZERO_AMOUNT; - expect(() => rateUtils.getFeeAdjustedRateOfOrder(testOrder, feeRate)).to.throw( - 'Expected feeRate: 0 to be greater than 0', - ); - }); it('throws when feeRate is less than zero', async () => { const feeRate = new BigNumber(-1); expect(() => rateUtils.getFeeAdjustedRateOfOrder(testOrder, feeRate)).to.throw( - 'Expected feeRate: -1 to be greater than 0', + 'Expected feeRate: -1 to be greater than or equal to 0', ); }); it('correctly calculates fee adjusted rate', async () => { |