File size: 294 Bytes
1512e66
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
import React from "react";
import renderer from "react-test-renderer";
import MyComponent from "../components/MyComponent";

describe("MyComponent", () => {
 it("renders correctly", () => {
    const tree = renderer.create(<MyComponent />).toJSON();
    expect(tree).toMatchSnapshot();
 });
});