From fd37e88bdbdcc821e4aa734aed6ad1f499b2b3e4 Mon Sep 17 00:00:00 2001 From: Amir Bandeali Date: Mon, 7 Jan 2019 11:11:19 -0800 Subject: Use enums in pipeline --- packages/order-watcher/test/order_watcher_test.ts | 42 +++++++++++------------ 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'packages/order-watcher/test/order_watcher_test.ts') diff --git a/packages/order-watcher/test/order_watcher_test.ts b/packages/order-watcher/test/order_watcher_test.ts index dfa36f2fd..41dc884d5 100644 --- a/packages/order-watcher/test/order_watcher_test.ts +++ b/packages/order-watcher/test/order_watcher_test.ts @@ -859,29 +859,29 @@ describe('OrderWatcher', () => { })().catch(done); }); // TODO(abandeali1): The following test will fail until the MAP has been deployed and activated. - // it('should emit orderStateInvalid when watched order fully filled', (done: DoneCallback) => { - // (async () => { - // signedOrder = await fillScenarios.createFillableSignedOrderAsync( - // makerMultiAssetData, - // takerAssetData, - // makerAddress, - // takerAddress, - // fillableAmount, - // ); - // const orderHash = orderHashUtils.getOrderHashHex(signedOrder); - // await orderWatcher.addOrderAsync(signedOrder); + it.skip('should emit orderStateInvalid when watched order fully filled', (done: DoneCallback) => { + (async () => { + signedOrder = await fillScenarios.createFillableSignedOrderAsync( + makerMultiAssetData, + takerAssetData, + makerAddress, + takerAddress, + fillableAmount, + ); + const orderHash = orderHashUtils.getOrderHashHex(signedOrder); + await orderWatcher.addOrderAsync(signedOrder); - // const callback = callbackErrorReporter.reportNodeCallbackErrors(done)((orderState: OrderState) => { - // expect(orderState.isValid).to.be.false(); - // const invalidOrderState = orderState as OrderStateInvalid; - // expect(invalidOrderState.orderHash).to.be.equal(orderHash); - // expect(invalidOrderState.error).to.be.equal(ExchangeContractErrs.OrderRemainingFillAmountZero); - // }); - // orderWatcher.subscribe(callback); + const callback = callbackErrorReporter.reportNodeCallbackErrors(done)((orderState: OrderState) => { + expect(orderState.isValid).to.be.false(); + const invalidOrderState = orderState as OrderStateInvalid; + expect(invalidOrderState.orderHash).to.be.equal(orderHash); + expect(invalidOrderState.error).to.be.equal(ExchangeContractErrs.OrderRemainingFillAmountZero); + }); + orderWatcher.subscribe(callback); - // await contractWrappers.exchange.fillOrderAsync(signedOrder, fillableAmount, takerAddress); - // })().catch(done); - // }); + await contractWrappers.exchange.fillOrderAsync(signedOrder, fillableAmount, takerAddress); + })().catch(done); + }); }); }); }); // tslint:disable:max-file-line-count -- cgit v1.2.3