OK fails the test if an err is not nil.
(tb testing.TB, err error)
| 25 | |
| 26 | // OK fails the test if an err is not nil. |
| 27 | func OK(tb testing.TB, err error) { |
| 28 | tb.Helper() |
| 29 | if err != nil { |
| 30 | tb.Fatalf("\033[31munexpected error: %+v\033[39m\n\n", err) |
| 31 | } |
| 32 | } |
| 33 | |
| 34 | // OKs fails the test if any error from errs is not nil. |
| 35 | func OKs(tb testing.TB, errs []error) { |