Created
March 27, 2019 07:33
-
-
Save DinAlla/0f9ee18a6cb46c71a8db234493d36112 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe(ExampleComponent testing', () => { | |
test('should render correctly', () => { | |
const wrapper = shallow( | |
<ExampleComponent /> | |
); | |
expect(shallowToJson(wrapper)).toMatchSnapshot(); | |
window.history.assign(‘/newPathname’); | |
const newWrapper = shallow( | |
<ExampleComponent /> | |
); | |
expect(shallowToJson(newWrapper)).toMatchSnapshot(); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment