File tree Expand file tree Collapse file tree 4 files changed +10
-7
lines changed Expand file tree Collapse file tree 4 files changed +10
-7
lines changed Original file line number Diff line number Diff line change 15
15
package test
16
16
17
17
import (
18
- "log"
19
18
"strconv"
20
19
"strings"
21
20
"testing"
22
21
"time"
22
+
23
+ log "github.com/sirupsen/logrus"
23
24
)
24
25
25
26
type TestCtx struct {
@@ -69,7 +70,7 @@ func (ctx *TestCtx) Cleanup() {
69
70
for i := len (ctx .cleanupFns ) - 1 ; i >= 0 ; i -- {
70
71
err := ctx .cleanupFns [i ]()
71
72
if err != nil {
72
- ctx .t .Errorf ("a cleanup function failed with error: %v \n " , err )
73
+ ctx .t .Errorf ("a cleanup function failed with error: (%v) \n " , err )
73
74
}
74
75
}
75
76
}
@@ -82,7 +83,7 @@ func (ctx *TestCtx) CleanupNoT() {
82
83
err := ctx .cleanupFns [i ]()
83
84
if err != nil {
84
85
failed = true
85
- log .Printf ("a cleanup function failed with error: %v \n " , err )
86
+ log .Errorf ("a cleanup function failed with error: (%v) " , err )
86
87
}
87
88
}
88
89
if failed {
Original file line number Diff line number Diff line change @@ -17,9 +17,10 @@ package test
17
17
import (
18
18
"flag"
19
19
"io/ioutil"
20
- "log"
21
20
"os"
22
21
"testing"
22
+
23
+ log "github.com/sirupsen/logrus"
23
24
)
24
25
25
26
const (
Original file line number Diff line number Diff line change @@ -18,11 +18,11 @@ import (
18
18
goctx "context"
19
19
"flag"
20
20
"fmt"
21
- "log"
22
21
"os"
23
22
"sync"
24
23
"time"
25
24
25
+ log "github.com/sirupsen/logrus"
26
26
extscheme "k8s.io/apiextensions-apiserver/pkg/client/clientset/clientset/scheme"
27
27
"k8s.io/apimachinery/pkg/runtime"
28
28
"k8s.io/apimachinery/pkg/runtime/serializer"
Original file line number Diff line number Diff line change 15
15
package framework
16
16
17
17
import (
18
- "log"
19
18
"os"
20
19
"testing"
20
+
21
+ log "github.com/sirupsen/logrus"
21
22
)
22
23
23
24
func MainEntry (m * testing.M ) {
24
25
if err := setup (); err != nil {
25
- log .Fatalf ("failed to set up framework: %v " , err )
26
+ log .Fatalf ("failed to set up framework: (%v) " , err )
26
27
}
27
28
28
29
os .Exit (m .Run ())
You can’t perform that action at this time.
0 commit comments