File tree 1 file changed +21
-0
lines changed
1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -675,9 +675,30 @@ func (t *T) Parallel() {
675
675
t .parent .sub = append (t .parent .sub , t )
676
676
t .raceErrors += race .Errors ()
677
677
678
+ if t .chatty {
679
+ // Print directly to root's io.Writer so there is no delay.
680
+ root := t .parent
681
+ for ; root .parent != nil ; root = root .parent {
682
+ }
683
+ root .mu .Lock ()
684
+ fmt .Fprintf (root .w , "=== PAUSE %s\n " , t .name )
685
+ root .mu .Unlock ()
686
+ }
687
+
678
688
t .signal <- true // Release calling test.
679
689
<- t .parent .barrier // Wait for the parent test to complete.
680
690
t .context .waitParallel ()
691
+
692
+ if t .chatty {
693
+ // Print directly to root's io.Writer so there is no delay.
694
+ root := t .parent
695
+ for ; root .parent != nil ; root = root .parent {
696
+ }
697
+ root .mu .Lock ()
698
+ fmt .Fprintf (root .w , "=== CONT %s\n " , t .name )
699
+ root .mu .Unlock ()
700
+ }
701
+
681
702
t .start = time .Now ()
682
703
t .raceErrors += - race .Errors ()
683
704
}
You can’t perform that action at this time.
0 commit comments