Add no-op test
This commit is contained in:
		@@ -144,7 +144,9 @@ export class ExchangeWrapper extends ContractWrapper {
 | 
			
		||||
     */
 | 
			
		||||
    public async batchFillOrderAsync(orderFillRequests: OrderFillRequest[],
 | 
			
		||||
                                     shouldCheckTransfer: boolean, takerAddress: string): Promise<void> {
 | 
			
		||||
        assert.assert(!_.isEmpty(orderFillRequests), 'Cannot fill an empty batch');
 | 
			
		||||
        if (_.isEmpty(orderFillRequests)) {
 | 
			
		||||
            return;
 | 
			
		||||
        }
 | 
			
		||||
        assert.isBoolean('shouldCheckTransfer', shouldCheckTransfer);
 | 
			
		||||
        await assert.isSenderAddressAsync('takerAddress', takerAddress, this.web3Wrapper);
 | 
			
		||||
        _.forEach(orderFillRequests,
 | 
			
		||||
 
 | 
			
		||||
@@ -347,11 +347,11 @@ describe('ExchangeWrapper', () => {
 | 
			
		||||
                        takerTokenFillAmount: fillTakerAmount,
 | 
			
		||||
                    },
 | 
			
		||||
                ];
 | 
			
		||||
            });
 | 
			
		||||
            describe('failed batch fills', () => {
 | 
			
		||||
 | 
			
		||||
            });
 | 
			
		||||
            describe('successful batch fills', () => {
 | 
			
		||||
                it('should no-op for an empty batch', async () => {
 | 
			
		||||
                    await zeroEx.exchange.batchFillOrderAsync([], shouldCheckTransfer, takerAddress);
 | 
			
		||||
                });
 | 
			
		||||
                it('should successfully fill multiple orders', async () => {
 | 
			
		||||
                    await zeroEx.exchange.batchFillOrderAsync(orderFillBatch, shouldCheckTransfer, takerAddress);
 | 
			
		||||
                    const filledAmount = await zeroEx.exchange.getFilledTakerAmountAsync(signedOrderHashHex);
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user