MCPcopy Create free account
hub / github.com/expr-lang/expr / Same

Function Same

internal/testify/require/require.go:1885–1893  ·  view source on GitHub ↗

Same asserts that two pointers reference the same object. assert.Same(t, ptr1, ptr2) Both arguments must be pointer variables. Pointer variable sameness is determined based on the equality of both type and value.

(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{})

Source from the content-addressed store, hash-verified

1883// Both arguments must be pointer variables. Pointer variable sameness is
1884// determined based on the equality of both type and value.
1885func Same(t TestingT, expected interface{}, actual interface{}, msgAndArgs ...interface{}) {
1886 if h, ok := t.(tHelper); ok {
1887 h.Helper()
1888 }
1889 if assert.Same(t, expected, actual, msgAndArgs...) {
1890 return
1891 }
1892 t.FailNow()
1893}
1894
1895// Samef asserts that two pointers reference the same object.
1896//

Callers 1

SameMethod · 0.70

Calls 3

SameFunction · 0.92
FailNowMethod · 0.65
HelperMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…