Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Principle:Cypress io Cypress Test Result Reporting

From Leeroopedia
Knowledge Sources
Domains Testing, UI
Last Updated 2026-02-12 00:00 GMT

Overview

A reactive UI pattern for displaying hierarchical test results in real time, organized by test suites with pass/fail/pending states and detailed command logs.

Description

Test result reporting aggregates execution events from the browser-side driver into a structured, interactive display. The reporter receives events via WebSocket as tests execute, updating a reactive store that drives the UI. Results are organized as a tree of runnables (suites and tests), each containing a command log that records every Cypress command executed.

This real-time approach differs from traditional reporters that only produce output after all tests complete, enabling developers to observe test execution progress and debug failures as they occur.

Usage

Use this principle when rendering test results in any Cypress execution context: the interactive runner (open mode), the headless reporter (run mode), or the Cypress Cloud dashboard.

Theoretical Basis

Reporter Data Flow:
  Driver (browser) → WebSocket events → Server → Reporter UI

Event Types:
  - runnables: Initial test tree structure
  - test:before:run: Test starting
  - test:after:run: Test completed with result
  - command:log:added: New command in log
  - stats: Aggregated pass/fail/pending counts

UI Structure:
  Suite
  ├── Test (pass/fail/pending)
  │   ├── Command Log Entry
  │   ├── Command Log Entry
  │   └── Assertion Result
  └── Nested Suite
      └── Test

Related Pages

Implemented By

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment