You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/react/testing/introduction.md
+16-8
Original file line number
Diff line number
Diff line change
@@ -10,23 +10,31 @@ This document provides an overview of how to test an application built with `@io
10
10
11
11
## Introduction
12
12
13
-
Testing is an important part of the development process, and it helps to ensure that an application is working as intended. In `@ionic/react`, testing is done using a combination of tools and libraries, including Jest, React Testing Library, and Cypress.
13
+
Testing is an important part of the development process, and it helps to ensure that an application is working as intended. In `@ionic/react`, testing is done using a combination of tools and libraries, including Vitest, Jest, React Testing Library, Playwright or Cypress.
14
+
15
+
## Types of Tests
16
+
17
+
There are two types of tests that can be written:
18
+
19
+
**Unit Tests**: Unit tests are used to test individual functions and components in isolation. They are typically written using [Jest](https://jestjs.io) and [React Testing Library](https://testing-library.com) or [Vitest](https://vitest.dev).
20
+
21
+
**Integration Tests**: Integration tests are used to test how different components work together. They are typically written using [Cypress](https://www.cypress.io) or [Playwright](https://playwright.dev).
14
22
15
23
## Tools and Libraries
16
24
17
-
**Jest**: Jest is a popular testing framework for JavaScript applications. It's used to run unit tests and integration tests.
25
+
### Unit Testing
18
26
19
-
**React Testing Library**: React Testing Library is a set of utilities that make it easier to test React components. It's used to interact with components and test their behavior.
27
+
[**Jest**](https://jestjs.io): Jest is a popular testing framework for JavaScript applications. It is included with `react-scripts` and is used to run unit tests.
20
28
21
-
**Cypress**: Cypress is a modern testing tool that's used to run end-to-end tests. It allows developers to test the entire application, including the user interface, in a simulated environment.
29
+
[**Vitest**](https://vitest.dev): Vitest is a modern testing framework powered by Vite. It is compatible with Jest and is used to run unit tests.
22
30
23
-
## Types of Tests
31
+
[**React Testing Library**](https://testing-library.com): React Testing Library is a set of utilities that make it easier to test React components. It's used to interact with components and test their behavior.
24
32
25
-
There are two types of tests that can be written:
33
+
### Integration Testing
26
34
27
-
**Unit Tests**: Unit tests are used to test individual functions and components in isolation. They are typically written using Jest and React Testing Library.
35
+
[**Cypress**](https://www.cypress.io): Cypress is a modern testing tool that's used to run end-to-end tests. It allows developers to test the entire application, including the user interface, in a simulated environment.
28
36
29
-
**Integration Tests**: Integration tests are used to test how different components work together. They are typically written using Cypress.
37
+
[**Playwright**](https://playwright.dev): Playwright is a browser automation library that's used to run end-to-end tests. It allows developers to test the entire application, including the user interface, in a simulated environment.
0 commit comments