Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: --fail-slow=10 #6152

Open
scottconnerly opened this issue Apr 1, 2021 · 1 comment
Open

Feature Request: --fail-slow=10 #6152

scottconnerly opened this issue Apr 1, 2021 · 1 comment
Labels

Comments

@scottconnerly
Copy link

scottconnerly commented Apr 1, 2021

What are you trying to achieve?

A halfway point between --fail-fast and running the full suite

Details

  • -fail-fast gives quick feedback loops
  • running the full suite gives all the context you need to figure out why something might be failing.

But what if there was a middle ground where, in a run where a LOT of tests were destined to fail, you still got more context on those failures than just the first one that failed? Like, maybe one could specify the number of tests that needed to fail before abandoning the rest of the suite?

Thus I propose an option called --fail-slow that after X number of tests fail, the run quits. If < X number of tests fail, the suite completes (but still returns a failure error code, of course).

@scottconnerly scottconnerly changed the title Request: --fail-slow=10 Feature Request: --fail-slow=10 Oct 14, 2021
@DavertMik
Copy link
Member

Seems good but I don't like the naming, my first guess was that this should fail slow tests, i.e. tests that take a long time to run.
So I agree this feature can be implemented with an optional parameter for --fail-fast like --fail-fast=10

If you can read the source code and figure out how to implement it, I am absolutely fine accepting this pull request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants