From d73fb5a23c0e23eaec90aee0b563c06fa8f380d6 Mon Sep 17 00:00:00 2001 From: Leonid Logvinov Date: Sun, 12 Nov 2017 19:24:58 -0500 Subject: Fix tests --- test/order_state_watcher_test.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/test/order_state_watcher_test.ts b/test/order_state_watcher_test.ts index df007588e..aa387f495 100644 --- a/test/order_state_watcher_test.ts +++ b/test/order_state_watcher_test.ts @@ -94,9 +94,9 @@ describe('OrderStateWatcher', () => { zeroEx.orderStateWatcher.unsubscribe(); }); it('should fail when trying to subscribe twice', async () => { - await zeroEx.orderStateWatcher.subscribe(_.noop); - return expect(zeroEx.orderStateWatcher.subscribe(_.noop)) - .to.be.eventually.rejectedWith(ZeroExError.SubscriptionAlreadyPresent); + zeroEx.orderStateWatcher.subscribe(_.noop); + expect(() => zeroEx.orderStateWatcher.subscribe(_.noop)) + .to.throw(); }); }); describe('tests with cleanup', async () => { @@ -119,7 +119,7 @@ describe('OrderStateWatcher', () => { expect(invalidOrderState.error).to.be.equal(ExchangeContractErrs.InsufficientMakerAllowance); done(); }); - await zeroEx.orderStateWatcher.subscribe(callback); + zeroEx.orderStateWatcher.subscribe(callback); await zeroEx.token.setProxyAllowanceAsync(makerToken.address, maker, new BigNumber(0)); })().catch(done); }); -- cgit v1.2.3