MCPcopy
hub / github.com/stretchr/testify / NotSubset

Function NotSubset

require/require.go:1799–1807  ·  view source on GitHub ↗

NotSubset asserts that the list (array, slice, or map) does NOT contain all elements given in the subset (array, slice, or map). Map elements are key-value pairs unless compared with an array or slice where only the map key is evaluated. require.NotSubset(t, [1, 3, 4], [1, 2]) require.NotSubset(t

(t TestingT, list interface{}, subset interface{}, msgAndArgs ...interface{})

Source from the content-addressed store, hash-verified

1797// require.NotSubset(t, [1, 3, 4], {1: "one", 2: "two"})
1798// require.NotSubset(t, {"x": 1, "y": 2}, ["z"])
1799func NotSubset(t TestingT, list interface{}, subset interface{}, msgAndArgs ...interface{}) {
1800 if h, ok := t.(tHelper); ok {
1801 h.Helper()
1802 }
1803 if assert.NotSubset(t, list, subset, msgAndArgs...) {
1804 return
1805 }
1806 t.FailNow()
1807}
1808
1809// NotSubsetf asserts that the list (array, slice, or map) does NOT contain all
1810// elements given in the subset (array, slice, or map).

Callers 1

NotSubsetMethod · 0.70

Calls 3

NotSubsetFunction · 0.92
HelperMethod · 0.65
FailNowMethod · 0.65

Tested by

no test coverage detected