Skip to content

Commit

Permalink
test(timelineitem.test.js): add test for TimelineItem.tsx
Browse files Browse the repository at this point in the history
Add test for TimelineItem.tsx
  • Loading branch information
erikpr1994 committed Oct 2, 2020
1 parent d65e323 commit 3dc5811
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/Components/timelineItem/TimelineItem.test.js
@@ -1,3 +1,10 @@
test('true', () => {
expect(true).toBe(true);
import React from 'react';
import { render } from '@testing-library/react';
import ReactDOM from 'react-dom';
import TimelineItem from './TimelineItem';

it('matches snapshot', () => {
const container = document.createElement('div');
ReactDOM.render(<TimelineItem />, container);
expect(container).toMatchSnapshot();
});
@@ -0,0 +1,18 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`matches snapshot 1`] = `
<div>
<div
class="sc-bxivhb SUHGw"
>
<div>
<div
style="cursor: pointer;"
>
<h4 />
<h5 />
</div>
</div>
</div>
</div>
`;

0 comments on commit 3dc5811

Please sign in to comment.