Skip to content

Commit f75e6a1

Browse files
Mario Aguiarravichdev
authored andcommitted
Add snapshot for errors
1 parent dc4a108 commit f75e6a1

File tree

2 files changed

+45
-0
lines changed

2 files changed

+45
-0
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// Jest Snapshot v1, https://goo.gl/fbAQLP
2+
3+
exports[`Settings: Errors matches snapshot 1`] = `<div />`;
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
/**
2+
* Copyright 2020 Google LLC
3+
*
4+
* Licensed under the Apache License, Version 2.0 (the "License");
5+
* you may not use this file except in compliance with the License.
6+
* You may obtain a copy of the License at
7+
*
8+
* http://www.apache.org/licenses/LICENSE-2.0
9+
*
10+
* Unless required by applicable law or agreed to in writing, software
11+
* distributed under the License is distributed on an "AS IS" BASIS,
12+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
* See the License for the specific language governing permissions and
14+
* limitations under the License.
15+
*/
16+
17+
/**
18+
* External dependencies
19+
*/
20+
import '@testing-library/jest-dom/extend-expect';
21+
import { render } from '@testing-library/react';
22+
23+
/**
24+
* Internal dependencies
25+
*/
26+
import Errors from '../../../../assets/src/settings/components/errors';
27+
import { SettingsProvider } from '../../../../assets/src/settings/context';
28+
29+
const setup = () => {
30+
return render(
31+
<SettingsProvider>
32+
<Errors />
33+
</SettingsProvider>
34+
);
35+
};
36+
37+
describe( 'Settings: Errors', () => {
38+
it( 'matches snapshot', () => {
39+
const { container } = setup();
40+
expect( container ).toMatchSnapshot();
41+
} );
42+
} );

0 commit comments

Comments
 (0)