This money tracker app is built with React/Redux and tested with Jest and Enzyme. It was developed to practice TDD and BDD principles.
Installation | Testing | Challenges and Solutions | Code Snippets | Acknowledgements
OS X & Linux:
npm install
Snapshot testing is done with Jest and assertion testing is done with Enzyme.
npm i --save-dev enzyme enzyme-adapter-react-16
With the release of React > 16, you must configure the Enzyme Adapter:
// yourTestFile.test.js
import { configure } from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';
configure({ adapter: new Adapter() });
Here are some of challenges I encountered along the way and how I went about solving them.
David Katz, thank you for your course. It was a great way to take my React and Jest knowledge to the next level.