fix deployment_manager_test
This commit is contained in:
parent
7aa88307f6
commit
56f7dd7538
@ -13,15 +13,6 @@ blockchainTests('Deployment Manager', env => {
|
|||||||
deploymentManager = await DeploymentManager.deployAsync(env);
|
deploymentManager = await DeploymentManager.deployAsync(env);
|
||||||
});
|
});
|
||||||
|
|
||||||
async function batchAssertAuthoritiesAsync(
|
|
||||||
authorities: string[],
|
|
||||||
authorizedContracts: Authorizable[],
|
|
||||||
): Promise<void> {
|
|
||||||
for (const authorized of authorizedContracts) {
|
|
||||||
expect(await authorized.getAuthorizedAddresses.callAsync()).to.be.deep.eq(authorities);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
async function batchAssertAuthorizedAsync(
|
async function batchAssertAuthorizedAsync(
|
||||||
authorizedAddress: string,
|
authorizedAddress: string,
|
||||||
authorizedContracts: Authorizable[],
|
authorizedContracts: Authorizable[],
|
||||||
@ -79,14 +70,24 @@ blockchainTests('Deployment Manager', env => {
|
|||||||
|
|
||||||
// The other asset proxies should have the exchange and the multi-asset proxy in their
|
// The other asset proxies should have the exchange and the multi-asset proxy in their
|
||||||
// authorities list.
|
// authorities list.
|
||||||
await batchAssertAuthoritiesAsync(
|
const erc20ProxyAuthorities = await deploymentManager.assetProxies.erc20Proxy.getAuthorizedAddresses.callAsync();
|
||||||
[deploymentManager.assetProxies.multiAssetProxy.address, deploymentManager.exchange.address],
|
expect(erc20ProxyAuthorities).to.deep.eq([
|
||||||
[
|
deploymentManager.staking.zrxVault.address,
|
||||||
deploymentManager.assetProxies.erc1155Proxy,
|
deploymentManager.assetProxies.multiAssetProxy.address,
|
||||||
deploymentManager.assetProxies.erc20Proxy,
|
deploymentManager.exchange.address,
|
||||||
deploymentManager.assetProxies.erc721Proxy,
|
]);
|
||||||
],
|
|
||||||
);
|
const erc1155ProxyAuthorities = await deploymentManager.assetProxies.erc1155Proxy.getAuthorizedAddresses.callAsync();
|
||||||
|
expect(erc1155ProxyAuthorities).to.deep.eq([
|
||||||
|
deploymentManager.assetProxies.multiAssetProxy.address,
|
||||||
|
deploymentManager.exchange.address,
|
||||||
|
]);
|
||||||
|
|
||||||
|
const erc721ProxyAuthorities = await deploymentManager.assetProxies.erc721Proxy.getAuthorizedAddresses.callAsync();
|
||||||
|
expect(erc721ProxyAuthorities).to.deep.eq([
|
||||||
|
deploymentManager.assetProxies.multiAssetProxy.address,
|
||||||
|
deploymentManager.exchange.address,
|
||||||
|
]);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -87,7 +87,6 @@ blockchainTests.resets('fillOrder integration tests', env => {
|
|||||||
StakingProxy: deployment.staking.stakingProxy.address,
|
StakingProxy: deployment.staking.stakingProxy.address,
|
||||||
ZrxVault: deployment.staking.zrxVault.address,
|
ZrxVault: deployment.staking.zrxVault.address,
|
||||||
};
|
};
|
||||||
console.log(tokenOwners);
|
|
||||||
const tokenContracts = {
|
const tokenContracts = {
|
||||||
erc20: { makerToken, takerToken, ZRX: deployment.tokens.zrx, WETH: deployment.tokens.weth },
|
erc20: { makerToken, takerToken, ZRX: deployment.tokens.zrx, WETH: deployment.tokens.weth },
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user