Fix tests

This commit is contained in:
Leonid Logvinov
2017-11-27 17:07:37 -06:00
parent e6887dc9d4
commit 0500602ac3
2 changed files with 9 additions and 14 deletions

View File

@@ -184,6 +184,7 @@ describe('ExchangeWrapper', () => {
it('should not validate when orderTransactionOptions specify not to validate', async () => {
return expect(zeroEx.exchange.fillOrKillOrderAsync(signedOrder, emptyFillableAmount, takerAddress, {
shouldValidate: false,
gasLimit: 200000, // If we don't pass this gas estimation will fail
})).to.not.be.rejectedWith(ExchangeContractErrs.OrderFillAmountZero);
});
});
@@ -363,6 +364,7 @@ describe('ExchangeWrapper', () => {
return expect(zeroEx.exchange.batchFillOrdersAsync(
orderFillBatch, shouldThrowOnInsufficientBalanceOrAllowance, takerAddress, {
shouldValidate: false,
gasLimit: 200000, // If we don't pass this gas estimation will fail
})).to.not.be.rejectedWith(ExchangeContractErrs.OrderFillAmountZero);
});
});
@@ -420,6 +422,7 @@ describe('ExchangeWrapper', () => {
return expect(zeroEx.exchange.fillOrdersUpToAsync(
signedOrders, emptyFillUpToAmount, shouldThrowOnInsufficientBalanceOrAllowance, takerAddress, {
shouldValidate: false,
gasLimit: 200000, // If we don't pass this gas estimation will fail
})).to.not.be.rejectedWith(ExchangeContractErrs.OrderFillAmountZero);
});
});
@@ -468,6 +471,7 @@ describe('ExchangeWrapper', () => {
it('should not validate when orderTransactionOptions specify not to validate', async () => {
return expect(zeroEx.exchange.cancelOrderAsync(signedOrder, emptyCancelTakerTokenAmount, {
shouldValidate: false,
gasLimit: 200000, // If we don't pass this gas estimation will fail
})).to.not.be.rejectedWith(ExchangeContractErrs.OrderCancelAmountZero);
});
});
@@ -543,6 +547,7 @@ describe('ExchangeWrapper', () => {
it('should not validate when orderTransactionOptions specify not to validate', async () => {
return expect(zeroEx.exchange.batchCancelOrdersAsync(cancelBatch, {
shouldValidate: false,
gasLimit: 200000, // If we don't pass this gas estimation will fail
})).to.not.be.rejectedWith(ExchangeContractErrs.OrderCancelAmountZero);
});
});