aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contract-wrappers/test
diff options
context:
space:
mode:
Diffstat (limited to 'packages/contract-wrappers/test')
-rw-r--r--packages/contract-wrappers/test/calldata_optimization_utils_test.ts (renamed from packages/contract-wrappers/test/market_orders_optimization_utils_test.ts)16
1 files changed, 8 insertions, 8 deletions
diff --git a/packages/contract-wrappers/test/market_orders_optimization_utils_test.ts b/packages/contract-wrappers/test/calldata_optimization_utils_test.ts
index 742294df2..107d913ba 100644
--- a/packages/contract-wrappers/test/market_orders_optimization_utils_test.ts
+++ b/packages/contract-wrappers/test/calldata_optimization_utils_test.ts
@@ -4,7 +4,7 @@ import * as _ from 'lodash';
import 'mocha';
import { constants } from '../src/utils/constants';
-import { marketOrdersOptimizationUtils } from '../src/utils/market_orders_optimization_utils';
+import { calldataOptimizationUtils } from '../src/utils/calldata_optimization_utils';
import { chaiSetup } from './utils/chai_setup';
import { assert } from '../src/utils/assert';
@@ -37,29 +37,29 @@ const generateFakeOrders = (makerAssetData: string, takerAssetData: string) =>
};
});
-describe('marketOrdersOptimizationUtils', () => {
+describe('calldataOptimizationUtils', () => {
const fakeMakerAssetData = 'fakeMakerAssetData';
const fakeTakerAssetData = 'fakeTakerAssetData';
const orders = generateFakeOrders(fakeMakerAssetData, fakeTakerAssetData);
- describe('#optimizeMarketOrders', () => {
+ describe('#optimizeForwarderOrders', () => {
it('should make makerAssetData `0x` unless first order', () => {
- const optimizedOrders = marketOrdersOptimizationUtils.optimizeMarketOrders(orders);
+ const optimizedOrders = calldataOptimizationUtils.optimizeForwarderOrders(orders);
expect(optimizedOrders[0].makerAssetData).to.equal(fakeMakerAssetData);
const ordersWithoutHead = _.slice(optimizedOrders, 1);
_.forEach(ordersWithoutHead, order => expect(order.makerAssetData).to.equal(constants.NULL_BYTES));
});
it('should make all takerAssetData `0x`', () => {
- const optimizedOrders = marketOrdersOptimizationUtils.optimizeMarketOrders(orders);
+ const optimizedOrders = calldataOptimizationUtils.optimizeForwarderOrders(orders);
_.forEach(optimizedOrders, order => expect(order.takerAssetData).to.equal(constants.NULL_BYTES));
});
});
- describe('#optimizeFeeOrders', () => {
+ describe('#optimizeForwarderFeeOrders', () => {
it('should make all makerAssetData `0x`', () => {
- const optimizedOrders = marketOrdersOptimizationUtils.optimizeFeeOrders(orders);
+ const optimizedOrders = calldataOptimizationUtils.optimizeForwarderFeeOrders(orders);
_.forEach(optimizedOrders, order => expect(order.makerAssetData).to.equal(constants.NULL_BYTES));
});
it('should make all takerAssetData `0x`', () => {
- const optimizedOrders = marketOrdersOptimizationUtils.optimizeFeeOrders(orders);
+ const optimizedOrders = calldataOptimizationUtils.optimizeForwarderFeeOrders(orders);
_.forEach(optimizedOrders, order => expect(order.takerAssetData).to.equal(constants.NULL_BYTES));
});
});