Browse code

Don't run tests twice

It's useless

Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>

Djordje Lukic authored on 2023/09/19 18:37:55
Showing 3 changed files
... ...
@@ -44,7 +44,7 @@ func TestMain(m *testing.M) {
44 44
 	}
45 45
 	span.End()
46 46
 	shutdown(ctx)
47
-	os.Exit(m.Run())
47
+	os.Exit(code)
48 48
 }
49 49
 
50 50
 func setupTest(t *testing.T) context.Context {
... ...
@@ -50,5 +50,5 @@ func TestMain(m *testing.M) {
50 50
 	span.SetAttributes(attribute.Int("exit", code))
51 51
 	span.End()
52 52
 	shutdown(ctx)
53
-	os.Exit(m.Run())
53
+	os.Exit(code)
54 54
 }
... ...
@@ -37,7 +37,7 @@ func TestMain(m *testing.M) {
37 37
 	}
38 38
 	span.SetAttributes(attribute.Int("exit", ec))
39 39
 	shutdown(ctx)
40
-	os.Exit(m.Run())
40
+	os.Exit(ec)
41 41
 }
42 42
 
43 43
 func setupTest(t *testing.T) context.Context {