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

cmd/go: -failfast flag does not apply across packages #33038

Open
dsnet opened this issue Jul 10, 2019 · 5 comments
Open

cmd/go: -failfast flag does not apply across packages #33038

dsnet opened this issue Jul 10, 2019 · 5 comments
Labels
GoCommand cmd/go help wanted NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@dsnet
Copy link
Member

dsnet commented Jul 10, 2019

Using go1.12

The documentation for failfast says "Do not start new tests after the first test failure."

When running go test ./... -failfast and one of the packages has a failure, it continues to run the tests for other packages. My interpretation of the documentation above is that go test would stop after any failure, even if in a different package.

@dmitshur dmitshur added GoCommand cmd/go NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. labels Jul 15, 2019
@dmitshur dmitshur added this to the Go1.14 milestone Jul 15, 2019
@dmitshur dmitshur changed the title testing: failfast flags does not apply across packages cmd/go: -failfast flag does not apply across packages Jul 15, 2019
@dmitshur
Copy link
Contributor

/cc @jayconrod @bcmills

@zenovich
Copy link

zenovich commented Jul 23, 2019

For now, this command helps me a lot:

for s in $(go list ./...); do if ! go test -failfast -v -p 1 $s; then break; fi; done

@lookfirst

This comment was marked as duplicate.

@docmerlin

This comment was marked as duplicate.

@mvdan
Copy link
Member

mvdan commented Jul 27, 2022

Please refrain from "bumping" github threads; see https://github.com/golang/go/wiki/NoPlusOne. If you would like to speed up the resolution of this issue, you can either react with a 👍 on the original post, or look into sending a CL with a test. See https://go.dev/doc/contribute :)

kerzhner added a commit to statechannels/go-nitro that referenced this issue Mar 23, 2023
Note that the flag will stop future tests for a failing package.
But tests for other packages will continue. See
golang/go#33038
kerzhner added a commit to statechannels/go-nitro that referenced this issue Mar 24, 2023
Note that the flag will stop future tests for a failing package.
But tests for other packages will continue. See
golang/go#33038
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GoCommand cmd/go help wanted NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

No branches or pull requests

8 participants