npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@probara/cypress-reporter

v0.4.0

Published

Cypress reporter that sends every test result to Probara.

Readme

A Cypress reporter that sends every test result of a run to Probara: each attempt with its status, duration and error, linked to its Probara test case, with the steps, attachments and links your tests add. Cases that are missing get created, and the run is closed once everything is in. Built on @probara/core.

Features

  • Three registrations, each with its own job: the reporter (reporter and reporterOptions) turns Cypress' own events into results, the plugin (setupNodeEvents, from @probara/cypress-reporter/setup) owns the run, registers the probara task, and collects the screenshots and the video, and the support file (import '@probara/cypress-reporter/support') turns on the probara.* helpers. Registered together, a spec reports every attempt with everything it recorded (registration).
  • One result per attempt, retries included, with Cypress' own verdict: it.skip and this.skip() are skipped, the attempt a retry stands for is failed, and every test a failing hook kept from running is skipped (statuses, retries).
  • The same keys as probara import junit on the JUnit XML of Cypress's junit reporter or of cypress-junit, so switching from the JUnit import keeps every case and its history (same cases as the JUnit import).
  • Screenshots attached to the exact attempt Cypress took them for, plus the video of a spec for its failed results (attachVideos) (attachments).
  • Visual testing with cy.probaraSnap(name): screenshots compared between commits in Probara Snap (Probara Snap).
  • Linking by a case id in a title or a describe (SHOP-12 adds an item) or probara.id(), and the browser Cypress runs as a browser context value of every result: shown on it, never a parameter of a new case, never in the key (linking, projects).
  • Browser helpers that run where the test runs: probara.step() (nested, with expected results and data), probara.attach(), probara.link(), probara.issue(), probara.parameters(), and the title, suite, tags and fields of a new case (metadata, steps).
  • Console output of each test attached with captureOutput (attachments), and run selection: only the tests of a Probara run, with runCasesOnly (run selection).
  • Runs by name, with an environment, milestone, test plan, configurations and tags (run options); one run for every shard of a sharded CI job (sharding); failures assigned with assignFailedTo (assign failed).
  • Never breaks your test run: a reporting problem is logged, never thrown, and cypress run still ends with the number of its own failed tests. What could not be sent can be kept in a file and sent later with probara import results 'probara-results*.json'.

Not supported in this version

| What | Why, and what to use | | ------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | cypress open (interactive mode) | Cypress builds the reporter only in cypress run: run the specs you work on with cypress run --spec (interactive mode) | | Cypress commands as steps | The support file could follow Cypress's command events in the browser (Cypress.on('command:start'), or log:added as Allure's does); this version does not, since every command would multiply the steps of a result (Probara keeps 200 per result). Use probara.step() (steps) | | Gherkin steps of a Cucumber preprocessor (@badeball/cypress-cucumber-preprocessor) | Not turned into steps of the result | | Network profiling (Qase's cy.intercept recorder) | A task per request: more noise and cost than value | | Result fields | Probara has no result fields |

Also not ported from the reporters this one takes over from, each with its reason: updating existing cases (a report never changes a case), a key override (externalId, historyId, automation_id), a case owner, masked parameters, categories and known issues, and defects or public links (coming from other tools).

Requirements

  • Node.js 22.12 or later.
  • Cypress 15.10.0 or later: the first version with Cypress.expose(), which carries the plugin's settings to the browser (Cypress versions).
  • A Probara app token, created from the Cypress card in Integrations (get a token), and the code of the project to report into (such as SHOP). Reporting from CI needs a paid plan.

Install

npm install --save-dev @probara/cypress-reporter

Quick start

  1. In Probara, open Workspace › Integrations, pick the Cypress card and create a token (get a token). Store it as a CI secret named PROBARA_API_TOKEN: the reporter reads it from the environment, never from the config.

  2. Register the reporter and its plugin in the Cypress config:

    // cypress.config.js
    const { defineConfig } = require('cypress');
    const { probaraNodeEvents } = require('@probara/cypress-reporter/setup');
    
    module.exports = defineConfig({
      e2e: {
        reporter: '@probara/cypress-reporter',
        reporterOptions: { projectId: 'SHOP' },
        setupNodeEvents(on, config) {
          return probaraNodeEvents(on, config);
        },
      },
    });
  3. Load the browser helpers in the support file, so a spec can use probara.*:

    // cypress/support/e2e.js
    import '@probara/cypress-reporter/support';
  4. Run your tests with the token in the environment. In GitHub Actions:

    - name: Run Cypress tests
      run: npx cypress run
      env:
        PROBARA_API_TOKEN: ${{ secrets.PROBARA_API_TOKEN }}
        PROBARA_PROJECT: SHOP

Without a token and a project the reporter stays off and quiet, so local runs send nothing. In CI it logs on stdout, in [probara] lines, and ends with the link to the run:

$ npx cypress run --spec cypress/e2e/cart.cy.js
[probara] Sending 5 results of 4 tests (3 passed, 2 failed, 0 skipped, 0 blocked)
[probara] Recorded 5 results (2 new cases, 0 unmatched) in R-1 (closed): https://app.probara.net/projects/SHOP/runs/R-1

What gets reported

| Cypress | In Probara | | ----------------------------------------------------------------------- | ------------------------------------------------------------------------- | | A test | A test case, matched by its automation key or linked by a case id | | Each attempt (retries too) | A result in the run, with its status, duration, start time and error | | it.skip, this.skip(), a test a failing hook kept from running | A skipped result | | A failing beforeEach/before | One failed result named as Cypress names it, plus the tests it stopped | | probara.step() calls | The steps of the result, nested, with their status, duration and error | | probara.attach(), captureOutput, the screenshots of a failure | Files of the result, or of the step they were attached in | | probara.link(), probara.issue() | Links of the result | | Other probara.* calls in the test | The title, suite, tags, fields and steps of a new case; result parameters | | A spec Cypress cannot run (a syntax error), one that throws as it loads | One failed result, as Cypress names it, so it never shows green | | The cypress run command | One automated run, named after the CI build, closed at the end |

Cypress ends a cypress run with the number of its own failed tests, and reporting changes nothing of it: four failed tests still end the command with 4, whatever Probara answered (statuses).

Same cases as the JUnit import

The reporter gives each test the automation key probara import junit gives it on the report of Cypress's built-in junit reporter or of cypress-junit written with their default options: the spec file relative to the project root, then > between spaces, then the describes and the it title joined by spaces (the name both write), without the case ids. For these two specs:

// cypress/e2e/cart.cy.js
describe('Cart', () => {
  it('SHOP-12 adds an item', () => {
    cy.get('.add').click();
  });

  it('removes an item', () => {
    cy.get('.remove').click();
  });
});
// cypress/e2e/login.cy.js
describe('Login', () => {
  it('logs in with a valid password', () => {
    cy.get('#submit').click();
  });
});

the reporter sends:

[
  {
    "automationKey": "cypress/e2e/cart.cy.js > Cart adds an item",
    "caseDisplayId": "SHOP-12",
    "status": "passed"
  },
  { "automationKey": "cypress/e2e/cart.cy.js > Cart removes an item", "status": "passed" },
  {
    "automationKey": "cypress/e2e/login.cy.js > Login logs in with a valid password",
    "status": "passed"
  }
]

If your JUnit reports were written with a mochaFile that one spec overwrites, or without the file attribute of the root suite, set keyIncludesFile: false: the keys then leave the file out (configuration). Either way, a test keeps its case and its history when you switch from the JUnit import (migrating from the JUnit import).

Documentation

| Page | What it covers | | --------------------------------------------------------------- | ----------------------------------------------------------------------------------------------- | | Configuration | The three registrations, every option, its variable and default; getting a token | | Linking tests to cases | Case ids in titles and describes, probara.id(), automation keys, describe and it.only | | Metadata | Title, suite, comment, tags, fields, parameters, ignoring an attempt; where helpers work | | Steps | probara.step(): nesting, status, errors, Cypress commands, the steps of a new case | | Attachments | probara.attach(), files of steps, screenshots, video, console output, limits | | Probara Snap | cy.probaraSnap(): screenshots compared between commits, masking, split specs | | Links | probara.link(), probara.issue() and issueUrlTemplate | | Statuses | How attempts become statuses; it.skip, hooks, specs that fail; mapping and filter | | Specs | --spec, it.only, retries, specs that cannot run, the spec as a suite | | Retries and flaky tests | Every attempt is a result | | Run options | Name, description, environment, milestone, plan, configurations, tags, an existing run, closing | | Sharding and CI | One run for every shard | | Cypress and Probara projects | Results to other Probara projects, keyIncludesFile, the browser as a parameter | | Interactive mode | Why cypress open reports nothing, and what to run instead | | Run selection | runCasesOnly: run only the tests of a Probara run | | Assign failed results | assignFailedTo: who looks into failures | | Results file | Keep what could not be sent, send it later | | Migrating from the JUnit import | From Cypress's junit reporter or cypress-junit and probara import junit, keeping every case | | Migrating from Qase | Option by option and call by call, what is different, what is not ported | | Coming from other tools | Allure Cypress and TestRail's trcli, mapped, and what is not ported | | Troubleshooting | Problems and their solutions; every line the reporter logs | | Debugging | PROBARA_DEBUG, the logs, checking what would be sent | | Network | Requests, timeouts, retries, rate limits, proxies and certificates | | Upgrading | Versioning policy, the automation key contract, Cypress versions | | Changelog | What changed in each version |

CI guides: GitHub Actions, GitLab CI, CircleCI, Azure Pipelines, Jenkins, Bitbucket Pipelines and Buildkite.

On the Probara side, the Cypress integration guide covers the card, its app tokens and what Probara shows.

Reporting never breaks your test run

The reporter never throws into Cypress and never changes its exit code: a failed test still fails the command, a reporting problem does not. Every problem (a wrong setting, Probara unreachable, a refused token) is logged, and the tests keep their outcome. probara.* calls never throw into a test either: a call Probara cannot use is left out with a warning. There is no option to fail the command on a reporting error; to keep what could not be sent, set a results file (resultsFile).

License

Apache License 2.0.