MCPcopy
hub / github.com/duke-git/lancet / GreaterOrEqual

Method GreaterOrEqual

internal/assert.go:117–123  ·  view source on GitHub ↗

GreaterOrEqual check if expected is greate than or equal with actual

(expected, actual any)

Source from the content-addressed store, hash-verified

115
116// GreaterOrEqual check if expected is greate than or equal with actual
117func (a *Assert) GreaterOrEqual(expected, actual any) {
118 isGreatOrEqual := compare(expected, actual) == compareGreater || compare(expected, actual) == compareEqual
119 if !isGreatOrEqual {
120 expectedInfo := fmt.Sprintf(">= %v", expected)
121 makeTestFailed(a.T, a.CaseName, expectedInfo, actual)
122 }
123}
124
125// Less check if expected is less than actual
126func (a *Assert) Less(expected, actual any) {

Callers 4

TestRandIntFunction · 0.95
TestRandFloatFunction · 0.95
TestRandFloatsFunction · 0.95
TestAssertFunction · 0.95

Calls 2

compareFunction · 0.85
makeTestFailedFunction · 0.85

Tested by 4

TestRandIntFunction · 0.76
TestRandFloatFunction · 0.76
TestRandFloatsFunction · 0.76
TestAssertFunction · 0.76