diff options
author | Jacob Evans <jacob@dekz.net> | 2017-11-13 00:28:01 +0800 |
---|---|---|
committer | Jacob Evans <jacob@dekz.net> | 2017-11-13 00:28:01 +0800 |
commit | 3e2a614eb9a4f1219e2f11ea29c8a7cd59dd74dd (patch) | |
tree | 37f4c3dc2344607737e5da3d79ed5cf0c3bb5ffd /test/order_state_watcher_test.ts | |
parent | abb23631df4fd775d2f9c96332e16c0732b2955e (diff) | |
download | dexon-0x-contracts-3e2a614eb9a4f1219e2f11ea29c8a7cd59dd74dd.tar.gz dexon-0x-contracts-3e2a614eb9a4f1219e2f11ea29c8a7cd59dd74dd.tar.zst dexon-0x-contracts-3e2a614eb9a4f1219e2f11ea29c8a7cd59dd74dd.zip |
Calculate the remaining order amount in maker units
Diffstat (limited to 'test/order_state_watcher_test.ts')
-rw-r--r-- | test/order_state_watcher_test.ts | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/order_state_watcher_test.ts b/test/order_state_watcher_test.ts index 3421353e3..039bcef18 100644 --- a/test/order_state_watcher_test.ts +++ b/test/order_state_watcher_test.ts @@ -189,6 +189,8 @@ describe('OrderStateWatcher', () => { expect(validOrderState.orderHash).to.be.equal(orderHash); const orderRelevantState = validOrderState.orderRelevantState; const remainingMakerBalance = makerBalance.sub(fillAmountInBaseUnits); + const remainingFillable = fillableAmount.minus(fillAmountInBaseUnits); + expect(remainingFillable).to.be.bignumber.equal(fillableAmount.minus(fillAmountInBaseUnits)); expect(orderRelevantState.makerBalance).to.be.bignumber.equal(remainingMakerBalance); if (eventCount === 2) { done(); |