DEV Community

Discussion on: Unit Tests and Snapshots are Fake News

Collapse
 
stereobooster profile image
stereobooster

For React components you can try Cypress to get more "real" tests. You can use unit-tests for "utilities" functions. I don't like snapshot tests. Screenshot tests can be useful as well. I like to use type checker (for example, TypeScript and io-ts). I didn't try property-based testing for JS, but this can be a nice option.