Empty asserts that the specified object is empty. I.e. nil, "", false, 0 or either a slice or a channel with len == 0. assert.Empty(t, obj)
(t TestingT, object interface{}, msgAndArgs ...interface{})
| 123 | // |
| 124 | // assert.Empty(t, obj) |
| 125 | func Empty(t TestingT, object interface{}, msgAndArgs ...interface{}) { |
| 126 | if h, ok := t.(tHelper); ok { |
| 127 | h.Helper() |
| 128 | } |
| 129 | if assert.Empty(t, object, msgAndArgs...) { |
| 130 | return |
| 131 | } |
| 132 | t.FailNow() |
| 133 | } |
| 134 | |
| 135 | // Emptyf asserts that the specified object is empty. I.e. nil, "", false, 0 or either |
| 136 | // a slice or a channel with len == 0. |