Skip to content

Commit

Permalink
tests repair
Browse files Browse the repository at this point in the history
  • Loading branch information
Stanislav Lysak committed Aug 29, 2024
1 parent 2d969e8 commit 3350856
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import { useAccount, useClient } from 'wagmi'

import * as ThorinComponents from '@ensdomains/thorin'

import { AvatarNFT } from './AvatarNFT'
import { makeMockIntersectionObserver } from '../../../../../test/mock/makeMockIntersectionObserver'
import { AvatarNFT } from './AvatarNFT'

vi.mock('wagmi')

Expand Down Expand Up @@ -118,7 +118,6 @@ describe('<AvatarNFT />', () => {
fireEvent.click(screen.getByText('action.confirm'))
await waitFor(() =>
expect(mockHandleSubmit).toHaveBeenCalledWith(
'nft',
'eip155:1/erc1155:0x0/0',
'https://localhost/test-media-gateway.png',
),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import { useAccount, useSignTypedData } from 'wagmi'

import { useChainName } from '@app/hooks/chain/useChainName'

import { AvatarUpload } from './AvatarUpload'
import { makeMockIntersectionObserver } from '../../../../../test/mock/makeMockIntersectionObserver'
import { AvatarUpload } from './AvatarUpload'

vi.mock('wagmi')

Expand Down Expand Up @@ -88,11 +88,7 @@ describe('<AvatarUpload />', () => {
)

await waitFor(() =>
expect(mockHandleSubmit).toHaveBeenCalledWith(
'upload',
'https://euc.li/test.eth',
mockFileDataURL,
),
expect(mockHandleSubmit).toHaveBeenCalledWith('https://euc.li/test.eth', mockFileDataURL),
)
})
it('calls handleSubmit with network path if network is not mainnet', async () => {
Expand Down

0 comments on commit 3350856

Please sign in to comment.