Skip to content

Commit

Permalink
add optimism goerli tokens for test envs
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlosQ96 committed Jun 23, 2023
1 parent 182de73 commit 7b95681
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/services/transactionService.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ function getTransactionDetailTestCases() {
txHash:
'0x95acfc3a5d1adbc9a4584d6bf92e9dfde48087fe54c2b750b067be718215ffc3',
symbol: 'ETH',
networkId: NETWORK_IDS.POLYGON,
networkId: NETWORK_IDS.OPTIMISM_GOERLI,
fromAddress: '0x317bbc1927be411cd05615d2ffdf8d320c6c4052',
toAddress: '0x00d18ca9782be1caef611017c2fbc1a39779a57c',
amount,
Expand Down
11 changes: 11 additions & 0 deletions test/pre-test-scripts.ts
Original file line number Diff line number Diff line change
Expand Up @@ -156,6 +156,17 @@ async function seedTokens() {
}
await Token.create(tokenData as Token).save();
}
for (const token of SEED_DATA.TOKENS.optimism_goerli) {
const tokenData = {
...token,
networkId: NETWORK_IDS.OPTIMISM_GOERLI,
isGivbackEligible: true,
};
if (token.symbol === 'OP') {
(tokenData as any).order = 2;
}
await Token.create(tokenData as Token).save();
}
}

async function seedOrganizations() {
Expand Down
14 changes: 14 additions & 0 deletions test/testUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1275,6 +1275,20 @@ export const SEED_DATA = {
decimals: 18,
},
],
optimism_goerli: [
{
name: 'OPTIMISM native token',
symbol: 'ETH',
address: '0x0000000000000000000000000000000000000000',
decimals: 18,
},
{
name: 'OPTIMISM OP token',
symbol: 'OP',
address: '0x4200000000000000000000000000000000000042',
decimals: 18,
},
],
goerli: [
{
name: 'Ethereum native token',
Expand Down

0 comments on commit 7b95681

Please sign in to comment.