mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
Adding inital outline for test
This commit is contained in:
parent
9fca971d77
commit
6776ffe34d
22
src/components/Asset/Edit/FormEditMetadata.test.tsx
Normal file
22
src/components/Asset/Edit/FormEditMetadata.test.tsx
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
import { render, screen } from '@testing-library/react'
|
||||||
|
import React from 'react'
|
||||||
|
import Formik, { useFormikContext } from 'formik'
|
||||||
|
import FormEditMetadata from './FormEditMetadata'
|
||||||
|
import content from '../../../../content/pages/editMetadata.json'
|
||||||
|
|
||||||
|
jest.mock('formik')
|
||||||
|
|
||||||
|
describe('src/components/Asset/Edit/FormEditMetadata.tsx', () => {
|
||||||
|
const useFormikContextMock = jest.spyOn(Formik, 'useFormikContext')
|
||||||
|
|
||||||
|
it('renders fixed price', () => {
|
||||||
|
// render()
|
||||||
|
// (useFormikContext as jest.Mock).
|
||||||
|
// <FormEditMetadata
|
||||||
|
// data={content.form.data}
|
||||||
|
// showPrice={true}
|
||||||
|
// isComputeDataset={false}
|
||||||
|
// />
|
||||||
|
expect(screen.getByText('New Title')).toBeInTheDocument()
|
||||||
|
})
|
||||||
|
})
|
Loading…
Reference in New Issue
Block a user