GreenOn
Software
ArticlesAuthorsCourses
Create articleMentoring
Join
HomeCoursesReact testing spellbook
Start
Course overview

React testing spellbook

1 hour, 8 minutes
created: 10-04-2023
updated: 10-05-2023
PENDING
Description

Master testing in React from the basics to advanced stuff and spar in front of other devs in the project.

Kacper Woźniak

Technical check

Adrian Połubiński

Author

Krzysztof Reszko

Linguistic check

Technologies
typescript
react
jest
react-testing-library
cypress
javascript
Chapters & lessons
  • 1. Basics

    10 minutes

    • Software testing

      2 m

    • Grouping the tests

      1 minute

    • The usage of describe and it

      2 m

    • The best practices for naming tests

      2 m

    • Navigating the different types of software tests

      3 m

  • 2. Mastering unit testing

    38 minutes

    • Project and tests setup

      3 m

    • Unit tests review

      4 m

    • React component testing

      5 m

    • Snapshot testing in React

      4 m

    • Understanding stubs in testing

      3 m

    • Understanding mocks in testing

      5 m

    • Creating testing fixtures

      4 m

    • Using spies in React and Typescript

      3 m

    • Mocking environment variables

      3 m

    • Using dependency injection pattern to improve fixtures

      4 m

  • 3. Mastering integration testing

    12 minutes

    • Understanding the integration tests

      4 m

    • Using MSW library to remove implementation details from tests

      4 m

    • Creating fixture for MSW to reduce boilerplate and setup

      4 m

  • 4. Mastering e2e tests

    8 minutes

    • Comprehensive guide to e2e testing on web

      3 m

    • The Gherkin Convention in a nutshell

      5 m

Statistics

4

Chapters

20

Lessons

About us

We're an educational platform that produces high quality articles, courses and teaching materials.

You can join our community via this link.

Recommended articles

Renaming git commits
Mastering article crafting in 10 steps
Common mistakes in using React Context API
NRWL extension and why do we need our own cli in JavaScript
Testing and mocking ResizeObserver in JavaScript
React components based on design system with styled-components
How to integrate state management in Zustand with NextJS
Types vs interfaces in TypeScript fully explained
Working with selectors in Zustand and Redux
Concerns about separating types from implementation
Make your components healthy with these patterns
How to work with e2e selectors in tests
Comparing Redux with Zustand for state management in React
Working with local storage vs session storage
Overview of the main functionalities of the NX tool
This keyword in JavaScript

Navigation

ArticlesAuthorsCoursesCreate articleMentoringHome

Powered by GreenOn Software