Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Flaky asynchronous test fails with wrong spec state #465

@williammartin

Description

@williammartin

Occasionally when I run the ginkgo tests I see the following failure:

• Failure [0.030 seconds]
Shared RunnableNode behavior JustBeforeEach Nodes asynchronous functions when the function times out [It] should return the timeout 
/tmp/build/a94a8fe5/gopath/src/github.com/onsi/ginkgo/internal/leafnodes/shared_runner_test.go:216

  Expected
      <types.SpecState>: 5
  to equal
      <types.SpecState>: 6

  /tmp/build/a94a8fe5/gopath/src/github.com/onsi/ginkgo/internal/leafnodes/shared_runner_test.go:220

  Full Stack Trace
  	/tmp/build/a94a8fe5/gopath/src/github.com/onsi/gomega/internal/assertion/assertion.go:69 +0x25b
  github.com/onsi/gomega/internal/assertion.(*Assertion).Should(0xc42041e5c0, 0xb0dc40, 0xc4203504e0, 0x0, 0x0, 0x0, 0xc42041e5c0)
  	/tmp/build/a94a8fe5/gopath/src/github.com/onsi/gomega/internal/assertion/assertion.go:27 +0xd0
  github.com/onsi/ginkgo/internal/leafnodes_test.AsynchronousSharedRunnerBehaviors.func2.5.2()
  	/usr/local/go/src/testing/testing.go:777 +0x16e
  created by testing.(*T).Run
  	/usr/local/go/src/testing/testing.go:824 +0x565

Metadata

Metadata

Assignees

Labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions