Skip to content

Commit 65a007c

Browse files
committed
improve(test): Allow caller to identify SpokePool contract (#428)
This eases the test implementation downstream in sdk-v2.
1 parent b41fcee commit 65a007c

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.4.7",
3+
"version": "2.4.8",
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
@@ -17,7 +17,10 @@ export const spokePoolFixture = hre.deployments.createFixture(async ({ ethers })
1717

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

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

0 commit comments

Comments
 (0)