Real World Testing with Cypress is a free and open source testing curriculum built with Next.js by the team at Cypress. Start learning today at learn.cypress.io.
# Clone the repository
git clone https://github.com/cypress-io/cypress-realworld-testing.git
cd cypress-realworld-testing
# Install dependencies
yarn install
# Start the Next.js dev server (http://localhost:3000)
yarn devTo create and run a production build locally:
yarn build
yarn startInternal documentation for this project lives in the /docs folder and is powered by VuePress. To view it, run:
yarn docs:devThis starts a local server and serves the docs site.
Lint the codebase with ESLint (via next lint):
yarn lintThe unit tests cover the project's XState machines and related utilities. They are powered by Mocha and Chai, live in the /tests folder, and can be run with:
yarn test:unitThe end-to-end tests live in cypress/e2e. Open the Cypress app to run them interactively:
yarn cypress:openRun the same tests headlessly, as they would run in CI:
yarn cypress:runTo run the tests against a mobile viewport, use the mobile variants:
yarn cypress:open:mobile
yarn cypress:run:mobileNote: The end-to-end tests run against the application, so make sure the dev server (
yarn dev) is running first.