Skip to content

Commit

Permalink
Fix calling setupOldUpgradeableVersionHardhat
Browse files Browse the repository at this point in the history
  • Loading branch information
area committed Aug 30, 2024
1 parent aaa0de3 commit d4d4f6b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
8 changes: 5 additions & 3 deletions scripts/setupOldUpgradeableVersionHardhat.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
const Resolver = artifacts.require("./Resolver");
const { setupEtherRouter } = require("../helpers/upgradable-contracts");

module.exports = async (callback) => {
async function main() {
const interfaceName = process.env.INTERFACE_NAME;
const implementationNames = process.env.IMPLEMENTATION_NAMES.split(",");
const implementations = implementationNames.map((x) => artifacts.require(x));
Expand All @@ -23,5 +23,7 @@ module.exports = async (callback) => {

await setupEtherRouter("colony", interfaceName, deployedImplementations, resolver);
console.log(resolver.address); // This returns the address to the caller
callback();
};
process.exit(0);
}

main();
9 changes: 8 additions & 1 deletion test/extensions/one-tx-payment.js
Original file line number Diff line number Diff line change
Expand Up @@ -630,11 +630,18 @@ contract("One transaction payments", (accounts) => {
it.only("can call getDomain() without an error", async () => {
await colony.uninstallExtension(ONE_TX_PAYMENT);
await colony.installExtension(ONE_TX_PAYMENT, 6);
const oneTxPaymentAddress = await colonyNetwork.getExtensionInstallation(ONE_TX_PAYMENT, colony.address);
oneTxPayment = await OneTxPayment.at(oneTxPaymentAddress);

await colony.setUserRoles(1, UINT256_MAX, oneTxPayment.address, 1, ROLES);
await token.mint(colony.address, INITIAL_FUNDING);
await colony.claimColonyFunds(token.address);

await colony.upgrade(14);
await colony.upgrade(15);
await colony.upgrade(16);

await oneTxPayment.makePaymentFundedFromDomain(1, UINT256_MAX, 1, UINT256_MAX, [USER1], [token.address], [10], 1, localSkillId);
await oneTxPayment.makePaymentFundedFromDomain(1, UINT256_MAX, 1, UINT256_MAX, [USER1], [token.address], [10], 1, 0);
});
});
});

0 comments on commit d4d4f6b

Please sign in to comment.