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

Ability to run all failed tests #2357

Closed
HerrNiklasRaab opened this issue Apr 15, 2020 · 3 comments · Fixed by #2828
Closed

Ability to run all failed tests #2357

HerrNiklasRaab opened this issue Apr 15, 2020 · 3 comments · Fixed by #2828
Labels
in testing Relates to test execution of Dart/Flutter tests for end users is enhancement
Milestone

Comments

@HerrNiklasRaab
Copy link

Most of the time you don't want to run all the tests, most of the time you only want to rerun test who are failed previously.

Something similar was also mentioned here: dart-lang/test#329

@DanTup
Copy link
Member

DanTup commented Apr 15, 2020

It's not currently possible. In theory we could get a list of tests and run each of them, but I don't think we can run a multiple tests in one go through package:test, so it might end up being much slower (as it'd have to run each one in its own debug session).

I'll keep an eye on that issue so if there are changes that would help support this, we can use them.

@DanTup DanTup added this to the Backlog milestone Apr 15, 2020
@DanTup DanTup added in testing Relates to test execution of Dart/Flutter tests for end users is enhancement labels Apr 15, 2020
@HerrNiklasRaab
Copy link
Author

What exactly is the blocker on this?

@DanTup
Copy link
Member

DanTup commented Sep 28, 2020

The issue was running a subset of tests from a suite in one go (without spawning lots of debug sessions). Running pub run test --name foo --name bar would require tests to match both foo and bar to run.

However, I think I found a way to handle this by combining them into a single regex like --name ^foo$|^bar$. I was able to make a command on the context menu for a suite that can re-run the failed tests there.

It won't be ready for the upcoming release, but I'll see if I can finish this off (it needs tests, and a way to run for all suites) for the next release. I'll ping you with a test build once it's done if you want to try it out.

@DanTup DanTup changed the title Is there an option to run all failed tests? Ability to run all failed tests Oct 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in testing Relates to test execution of Dart/Flutter tests for end users is enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants