ch14.6-14.7
This commit is contained in:
@@ -20,3 +20,11 @@ func StringContains(t *testing.T, actual, expectedString string) {
|
||||
t.Errorf("got: %q; expected to contain: %q", actual, expectedString)
|
||||
}
|
||||
}
|
||||
|
||||
func NilError(t *testing.T, actual error) {
|
||||
t.Helper()
|
||||
|
||||
if actual != nil {
|
||||
t.Errorf("got: %v; expected: nil", actual)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user