-
-
Notifications
You must be signed in to change notification settings - Fork 650
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
Problem in version 1.14.0 Multiple Suites Same Package #704
Comments
there was a subtle change introduced to the testing lifecycle in 1.14. Can you share some code so i can reproduce what you're seeing? |
Hi, I'm experiencing this issue as well, see eksctl-io/eksctl#2561.
If I remove the I've pushed a commit to that PR which fixes the failure. |
hmm. i'm seeing All this to say that removing these lines should fix the eksctl tests. I share a bit more detail in this issue: #708 |
Might be my golang ignorance showing here but if |
ah, i see. i'm a bit rusty on the distinction (and am not near a dev environment) but I leave the idea is that the As far as Ginkgo is concerned any Ginkgo nodes (i.e. If you see any behavior that contradicts that please let me know and I'll put together a reproducer locally once I get to my dev machine. |
Ah got it, so once per package directory thingy. That change seems to work, thanks! |
I have hit this problem too, specifically when using Using the test below under Ginkgo v1.14+ I see the failure as described by @saarrgett. It works as expected under Ginkgo v1.13.0. Edit: I should say it always appears to run as expected under v1.13 ;) package ginkgotest_test
import (
"testing"
"github.com/onsi/ginkgo"
)
var _ = ginkgo.Describe("<describe>", func() {
ginkgo.BeforeEach(func() {
})
ginkgo.It("passes", func() {
})
})
func TestSuite(t *testing.T) {
ginkgo.RunSpecs(t, "<suite>")
} Console output with v1.13.0:
Console output with v1.14.0:
|
yeah I'm planning on (eventually) updating Ginkgo to abort and explain when users use Out of curiosity I'd love to understand if there are circumstances that require you to use |
Ok, no problem. I could have sworn this did actually work, but even if it did and it was by chance I understand it's not a supported feature.
There is no technical reason I can point to. That is, it's not because the Some of our projects use Ginkgo, other's don't, some projects use "testable examples" or even just "regular Go tests" alongside Ginkgo test, etc, etc. Being able to run |
Forced ginkgo 1.13 to go round this issue: onsi/ginkgo#704
Forced ginkgo 1.13 to go round this issue: onsi/ginkgo#704
I noticed that after updating to the new release.
tests started to fail in case there are multiple suites under the same package.
This is the error message:
You may only call BeforeEach from within a Describe, Context or When
I can't say for sure what is the cause.
but it started once download to latest release,
The text was updated successfully, but these errors were encountered: