github.com/gagliardetto/golang-go@v0.0.0-20201020153340-53909ea70814/cmd/go/testdata/standalone_parallel_sub_test.go (about) 1 package standalone_parallel_sub_test 2 3 import "testing" 4 5 func Test(t *testing.T) { 6 ch := make(chan bool, 1) 7 t.Run("Sub", func(t *testing.T) { 8 t.Parallel() 9 <-ch 10 t.Run("Nested", func(t *testing.T) {}) 11 }) 12 // Ensures that Sub will finish after its t.Run call already returned. 13 ch <- true 14 }