MCPcopy Index your code
hub / github.com/expr-lang/expr / Empty

Function Empty

internal/testify/require/require.go:125–133  ·  view source on GitHub ↗

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{})

Source from the content-addressed store, hash-verified

123//
124// assert.Empty(t, obj)
125func 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.

Callers 2

EmptyMethod · 0.70
TestEmptyFunction · 0.70

Calls 3

EmptyFunction · 0.92
FailNowMethod · 0.65
HelperMethod · 0.45

Tested by 1

TestEmptyFunction · 0.56

Used in the wild real call sites across dependent graphs

searching dependent graphs…