How to write test in React and Redux.
-
Install dependencies
yarn
-
Run test
- Jest
yarn test
- Cypress
yarn cy:open
-
View your site locally
yarn develop
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Update all dependencies.
- Use
toEqual
instead of snapshot testing for unit testing ofactions
,reducers
andstore
to keep test code and result in same file. - Find element instead of snapshot testing to avoid fragile testing.
- Test what user see e.g. find by text and click.
- Add Cypress.