Closed rossneilson closed 2 years ago
@rossneilson I can create a proposal for this. I think the best tests could be behavioural react-testing library https://testing-library.com/docs/react-testing-library/intro/ (UI/UX and components logics), plus some enzyme support for cache or other libs. It will take some time to create a good tests coverage, but we could set up some little examples of components and then each time a new ticket is opened include a label: create tests (in this case, we can create tests when we see an area of potential changes, and not everywhere that could slow down the dev process).
I think jest|react-testing-library|enzyme|etc are great for unit testing. We can split this into 2 task. One for unit testing suite implementation and other for integration/e2e (cypress is a good option in my opinion). I think will be very important to cover main flows with proper integration tests at least starting with guilds.
This may be a good first task for a developer with experience in react integration tests.
Although we dont want tests to get in the way of development or slow us down, since we are scaling our team, integration tests could be a valuable addition. Proper thought and discussion should be had to agree on a solution we are all happy with here.
In particular we should use these to avoid possible regressions of bugs by adding test cases when bugs are fixed.