diff --git a/contracts/coordinator/test/coordinator.ts b/contracts/coordinator/test/coordinator.ts index 1fe84e3184..67a4d11379 100644 --- a/contracts/coordinator/test/coordinator.ts +++ b/contracts/coordinator/test/coordinator.ts @@ -113,21 +113,9 @@ describe('Coordinator tests', () => { const takerPrivateKey = devConstants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(takerAddress)]; const feeRecipientPrivateKey = devConstants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(feeRecipientAddress)]; orderFactory = new OrderFactory(makerPrivateKey, defaultOrderParams); - makerTransactionFactory = new TransactionFactory( - makerPrivateKey, - exchange.address, - chainId, - ); - takerTransactionFactory = new TransactionFactory( - takerPrivateKey, - exchange.address, - chainId, - ); - approvalFactory = new ApprovalFactory( - feeRecipientPrivateKey, - coordinatorContract.address, - chainId, - ); + makerTransactionFactory = new TransactionFactory(makerPrivateKey, exchange.address, chainId); + takerTransactionFactory = new TransactionFactory(takerPrivateKey, exchange.address, chainId); + approvalFactory = new ApprovalFactory(feeRecipientPrivateKey, coordinatorContract.address, chainId); }); beforeEach(async () => { await blockchainLifecycle.startAsync(); diff --git a/contracts/coordinator/test/mixins.ts b/contracts/coordinator/test/mixins.ts index 45f7961f1d..35a255c803 100644 --- a/contracts/coordinator/test/mixins.ts +++ b/contracts/coordinator/test/mixins.ts @@ -72,21 +72,9 @@ describe('Mixins tests', () => { devConstants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(transactionSignerAddress)]; const approvalSignerPrivateKey1 = devConstants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(approvalSignerAddress1)]; const approvalSignerPrivateKey2 = devConstants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(approvalSignerAddress2)]; - transactionFactory = new TransactionFactory( - transactionSignerPrivateKey, - exchangeAddress, - chainId, - ); - approvalFactory1 = new ApprovalFactory( - approvalSignerPrivateKey1, - mixins.address, - chainId, - ); - approvalFactory2 = new ApprovalFactory( - approvalSignerPrivateKey2, - mixins.address, - chainId, - ); + transactionFactory = new TransactionFactory(transactionSignerPrivateKey, exchangeAddress, chainId); + approvalFactory1 = new ApprovalFactory(approvalSignerPrivateKey1, mixins.address, chainId); + approvalFactory2 = new ApprovalFactory(approvalSignerPrivateKey2, mixins.address, chainId); }); beforeEach(async () => { await blockchainLifecycle.startAsync(); diff --git a/contracts/coordinator/test/utils/approval_factory.ts b/contracts/coordinator/test/utils/approval_factory.ts index 9e35b81a37..36c90cd356 100644 --- a/contracts/coordinator/test/utils/approval_factory.ts +++ b/contracts/coordinator/test/utils/approval_factory.ts @@ -10,11 +10,7 @@ export class ApprovalFactory { private readonly _verifyingContractAddress: string; private readonly _chainId: number; - constructor( - privateKey: Buffer, - verifyingContractAddress: string, - chainId: number, - ) { + constructor(privateKey: Buffer, verifyingContractAddress: string, chainId: number) { this._privateKey = privateKey; this._verifyingContractAddress = verifyingContractAddress; this._chainId = chainId; diff --git a/contracts/coordinator/test/utils/hash_utils.ts b/contracts/coordinator/test/utils/hash_utils.ts index e16736e70e..7bff7ac257 100644 --- a/contracts/coordinator/test/utils/hash_utils.ts +++ b/contracts/coordinator/test/utils/hash_utils.ts @@ -30,7 +30,8 @@ export const hashUtils = { transaction, verifyingContractAddress, txOrigin, - approvalExpirationTimeSeconds) + approvalExpirationTimeSeconds, + ) .toString('hex')}`; return hashHex; }, diff --git a/contracts/exchange-libs/contracts/src/LibConstants.sol b/contracts/exchange-libs/contracts/src/LibConstants.sol index 55c86bf5c8..353a73a15b 100644 --- a/contracts/exchange-libs/contracts/src/LibConstants.sol +++ b/contracts/exchange-libs/contracts/src/LibConstants.sol @@ -38,7 +38,6 @@ contract LibConstants { bytes public ZRX_ASSET_DATA; - /// @param zrxAssetData Asset data for ZRX token. Used for fee transfers. constructor (bytes memory zrxAssetData) public diff --git a/contracts/exchange-libs/contracts/src/LibEIP712ExchangeDomain.sol b/contracts/exchange-libs/contracts/src/LibEIP712ExchangeDomain.sol index 219d41a35c..cf44e178d8 100644 --- a/contracts/exchange-libs/contracts/src/LibEIP712ExchangeDomain.sol +++ b/contracts/exchange-libs/contracts/src/LibEIP712ExchangeDomain.sol @@ -40,7 +40,6 @@ contract LibEIP712ExchangeDomain is ); } - /// @dev Calculates EIP712 encoding for a hash struct in the EIP712 domain /// of the Exchange contract. /// @param hashStruct The EIP712 hash struct. diff --git a/contracts/exchange-libs/contracts/test/TestLibs.sol b/contracts/exchange-libs/contracts/test/TestLibs.sol index 6fb32cc67d..c26311d0e5 100644 --- a/contracts/exchange-libs/contracts/test/TestLibs.sol +++ b/contracts/exchange-libs/contracts/test/TestLibs.sol @@ -26,6 +26,7 @@ import "../src/LibFillResults.sol"; import "../src/LibAbiEncoder.sol"; +// solhint-disable no-empty-blocks contract TestLibs is LibEIP712, LibMath, diff --git a/contracts/exchange/contracts/src/MixinTransactions.sol b/contracts/exchange/contracts/src/MixinTransactions.sol index dc050a8bd9..ded04220ae 100644 --- a/contracts/exchange/contracts/src/MixinTransactions.sol +++ b/contracts/exchange/contracts/src/MixinTransactions.sol @@ -62,8 +62,7 @@ contract MixinTransactions is salt, signerAddress, data - ) - ); + )); // Validate transaction has not been executed require( diff --git a/contracts/exchange/contracts/test/TestSignatureValidator.sol b/contracts/exchange/contracts/test/TestSignatureValidator.sol index 44ba36cf9f..b6158e38e9 100644 --- a/contracts/exchange/contracts/test/TestSignatureValidator.sol +++ b/contracts/exchange/contracts/test/TestSignatureValidator.sol @@ -29,6 +29,7 @@ contract TestSignatureValidator is MixinTransactions { + // solhint-disable no-empty-blocks constructor (uint256 chainId) public LibEIP712(chainId) diff --git a/contracts/exchange/test/match_orders.ts b/contracts/exchange/test/match_orders.ts index d6a25df97a..e221e2888b 100644 --- a/contracts/exchange/test/match_orders.ts +++ b/contracts/exchange/test/match_orders.ts @@ -122,7 +122,7 @@ describe('matchOrders', () => { provider, txDefaults, assetDataUtils.encodeERC20AssetData(zrxToken.address), - new BigNumber(chainId) + new BigNumber(chainId), ); exchangeWrapper = new ExchangeWrapper(exchange, provider); await exchangeWrapper.registerAssetProxyAsync(erc20Proxy.address, owner); diff --git a/contracts/exchange/test/transactions.ts b/contracts/exchange/test/transactions.ts index 784e640a7f..0c12451e22 100644 --- a/contracts/exchange/test/transactions.ts +++ b/contracts/exchange/test/transactions.ts @@ -90,7 +90,7 @@ describe('Exchange transactions', () => { provider, txDefaults, assetDataUtils.encodeERC20AssetData(zrxToken.address), - new BigNumber(chainId) + new BigNumber(chainId), ); exchangeWrapper = new ExchangeWrapper(exchange, provider); await exchangeWrapper.registerAssetProxyAsync(erc20Proxy.address, owner); @@ -116,16 +116,8 @@ describe('Exchange transactions', () => { makerPrivateKey = constants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(makerAddress)]; takerPrivateKey = constants.TESTRPC_PRIVATE_KEYS[accounts.indexOf(takerAddress)]; orderFactory = new OrderFactory(makerPrivateKey, defaultOrderParams); - makerTransactionFactory = new TransactionFactory( - makerPrivateKey, - exchange.address, - chainId, - ); - takerTransactionFactory = new TransactionFactory( - takerPrivateKey, - exchange.address, - chainId, - ); + makerTransactionFactory = new TransactionFactory(makerPrivateKey, exchange.address, chainId); + takerTransactionFactory = new TransactionFactory(takerPrivateKey, exchange.address, chainId); }); describe('executeTransaction', () => { describe('fillOrder', () => { diff --git a/contracts/exchange/test/utils/fill_order_combinatorial_utils.ts b/contracts/exchange/test/utils/fill_order_combinatorial_utils.ts index d5e1c912e3..971eba936c 100644 --- a/contracts/exchange/test/utils/fill_order_combinatorial_utils.ts +++ b/contracts/exchange/test/utils/fill_order_combinatorial_utils.ts @@ -103,7 +103,7 @@ export async function fillOrderCombinatorialUtilsFactoryAsync( provider, txDefaults, zrxAssetData, - new BigNumber(chainId) + new BigNumber(chainId), ); const exchangeWrapper = new ExchangeWrapper(exchangeContract, provider); await exchangeWrapper.registerAssetProxyAsync(erc20Proxy.address, ownerAddress); @@ -131,7 +131,7 @@ export async function fillOrderCombinatorialUtilsFactoryAsync( erc721Token, erc721Balances, exchangeContract.address, - chainId + chainId, ); const testLibsContract = await TestLibsContract.deployFrom0xArtifactAsync( diff --git a/contracts/exchange/test/utils/order_factory_from_scenario.ts b/contracts/exchange/test/utils/order_factory_from_scenario.ts index 4417f71a7f..a7c216e62d 100644 --- a/contracts/exchange/test/utils/order_factory_from_scenario.ts +++ b/contracts/exchange/test/utils/order_factory_from_scenario.ts @@ -42,7 +42,7 @@ export class OrderFactoryFromScenario { erc721Token: DummyERC721TokenContract, erc721Balances: ERC721TokenIdsByOwner, exchangeAddress: string, - chainId: number + chainId: number, ) { this._userAddresses = userAddresses; this._zrxAddress = zrxAddress; diff --git a/contracts/exchange/test/wrapper.ts b/contracts/exchange/test/wrapper.ts index ecfa568db5..6e6052f11c 100644 --- a/contracts/exchange/test/wrapper.ts +++ b/contracts/exchange/test/wrapper.ts @@ -90,7 +90,7 @@ describe('Exchange wrappers', () => { provider, txDefaults, assetDataUtils.encodeERC20AssetData(zrxToken.address), - new BigNumber(chainId) + new BigNumber(chainId), ); exchangeWrapper = new ExchangeWrapper(exchange, provider); await exchangeWrapper.registerAssetProxyAsync(erc20Proxy.address, owner);