MCPcopy
hub / github.com/expr-lang/expr / TestExactlyWrapper

Function TestExactlyWrapper

internal/testify/assert/forward_assertions_test.go:109–134  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

107}
108
109func TestExactlyWrapper(t *testing.T) {
110 assert := New(new(testing.T))
111
112 a := float32(1)
113 b := float64(1)
114 c := float32(1)
115 d := float32(2)
116
117 if assert.Exactly(a, b) {
118 t.Error("Exactly should return false")
119 }
120 if assert.Exactly(a, d) {
121 t.Error("Exactly should return false")
122 }
123 if !assert.Exactly(a, c) {
124 t.Error("Exactly should return true")
125 }
126
127 if assert.Exactly(nil, a) {
128 t.Error("Exactly should return false")
129 }
130 if assert.Exactly(a, nil) {
131 t.Error("Exactly should return false")
132 }
133
134}
135
136func TestNotEqualWrapper(t *testing.T) {
137

Callers

nothing calls this directly

Calls 3

NewFunction · 0.70
ExactlyMethod · 0.45
ErrorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…