Skip to content

Commit

Permalink
Merge pull request #532 from matter-labs/nikola-bozin-txfusion-verify…
Browse files Browse the repository at this point in the history
…-sepolia-support

refactor(hardhat-zksync-verify):Add support for Sepolia testnet.
  • Loading branch information
nikola-bozin-txfusion authored Dec 5, 2023
2 parents 3eaf0f3 + 239cf49 commit b88b1fd
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 6 deletions.
5 changes: 5 additions & 0 deletions .changeset/polite-kings-relax.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@matterlabs/hardhat-zksync-verify": patch
---

Added support for Sepolia testnet.
14 changes: 12 additions & 2 deletions examples/verify-example/hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,28 @@ const config: HardhatUserConfig = {
},
}
},
defaultNetwork: 'zkTestnet',
defaultNetwork: 'testnet',
networks: {
zkTestnet: {
url: "https://zksync2-testnet.zksync.dev",
zksync: true,
verifyURL: "https://zksync2-testnet-explorer.zksync.dev/contract_verification",
accounts: ["PRIVATE KEY"]
},
customNetwork: {
customNetwork: {
zksync: true,
url: ''
},
testnet:{
url: `https://sepolia.era.zksync.dev`,
ethNetwork: 'ethNetwork',
zksync:true,
accounts: ["PRIVATE KEY"]
},
ethNetwork:{
url:'YOUR_URL_FOR_SEPOLIA'
}

},
solidity: {
version: '0.8.17',
Expand Down
2 changes: 1 addition & 1 deletion examples/verify-example/test/tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import chalk from 'chalk';
import { CONTRACT_ALREADY_VERIFIED_ERROR, MOCK_ADDRESS, WRONG_NUMBER_OF_CONSTRUCTOR_ARGUMENTS_ERROR, useEnvironment } from './helpers';

describe('verify plugin', async function () {
const testnetVerifyURL = 'https://zksync2-testnet-explorer.zksync.dev/contract_verification';
const testnetVerifyURL = 'https://explorer.sepolia.era.zksync.dev/contract_verification';

describe('Testnet verifyURL extraction from config', async function () {
useEnvironment();
Expand Down
2 changes: 1 addition & 1 deletion packages/hardhat-zksync-verify/src/constants.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
export const PLUGIN_NAME = '@matterlabs/hardhat-zksync-verify';

export const TESTNET_VERIFY_URL = 'https://zksync2-testnet-explorer.zksync.dev/contract_verification';
export const TESTNET_VERIFY_URL = 'https://explorer.sepolia.era.zksync.dev/contract_verification';

export const TASK_COMPILE = 'compile';
export const TASK_VERIFY = 'verify';
Expand Down
2 changes: 1 addition & 1 deletion packages/hardhat-zksync-verify/test/common.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const config: HardhatUserConfig = {
testnet: {
zksync: true,
url: 'https://zksync2-testnet.zksync.dev',
verifyURL: 'https://zksync2-testnet-explorer.zksync.dev/contract_verification',
verifyURL: 'https://explorer.sepolia.era.zksync.dev/contract_verification',
},
},
solidity: {
Expand Down
2 changes: 1 addition & 1 deletion packages/hardhat-zksync-verify/test/tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { useEnvironment } from './helpers';
describe('verify plugin', async function () {
const sourceName: string = 'contracts/Greeter.sol';
const contractName: string = 'Greeter';
const testnetVerifyURL = 'https://zksync2-testnet-explorer.zksync.dev/contract_verification';
const testnetVerifyURL = 'https://explorer.sepolia.era.zksync.dev/contract_verification';

describe('Testnet verifyURL extraction from config', async function () {
useEnvironment('localGreeter', 'testnet');
Expand Down

0 comments on commit b88b1fd

Please sign in to comment.