Cypress Documentation

website·Indexed 43 days ago

https://docs.cypress.io/

A modern end-to-end testing framework for web applications. This documentation covers core concepts like retry-ability and test isolation, end-to-end testing, and component testing for frameworks including React 18/19, Vue 3+, Angular ^21.0.0/^22.0.0, and Svelte 5. It also provides guides for continuous integration with GitHub Actions, CircleCI, GitLab CI, AWS CodeBuild, and Bitbucket Pipelines, as well as AI-powered test generation.

Tokens
418.1K
Snippets
2K
Records
3.3K
Agent score
73%

What's inside Cypress

  1. Overview of Cypress Cloud Teams

    A Cypress Cloud team is a reusable group of users granted access to a specific set of projects. Teams allow organization owners to control project visibility at the team level rather than managing access for every user on every project individually.

    Key characteristics include:

    • No limit on the number of teams per organization.
    • All organization members are automatically part of the default 'Everyone' team.
    • Users can belong to multiple teams.
    • Projects can be assigned to multiple teams.
    • Team-based access only controls visibility within the Cypress Cloud UI; it does not prevent the Cypress App from recording runs to a project.
    • Public projects remain visible to all users regardless of team membership.
  2. Overview of Cypress Studio and Studio AI

    Cypress Studio allows developers to generate and extend E2E tests by recording real interactions in an application. Studio AI is an opt-in layer that analyzes DOM changes during recording to automatically recommend assertions. While basic recording and manual assertions are available without a Cloud account, AI-powered recommendations require a Cypress Cloud connection.
  3. Overview of Cypress UI Coverage

    UI Coverage is a feature of Cypress Cloud that identifies which interactive parts of an application (buttons, inputs, links, and controls) are exercised by tests and which are missed. Unlike code coverage, which tracks executed lines of code, UI Coverage measures the application from the user's perspective by analyzing the interactive surface area. It requires no code changes, no plugins, and no instrumentation, as it is generated automatically from Test Replay data captured during recorded runs.
  4. Overview of the UI Coverage Results API

    The Results API allows developers to pull UI Coverage results from Cypress Cloud into a CI job. This enables automating coverage enforcement, such as failing a build if coverage drops below a threshold, enforcing different standards for specific app areas (e.g., /checkout), or posting coverage scores to Slack or Pull Requests. Because reports are processed server-side from Test Replay data, using this API adds no overhead to the Cypress runs themselves. The helper must be called after cypress run --record completes within the same CI build.
  5. Overview of Cypress Cloud Free Trial

    Cypress Cloud offers a 30-day free trial providing full access to the Enterprise plan features. The trial is designed to help teams evaluate debugging, orchestration, and analytics capabilities without requiring a credit card. During the trial, users are provided with 50,000 test results and 50 user seats. After the trial ends, accounts automatically transition to the free Starter plan unless a paid subscription is chosen.
  6. Overview of identifying coverage gaps with UI Coverage

    UI Coverage analyzes recorded runs in Cypress Cloud (using Test Replay data) to create a visual map of interactive elements that tests exercise versus those they miss. It requires no code instrumentation or application changes. The workflow involves recording a run, analyzing the overall coverage score, identifying low-scoring views, drilling into untested elements, and turning those gaps into new tests.
  7. Overview of Native Network Interception in Cypress

    Starting in Cypress 16, Chrome, Chromium, and Edge use native browser network interception. This allows the application to connect directly to servers using the production protocol (supporting HTTP/2 and HTTP/3) and validates the server's own certificates rather than using a Cypress-generated CA. cy.intercept() continues to work with the same API, and stubbed responses are now visible in the browser's own network panel.
  8. Overview of Cypress Accessibility (Cloud Solution)

    Cypress Accessibility is a paid premium solution available in Cypress Cloud. Unlike in-test plugins, it moves accessibility checks outside of the test execution context. It automatically detects steps within user flows and generates accessibility reports without requiring additional test code, eliminating the performance overhead and training hurdles associated with in-test plugins.
  9. Overview of bundled libraries in Cypress

    Cypress comes with several open-source testing and utility libraries built-in. These are available globally in every test and do not require installation, importing, or configuration. Cypress uses its own bundled versions of these libraries; installing different versions of them in your project will not override the versions Cypress uses.

    Key bundled libraries include:

    • Mocha: Test framework for structuring tests.
    • Chai: Assertion library for validating results.
    • Chai-jQuery: Extends Chai with DOM-specific assertions.
    • Sinon: Provides spies, stubs, and fake timers.
    • Sinon-Chai: Extends Chai with assertions for Sinon spies and stubs.
    • Utility Libraries: Lodash, jQuery, minimatch, blob-util, Buffer, and Bluebird.
  10. Overview of cypress tap

    cypress tap is a CLI extension that enables users or AI agents to interact with an open-mode Cypress session and extract context directly from the terminal. It allows an agent to run specs, poll for status, read the Command Log, and inspect the DOM of the application under test at the moment a command ran. It is designed to help AI agents (like Cursor, Claude Code, GitHub Copilot, etc.) verify and fix test failures in a tight loop.
  11. Overview of Cypress Accessibility capabilities

    Cypress Accessibility is used to improve and maintain the accessibility of websites and applications tested with Cypress. It supports two primary project states:

    1. Projects with many issues: Focuses on driving remediation, establishing incremental accessibility standards, identifying 'quick wins', and comparing test runs to isolate new issues from existing ones.
    2. Well-maintained projects: Focuses on maintaining high standards and preventing regressions through resilient workflows.

    Note: Automated checks are a starting point; they have limitations regarding static analysis. Full accessibility requires combining these checks with explicit test coverage to ensure a truly usable experience for all users.

  12. Overview of Cypress Cloud MCP for Agentic Debugging

    The Cypress Cloud Model Context Protocol (MCP) server allows AI coding assistants (the Host) to connect to Cypress Cloud (the Server) to retrieve real-time test results. This enables AI agents to query run statuses, identify flaky tests, and retrieve failure details, including Test Replay links, directly within the developer's workflow. It is available on all Cypress Cloud plans.