mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
28 lines
807 B
TypeScript
28 lines
807 B
TypeScript
|
import React from 'react'
|
||
|
import { render } from '@testing-library/react'
|
||
|
import PrivacyHeader from '../../../src/components/molecules/PrivacyHeader'
|
||
|
import PrivacyLanguages from '../../../src/components/atoms/PrivacyLanguages'
|
||
|
|
||
|
const privacyPolicy = {
|
||
|
tableOfContents: 'toc',
|
||
|
policy: 'en'
|
||
|
}
|
||
|
|
||
|
describe('PrivacyLanguages', () => {
|
||
|
it('renders correctly without crashing', () => {
|
||
|
const label = 'TEST'
|
||
|
const { container } = render(<PrivacyLanguages label={label} />)
|
||
|
|
||
|
expect(container.firstChild).toBeInTheDocument()
|
||
|
expect(container).toHaveTextContent(label)
|
||
|
})
|
||
|
})
|
||
|
|
||
|
describe('PrivacyHeader', () => {
|
||
|
it('renders correctly without crashing', () => {
|
||
|
const { container } = render(<PrivacyHeader {...privacyPolicy} />)
|
||
|
|
||
|
expect(container.firstChild).toBeInTheDocument()
|
||
|
})
|
||
|
})
|