Debian Codegraph @

integration/_fixtures/fail_fixture/fail_fixture_ginkgo_t_test.go

raw
1 package fail_fixture_test
2
3 import (
4 . "github.com/onsi/ginkgo/v2"
5 )
6
7 var _ = Describe("GinkgoT", func() {
8 It("synchronous failures with GinkgoT().Fail", func() {
9 GinkgoT().Fail()
10 println("NEVER SEE THIS")
11 })
12
13 DescribeTable("DescribeTable",
14 func() {
15 GinkgoT().Fail()
16 },
17 Entry("a TableEntry constructed by Entry"),
18 )
19
20 It("tracks line numbers correctly when GinkgoT().Helper() is called", func() {
21 ginkgoTHelper()
22 })
23
24 It("tracks the actual line number when no helper is used", func() {
25 ginkgoTNoHelper()
26 })
27 })
28
29 var ginkgoTNoHelper = func() {
30 GinkgoT().Fail()
31 }
32 var ginkgoTHelper = func() {
33 GinkgoT().Helper()
34 GinkgoT().Fail()
35 }