Read about "testing"
Testing with a Custom Render
January 13, 2021It's been quite some time for me using @testing-library/react that I can already get a sense of what's right to do and what's not. If you have used RTL before, you probably know that it exposes a render method. import { render } from '@testing-library/react' This method takes... Read more →
React Testing Setup
September 6, 2020Testing your code is like having a lifesaver, everyone should have one. Here, I'm going to set up an environment of safety, one that will you the confidence you need to ship your React code in the best shape possible. > Let's assume you already have your React project setup and... Read more →
Mocking HTTP requests with Mock Service Worker
June 12, 2020There is a lot of talk these days about if when you are testing your API integration you should be mocking your client (fetch/axios...etc.) or not. To answer your question, we want our tests to be as reliable as possible, so if they work as closes as they will do in real life,... Read more →
Mocking a Server Error with cypress
February 18, 2020When doing cypress end-to-end tests, it is very tempting to only be testing the happy path most of the time. The happy path, is the one we think users will follow, the ideal journey that will take a user from state A to B. But users have unexpected behaviour, or even worse, thi... Read more →