forked from DMDcoin/diamond-contracts-core
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- removed support that the DAO could be an EOA.
- refactored deployment to a helper function.
- Loading branch information
1 parent
4f0f579
commit 56f0d14
Showing
3 changed files
with
32 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import { ethers, network, upgrades } from "hardhat"; | ||
|
||
|
||
export const GovernanceAddress = '0xDA0da0da0Da0Da0Da0DA00DA0da0da0DA0DA0dA0'; | ||
|
||
/// deploys the DAO Mock on the predefined address `GovernanceAddress`. | ||
export async function deployDao() { | ||
|
||
// we fake the deployment of a governance contract here. | ||
const DaoMockFactory = await ethers.getContractFactory("DaoMock"); | ||
let deployedDaoMock = await (await DaoMockFactory.deploy()).waitForDeployment(); | ||
let daoMockBytecode = await deployedDaoMock.getDeployedCode(); | ||
|
||
await network.provider.send("hardhat_setCode", [ | ||
GovernanceAddress, | ||
daoMockBytecode!, | ||
]); | ||
} |