Skip to content

Commit

Permalink
chore: rm tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jxom committed Dec 30, 2024
1 parent 652f779 commit 1fc8008
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 102 deletions.
29 changes: 0 additions & 29 deletions src/zksync/actions/getL1TokenAddress.test.ts

This file was deleted.

30 changes: 0 additions & 30 deletions src/zksync/actions/getL2TokenAddress.test.ts

This file was deleted.

43 changes: 0 additions & 43 deletions src/zksync/decorators/publicL2.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -212,46 +212,3 @@ test('getLogProof', async () => {

expect(fee).to.deep.equal(mockProofValues)
})

test('getL2TokenAddress', async () => {
const daiL1 = '0x70a0F165d6f8054d0d0CF8dFd4DD2005f0AF6B55'
const daiL2 = '0xFC073319977e314F251EAE6ae6bE76B0B3BAeeCF'
const client = anvilZksync.getClient()

client.request = (async ({ method, params }) => {
if (method === 'eth_call') return padHex(daiL2)
if (method === 'eth_estimateGas') return 158774n
if (method === 'zks_getBridgeContracts') return mockAddresses
if (method === 'zks_getBaseTokenL1Address') return mockBaseTokenL1Address
return anvilZksync.getClient().request({ method, params } as any)
}) as EIP1193RequestFn

const zksyncClient = client.extend(publicActionsL2())

expect(
await zksyncClient.getL2TokenAddress({
token: daiL1,
}),
).toBeDefined()
})

test('getL1TokenAddress', async () => {
const daiL1 = '0x70a0F165d6f8054d0d0CF8dFd4DD2005f0AF6B55'
const daiL2 = '0xFC073319977e314F251EAE6ae6bE76B0B3BAeeCF'
const client = anvilZksync.getClient()

client.request = (async ({ method, params }) => {
if (method === 'eth_call') return padHex(daiL1)
if (method === 'eth_estimateGas') return 158774n
if (method === 'zks_getBridgeContracts') return mockAddresses
return anvilZksync.getClient().request({ method, params } as any)
}) as EIP1193RequestFn

const zksyncClient = client.extend(publicActionsL2())

expect(
await zksyncClient.getL1TokenAddress({
token: daiL2,
}),
).toBeDefined()
})

0 comments on commit 1fc8008

Please sign in to comment.