@@ -26,6 +26,7 @@ import (
2626
2727	"github.com/containerd/nerdctl/mod/tigron/internal/assertive" 
2828	"github.com/containerd/nerdctl/mod/tigron/internal/formatter" 
29+ 	"github.com/containerd/nerdctl/mod/tigron/tig" 
2930)
3031
3132// Case describes an entire test-case, including data, setup and cleanup routines, command and 
@@ -63,7 +64,7 @@ type Case struct {
6364
6465	// Private 
6566	helpers  Helpers 
66- 	t        * testing .T 
67+ 	t        tig .T 
6768	parent   * Case 
6869}
6970
@@ -151,7 +152,7 @@ func (test *Case) Run(t *testing.T) {
151152		if  test .Require  !=  nil  {
152153			shouldRun , message  :=  test .Require .Check (test .Data , test .helpers )
153154			if  ! shouldRun  {
154- 				test .t .Skipf ("test skipped as: %s"  ,  message )
155+ 				test .t .Skip ("test skipped as: "    +  message )
155156			}
156157
157158			if  test .Require .Setup  !=  nil  {
@@ -180,7 +181,7 @@ func (test *Case) Run(t *testing.T) {
180181
181182		// Set parallel unless asked not to 
182183		if  ! test .NoParallel  {
183- 			test . t .Parallel ()
184+ 			subT .Parallel ()
184185		}
185186
186187		// Execute cleanups now 
@@ -197,7 +198,7 @@ func (test *Case) Run(t *testing.T) {
197198			}
198199
199200			// Register the cleanups, in reverse 
200- 			test . t .Cleanup (func () {
201+ 			subT .Cleanup (func () {
201202				test .t .Helper ()
202203				test .t .Log (
203204					"\n \n "  +  formatter .Table (
@@ -263,14 +264,14 @@ func (test *Case) Run(t *testing.T) {
263264
264265		if  len (test .SubTests ) >  0  {
265266			// Now go for the subtests 
266- 			test .t .Logf ( "\n %s️ %q: into subtests prep" , subinDecorator , test .t .Name ())
267+ 			test .t .Log ( fmt . Sprintf ( "\n %s️ %q: into subtests prep" , subinDecorator , test .t .Name () ))
267268
268269			for  _ , subTest  :=  range  test .SubTests  {
269270				subTest .parent  =  test 
270- 				subTest .Run (test . t )
271+ 				subTest .Run (subT )
271272			}
272273
273- 			test .t .Logf ( "\n %s️ %q: done with subtests prep" , suboutDecorator , test .t .Name ())
274+ 			test .t .Log ( fmt . Sprintf ( "\n %s️ %q: done with subtests prep" , suboutDecorator , test .t .Name () ))
274275		}
275276	}
276277
0 commit comments