question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Public API for start/end of all tests run

See original GitHub issue

Not sure this is a documentation issue, but the feature does exist in Cypress. There’s a need for listening to an event that fires when tests start running. I see 3 cases where this can happen when running cypress open:

  1. Launch browser
  2. Click on “run all tests” button
  3. Reload the browser tab

When running cypress run this should happen only once, of course.

From inspecting the events that Cypress emits, I see run:start and run:end answer exactly this need. So the question is, can these be used as a public API for this hook? If so, I was right to think it’s a documentation issue.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:5
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
jennifer-shehanecommented, Oct 29, 2018

Hey @amitzur, we agree. In fact the work for adding this hook has mostly been done and will be part of a future release. You can see those changes in these doc updates here: https://github.com/cypress-io/cypress-documentation/issues/890

0reactions
jennifer-shehanecommented, Apr 13, 2020

@gilgold This issue is about documentation, not the Cypress product itself. See this issue for any actual events feature: https://github.com/cypress-io/cypress/issues/2840

I’m going to close this documentation issue - as the behavior of before and `after has been documented correctly now. The rest of the comments seem related to actually wanting new features in Cypress covered in https://github.com/cypress-io/cypress/issues/2840

Read more comments on GitHub >

github_iconTop Results From Across the Web

Free API - Huge List of Public APIs For Testing [No Key]
Humongous list of free APIs for finance, sports travel, data, & more. Open, public REST APIs for testing without a key.
Read more >
A complete guide to end-to-end API testing with Docker
In this article we are going to test an API built with Node/express and use chai/mocha for ... What about just running unit...
Read more >
Running integration/acceptance tests on the frontend. Need ...
Frontend runs test steps, using the normal backend API as it would in production: log in, create posts, comment on them. It will...
Read more >
REST API Testing Strategy: What Exactly Should You Test?
The API layer of any application is one of the most crucial software components. Here's a technical look at how we test our...
Read more >
Testing With CMake and CTest
Another form of smoke test is to verify that a test runs without crashing. ... nothing about the implementation of the software other...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found