NotContains asserts that the specified string, list(array, slice...) or map does NOT contain the specified substring or element. assert.NotContains(t, "Hello World", "Earth") assert.NotContains(t, ["Hello", "World"], "Earth") assert.NotContains(t, {"Hello": "World"}, "Earth")
(t TestingT, s interface{}, contains interface{}, msgAndArgs ...interface{})
| 1405 | // assert.NotContains(t, ["Hello", "World"], "Earth") |
| 1406 | // assert.NotContains(t, {"Hello": "World"}, "Earth") |
| 1407 | func NotContains(t TestingT, s interface{}, contains interface{}, msgAndArgs ...interface{}) { |
| 1408 | if h, ok := t.(tHelper); ok { |
| 1409 | h.Helper() |
| 1410 | } |
| 1411 | if assert.NotContains(t, s, contains, msgAndArgs...) { |
| 1412 | return |
| 1413 | } |
| 1414 | t.FailNow() |
| 1415 | } |
| 1416 | |
| 1417 | // NotContainsf asserts that the specified string, list(array, slice...) or map does NOT contain the |
| 1418 | // specified substring or element. |
searching dependent graphs…