-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
384 additions
and
140 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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 was deleted.
Oops, something went wrong.
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,47 @@ | ||
import { HardhatUserConfig } from "hardhat/config"; | ||
import "@nomicfoundation/hardhat-toolbox"; | ||
import "@nomicfoundation/hardhat-foundry"; | ||
import "@openzeppelin/hardhat-upgrades"; | ||
import dotenv from "dotenv"; | ||
|
||
dotenv.config({ path: "./.env" }); | ||
|
||
const { PRIVATE_KEY, LINEASCAN_API_KEY, ARBITRUM_MAINNET_PRIVATE_KEY, ARBITRUM_API_KEY } = process.env; | ||
|
||
const config: HardhatUserConfig = { | ||
solidity: { | ||
compilers: [ | ||
{ | ||
version: "0.8.20", | ||
}, | ||
], | ||
}, | ||
networks: { | ||
linea_testnet: { | ||
url: `https://rpc.goerli.linea.build/`, | ||
accounts: [PRIVATE_KEY ?? ""], | ||
}, | ||
arbitrum_one: { | ||
url: "https://arb1.arbitrum.io/rpc", | ||
accounts: [ARBITRUM_MAINNET_PRIVATE_KEY ?? ""], | ||
}, | ||
}, | ||
etherscan: { | ||
apiKey: { | ||
linea_testnet: LINEASCAN_API_KEY ?? "", | ||
arbitrumOne: ARBITRUM_API_KEY ?? "", | ||
}, | ||
customChains: [ | ||
{ | ||
network: "linea_testnet", | ||
chainId: 59140, | ||
urls: { | ||
apiURL: "https://api-testnet.lineascan.build/api", | ||
browserURL: "https://goerli.lineascan.build/address", | ||
}, | ||
}, | ||
], | ||
}, | ||
}; | ||
|
||
export default config; |
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,7 @@ | ||
/** @type {import("jest").Config} */ | ||
const config = { | ||
preset: "ts-jest", | ||
testEnvironment: "node", | ||
}; | ||
|
||
module.exports = config; |
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 was deleted.
Oops, something went wrong.
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,21 @@ | ||
import { ethers } from "hardhat"; | ||
import dotenv from "dotenv"; | ||
|
||
dotenv.config({ path: "../.env" }); | ||
|
||
const { CONTRACT_OWNER } = process.env; | ||
|
||
async function main() { | ||
const veraxVotingNFT = await ethers.deployContract("VeraxVotingNFT", [CONTRACT_OWNER]); | ||
|
||
await veraxVotingNFT.waitForDeployment(); | ||
|
||
console.log(`Deployed contract at ${veraxVotingNFT.target}`); | ||
} | ||
|
||
// We recommend this pattern to be able to use async/await everywhere | ||
// and properly handle errors. | ||
main().catch((error) => { | ||
console.error(error); | ||
process.exitCode = 1; | ||
}); |
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 was deleted.
Oops, something went wrong.
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,19 @@ | ||
import { ethers, upgrades } from "hardhat"; | ||
import dotenv from "dotenv"; | ||
|
||
dotenv.config({ path: "../.env" }); | ||
|
||
const { PROXY_ADDRESS } = process.env; | ||
|
||
async function main() { | ||
const VeraxVotingNFT = await ethers.getContractFactory("VeraxVotingNFT"); | ||
await upgrades.upgradeProxy(PROXY_ADDRESS ?? "", VeraxVotingNFT); | ||
console.log("upgrade completed"); | ||
} | ||
|
||
// We recommend this pattern to be able to use async/await everywhere | ||
// and properly handle errors. | ||
main().catch((error) => { | ||
console.error(error); | ||
process.exitCode = 1; | ||
}); |
15 changes: 8 additions & 7 deletions
15
governance/test/VeraxVotingNFT.js → governance/test/VeraxVotingNFT.ts
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,4 @@ | ||
{ | ||
"extends": "../tsconfig.json", | ||
"include": ["**/*.ts"] | ||
} |
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
Oops, something went wrong.