Skip to content

Commit

Permalink
sort snapshot re. styled-components-jest
Browse files Browse the repository at this point in the history
  • Loading branch information
michael-odonovan committed Oct 4, 2023
1 parent 8a43e83 commit 476f482
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions src/components/Molecules/PostcodeLookup/PostcodeLookup.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,12 @@ import 'jest-styled-components';
import renderWithTheme from '../../../hoc/shallowWithTheme';
import PostcodeLookup from './PostcodeLookup';

it('renders correctly', () => {
const renderer = renderWithTheme(<PostcodeLookup onSelect={() => {}} />);
// const goodPostcode = "bs5 6hq";
// const badPostcode = "555 6hq";

expect(renderer.toJSON()).toMatchSnapshot();
it('renders correctly', () => {
const tree = renderWithTheme(
<PostcodeLookup onSelect={address => alert(JSON.stringify(address, null, 2))} />
).toJSON();
expect(tree).toMatchSnapshot()
});

0 comments on commit 476f482

Please sign in to comment.