MCPcopy Create free account
hub / github.com/jmespath/go-jmespath / TestNotSame

Function TestNotSame

internal/testify/assert/assertions_test.go:249–266  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

247}
248
249func TestNotSame(t *testing.T) {
250
251 mockT := new(testing.T)
252
253 if !NotSame(mockT, ptr(1), ptr(1)) {
254 t.Error("NotSame should return true; different pointers")
255 }
256 if !NotSame(mockT, 1, 1) {
257 t.Error("NotSame should return true; constant inputs")
258 }
259 p := ptr(2)
260 if !NotSame(mockT, p, *p) {
261 t.Error("NotSame should return true; mixed-type inputs")
262 }
263 if NotSame(mockT, p, p) {
264 t.Error("NotSame should return false")
265 }
266}
267
268func Test_samePointers(t *testing.T) {
269 p := ptr(2)

Callers

nothing calls this directly

Calls 3

ptrFunction · 0.85
NotSameFunction · 0.70
ErrorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…