Skip to content

Commit df87470

Browse files
authored
improve(test): Allow caller to identify SpokePool contract (#428)
This eases the test implementation downstream in sdk-v2.
1 parent 5691bf1 commit df87470

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@across-protocol/contracts-v2",
3-
"version": "2.5.0-beta.2",
3+
"version": "2.5.0-beta.3",
44
"author": "UMA Team",
55
"license": "AGPL-3.0-only",
66
"repository": {

test/fixtures/SpokePool.Fixture.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@ export const spokePoolFixture = hre.deployments.createFixture(async ({ ethers })
1818

1919
// Have a separate function that deploys the contract and returns the contract addresses. This is called by the fixture
2020
// to have standard fixture features. It is also exported as a function to enable non-snapshoted deployments.
21-
export async function deploySpokePool(ethers: any): Promise<{
21+
export async function deploySpokePool(
22+
ethers: any,
23+
spokePoolName = "MockSpokePool"
24+
): Promise<{
2225
weth: Contract;
2326
erc20: Contract;
2427
spokePool: Contract;
@@ -43,7 +46,7 @@ export async function deploySpokePool(ethers: any): Promise<{
4346

4447
// Deploy the pool
4548
const spokePool = await hre.upgrades.deployProxy(
46-
await getContractFactory("MockSpokePool", deployerWallet),
49+
await getContractFactory(spokePoolName, deployerWallet),
4750
[0, crossChainAdmin.address, hubPool.address],
4851
{ kind: "uups", unsafeAllow: ["delegatecall"], constructorArgs: [weth.address] }
4952
);

0 commit comments

Comments
 (0)