Skip to content

Commit 71c6b0c

Browse files
appilonkmoe
authored andcommitted
tweak mockT implementation
1 parent acb365c commit 71c6b0c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

helper/resource/testing_test.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,8 @@ func (t *mockT) Error(args ...interface{}) {
174174
}
175175

176176
func (t *mockT) FailNow() {
177+
t.f = true
178+
177179
panic("mockT.FailNow")
178180
}
179181

@@ -186,7 +188,7 @@ func (t *mockT) Fatal(args ...interface{}) {
186188
}
187189

188190
func (t *mockT) Fatalf(format string, args ...interface{}) {
189-
t.Fatal(format, args)
191+
t.Fatal(fmt.Sprintf(format, args...))
190192
}
191193

192194
func (t *mockT) Helper() {}

0 commit comments

Comments
 (0)