Skip to content

Commit 7ededfc

Browse files
committedJun 29, 2023
chore: added faucet to deployment
1 parent 797bd89 commit 7ededfc

File tree

3 files changed

+17
-7
lines changed

3 files changed

+17
-7
lines changed
 

‎contracts/README.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,17 @@ Refresh the list of deployed contracts by running `./scripts/generateDeployments
2929
- [ArbitrableExample](https://goerli.arbiscan.io/address/0xb0338F2E3D832F3086e5681EAD329520A8d88CD6)
3030
- [BlockHashRNG](https://goerli.arbiscan.io/address/0x68eE49dfD9d76f3386257a3D0e0A85c0A5519bBD)
3131
- [DAI](https://goerli.arbiscan.io/address/0x70A704Dce4cCC00568Cc142C86D07Ec71C944a39)
32+
- [DAIFaucet](https://goerli.arbiscan.io/address/0x82C3FF40B0DB79b84bB97Df7792D759bDfAD1eAb)
3233
- [DisputeKitClassic](https://goerli.arbiscan.io/address/0x0245A93ABd9c5b2d767B2D98cE6d5e612208E474)
3334
- [DisputeResolver](https://goerli.arbiscan.io/address/0xcDC05c8d2EEEe384359Bd22E8631528B6b0564e9)
3435
- [HomeGatewayToGnosis](https://goerli.arbiscan.io/address/0x1807b0049D412a3208d840D74725e404a55E297E)
3536
- [KlerosCore](https://goerli.arbiscan.io/address/0x8Af82E2F8890acb4AB84cbaB3c4C4Eb3E965CF24)
37+
- [PNKFaucet](https://goerli.arbiscan.io/address/0xcc9dA0E6Fe98934781A57C861C939AC36989990d)
3638
- [PolicyRegistry](https://goerli.arbiscan.io/address/0xED503aBA65B28D81444294D1eAa5d84CeFdC2C58)
3739
- [RandomizerRNG](https://goerli.arbiscan.io/address/0xa90f7D2e35718FDE9AD96c8B6667AFcAa4BEfd4d)
3840
- [SortitionModule](https://goerli.arbiscan.io/address/0x5Ae75Db8B66B574b2c5C29eE4D32cc9Fe62bfdEE)
3941
- [WETH](https://goerli.arbiscan.io/address/0xddE1b84E43505432Fdf5F810ebB9373dD37e9230)
42+
- [WETHFaucet](https://goerli.arbiscan.io/address/0x87Efe303Cbc866320c14805C4D6cd04f426FBB17)
4043

4144
## Getting Started
4245

@@ -218,6 +221,6 @@ scripts/generateDeploymentArtifact.sh gnosischain 0xf8d1677c8a0c961938bf2f9adc3f
218221
Ensure that your `$TENDERLY_PROJECT` and `$TENDERLY_USERNAME` is set correctly in `.env`.
219222

220223
```bash
221-
yarn hardhat --network goerli tenderly:push
222-
yarn hardhat --network arbitrumGoerli tenderly:push
224+
yarn tenderly-verify --network goerli
225+
yarn tenderly-verify --network arbitrumGoerli
223226
```

‎contracts/deploy/00-home-chain-arbitration.ts

+10-4
Original file line numberDiff line numberDiff line change
@@ -35,15 +35,15 @@ const deployArbitration: DeployFunction = async (hre: HardhatRuntimeEnvironment)
3535
console.log("Deploying to %s with deployer %s", HomeChains[chainId], deployer);
3636

3737
if (!pnkByChain.get(chainId)) {
38-
const erc20Address = await deployERC20(hre, deployer, "PNK");
38+
const erc20Address = await deployERC20AndFaucet(hre, deployer, "PNK");
3939
pnkByChain.set(HomeChains[HomeChains[chainId]], erc20Address);
4040
}
4141
if (!daiByChain.get(chainId)) {
42-
const erc20Address = await deployERC20(hre, deployer, "DAI");
42+
const erc20Address = await deployERC20AndFaucet(hre, deployer, "DAI");
4343
daiByChain.set(HomeChains[HomeChains[chainId]], erc20Address);
4444
}
4545
if (!wethByChain.get(chainId)) {
46-
const erc20Address = await deployERC20(hre, deployer, "WETH");
46+
const erc20Address = await deployERC20AndFaucet(hre, deployer, "WETH");
4747
wethByChain.set(HomeChains[HomeChains[chainId]], erc20Address);
4848
}
4949

@@ -134,14 +134,20 @@ deployArbitration.skip = async ({ getChainId }) => {
134134
return !HomeChains[chainId];
135135
};
136136

137-
const deployERC20 = async (hre: HardhatRuntimeEnvironment, deployer: string, ticker: string) => {
137+
const deployERC20AndFaucet = async (hre: HardhatRuntimeEnvironment, deployer: string, ticker: string) => {
138138
const { deploy } = hre.deployments;
139139
const erc20 = await deploy(ticker, {
140140
from: deployer,
141141
contract: "TestERC20",
142142
args: [ticker, ticker],
143143
log: true,
144144
});
145+
await deploy(`${ticker}Faucet`, {
146+
from: deployer,
147+
contract: "Faucet",
148+
args: [erc20.address],
149+
log: true,
150+
});
145151
console.log("Deployed %s at %s", ticker, erc20.address);
146152
return erc20.address;
147153
};

‎contracts/package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,8 @@
3232
"docgen": "hardhat docgen",
3333
"docserve": "scripts/docPreprocess.sh && forge doc --serve",
3434
"docbuild": "scripts/docPreprocess.sh && forge doc --build --out dist && scripts/docPostprocess.sh",
35-
"publish": "yarn npm publish --access public --tag $(cat package.json | jq .version)"
35+
"publish": "yarn npm publish --access public --tag $(cat package.json | jq .version)",
36+
"tenderly-verify": "hardhat tenderly:verify"
3637
},
3738
"devDependencies": {
3839
"@kleros/kleros-v2-eslint-config": "workspace:^",

0 commit comments

Comments
 (0)