Skip to content

Commit

Permalink
hot-fix for PY-tests, fixes gas estimation problem on TokenManagerERC…
Browse files Browse the repository at this point in the history
…20 contract deployment in tests
  • Loading branch information
sergiy-skalelabs committed Jan 15, 2024
1 parent 82cdf8f commit 9afb00d
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions proxy/migrations/deploySchain.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,19 +181,6 @@ async function main() {
deployed.set( "TokenManagerEth", { address: tokenManagerEth.address, interface: tokenManagerEth.interface } );
console.log("Contract TokenManagerEth deployed to", tokenManagerEth.address);

console.log("Deploy TokenManagerERC20");
const tokenManagerERC20Factory = await ethers.getContractFactory("TokenManagerERC20");
const tokenManagerERC20 = await upgrades.deployProxy(tokenManagerERC20Factory, [
schainName,
messageProxy.address,
tokenManagerLinker.address,
communityLocker.address,
depositBoxERC20Address
]) as TokenManagerERC20;
await tokenManagerERC20.deployTransaction.wait();
deployed.set( "TokenManagerERC20", { address: tokenManagerERC20.address, interface: tokenManagerERC20.interface } );
console.log("Contract TokenManagerERC20 deployed to", tokenManagerERC20.address);

/*
In the moment of this code was written
ganache had a bug
Expand Down Expand Up @@ -222,6 +209,19 @@ async function main() {
return ethers.BigNumber.from(network.config.gas as number);
}

console.log("Deploy TokenManagerERC20");
const tokenManagerERC20Factory = await ethers.getContractFactory("TokenManagerERC20", signerWithFixedGasEstimation);
const tokenManagerERC20 = await upgrades.deployProxy(tokenManagerERC20Factory, [
schainName,
messageProxy.address,
tokenManagerLinker.address,
communityLocker.address,
depositBoxERC20Address
]) as TokenManagerERC20;
await tokenManagerERC20.deployTransaction.wait();
deployed.set( "TokenManagerERC20", { address: tokenManagerERC20.address, interface: tokenManagerERC20.interface } );
console.log("Contract TokenManagerERC20 deployed to", tokenManagerERC20.address);

// The end of TODO:

console.log("Deploy TokenManagerERC721");
Expand Down

0 comments on commit 9afb00d

Please sign in to comment.