1
0
mirror of https://github.com/kremalicious/portfolio.git synced 2024-11-15 09:35:17 +01:00
portfolio/src/components/templates/Project.test.jsx

17 lines
555 B
React
Raw Normal View History

2019-11-25 13:46:44 +01:00
import React from 'react'
import { render } from '@testing-library/react'
import { createHistory, createMemorySource } from '@reach/router'
import Project from './Project'
import project from '../../jest/__fixtures__/project.json'
describe('Project', () => {
const history = createHistory(createMemorySource('/oceanprotocol'))
it('renders correctly from data file values', async () => {
const { container } = render(
<Project data={project} location={history.location} />
)
expect(container.firstChild).toBeInTheDocument()
})
})