Skip to content

This repository contains code examples for the "Testing React Apps" section of the "Epic React" course, taught by Kent C. Dodds.

Notifications You must be signed in to change notification settings

RichardBacon/epic-react-testing

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Epic React - Testing React Apps

Epic React

This repository contains code examples for the "Testing React Apps" section of the "Epic React" course, taught by Kent C. Dodds.

Link to the course: Epic React

Description

"Testing React Apps" covers everything you need to test React components and applications with ease and get the knowledge you need to ship your applications with confidence. The topics cover are:

  • Testing with ReactDom
  • Testing with React Testing Library
  • Avoiding Implementation Details
  • Testing Forms
  • Mocking HTTP Requests
  • Mocking Browser APIs
  • Mocking Modules
  • Testing Context
  • Testing Custom Hooks

Repository Structure

  • components: Contains the components used in the testing exercises.
  • contexts: Contains the contexts used in the testing exercises.
  • exercises: Contains the testing exercises.
  • hooks: Contains the custom hooks used in the testing exercises.
  • tests: Contains the tests - the solutions to the testing exercises.
  • utils: Contains the utility functions used by the app and for testing.
  • index.js: The entry point of the app.
  • setupTests.js: Custom setup for testing.
  • styles.css: The styles for the React app.

Getting Started

  1. Clone the repository:

    git clone https://github.com/RichardBacon/epic-react-testing.git
  2. Install dependencies:

    npm install
  3. Start the React app:

    npm start
  4. Run the tests:

     npm run test

Requirements

  • Node.js (version 18)
  • npm (version 9)

About

This repository contains code examples for the "Testing React Apps" section of the "Epic React" course, taught by Kent C. Dodds.

Topics

Resources

Stars

Watchers

Forks

Contributors 2

  •  
  •  

Languages