ReactJS

Using Jest for Snapshot testing your React Components

When it comes to testing React components there are plenty of school of thoughts around it. I have been using Airbnb’s Enzyme.js for a while and felt uncomfortable in updating the test specs with ever-changing UI. Then I came across something interesting called Snapshot Testing using Jest. It was also compelling to know that Jest snapshot testing was developed along with the React Developers to make the component testing easier. I do not want to get into a war of words which is better and this post is not intended for it. And the snapshot testing will not replace your...

Continue reading...