© 2023 Hashnode
#react-testing-library
Writing tests for your app helps to ensure that your code is functioning correctly and is free of bugs. This improves the overall quality of your app, making it more reliable and user-friendly. 1. Imp…
React Testing Library React Testing Library is a testing framework for React applications that helps you test the behaviour of your components rather than their implementation details. It is built on …
Why do testing in the first place? Let's say that you are working on a signup form and have just added a couple of fields with some functionality. Testing it manually means you need to go through the …
OTHER ARTICLES IN SERIES #1: Introduction #2: Setting up Next.js Project for testing #3: Writing the tests #3A: What should I test? #3B: Testing App Initial Load #3C: User can create a post #3D: U…
It can happen to have very similar tests across our suites. In one of my recent examples, I had to test if the UI of the footer of the pages in the application was correctly rendered, depending on a p…
OTHER ARTICLES IN SERIES #1: Introduction #2: Setting up Next.js Project for testing #3: Writing the tests #3A: What should I test? #3B: Testing App Initial Load #3C: User can create a post (i.e T…
OTHER ARTICLES IN SERIES #1: Introduction #2: Setting up Next.js Project for testing #3: Writing the tests #3A: What should I test? #3B: Testing App Initial Load (i.e This article 😁) #3C: User ca…
React Testing Library The react-testing-library is a very light-weight solution for testing React components. It provides light utility functions on top of react-dom and react-dom/test-utils, in a way that encourages better testing practice…
While writing unit and integration tests, I'm trying to find the best way on how to write them cleanly. I'm using React Testing Library so that makes already a good job of using good patterns. However…