@@ -313,7 +313,7 @@ func Greater(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface
313
313
if h , ok := t .(tHelper ); ok {
314
314
h .Helper ()
315
315
}
316
- return compareTwoValues (t , e1 , e2 , []CompareType {compareGreater }, "\" %v\" is not greater than \" %v\" " , msgAndArgs )
316
+ return compareTwoValues (t , e1 , e2 , []CompareType {compareGreater }, "\" %v\" is not greater than \" %v\" " , msgAndArgs ... )
317
317
}
318
318
319
319
// GreaterOrEqual asserts that the first element is greater than or equal to the second
@@ -326,7 +326,7 @@ func GreaterOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...in
326
326
if h , ok := t .(tHelper ); ok {
327
327
h .Helper ()
328
328
}
329
- return compareTwoValues (t , e1 , e2 , []CompareType {compareGreater , compareEqual }, "\" %v\" is not greater than or equal to \" %v\" " , msgAndArgs )
329
+ return compareTwoValues (t , e1 , e2 , []CompareType {compareGreater , compareEqual }, "\" %v\" is not greater than or equal to \" %v\" " , msgAndArgs ... )
330
330
}
331
331
332
332
// Less asserts that the first element is less than the second
@@ -338,7 +338,7 @@ func Less(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...interface{})
338
338
if h , ok := t .(tHelper ); ok {
339
339
h .Helper ()
340
340
}
341
- return compareTwoValues (t , e1 , e2 , []CompareType {compareLess }, "\" %v\" is not less than \" %v\" " , msgAndArgs )
341
+ return compareTwoValues (t , e1 , e2 , []CompareType {compareLess }, "\" %v\" is not less than \" %v\" " , msgAndArgs ... )
342
342
}
343
343
344
344
// LessOrEqual asserts that the first element is less than or equal to the second
@@ -351,7 +351,7 @@ func LessOrEqual(t TestingT, e1 interface{}, e2 interface{}, msgAndArgs ...inter
351
351
if h , ok := t .(tHelper ); ok {
352
352
h .Helper ()
353
353
}
354
- return compareTwoValues (t , e1 , e2 , []CompareType {compareLess , compareEqual }, "\" %v\" is not less than or equal to \" %v\" " , msgAndArgs )
354
+ return compareTwoValues (t , e1 , e2 , []CompareType {compareLess , compareEqual }, "\" %v\" is not less than or equal to \" %v\" " , msgAndArgs ... )
355
355
}
356
356
357
357
// Positive asserts that the specified element is positive
@@ -363,7 +363,7 @@ func Positive(t TestingT, e interface{}, msgAndArgs ...interface{}) bool {
363
363
h .Helper ()
364
364
}
365
365
zero := reflect .Zero (reflect .TypeOf (e ))
366
- return compareTwoValues (t , e , zero .Interface (), []CompareType {compareGreater }, "\" %v\" is not positive" , msgAndArgs )
366
+ return compareTwoValues (t , e , zero .Interface (), []CompareType {compareGreater }, "\" %v\" is not positive" , msgAndArgs ... )
367
367
}
368
368
369
369
// Negative asserts that the specified element is negative
@@ -375,7 +375,7 @@ func Negative(t TestingT, e interface{}, msgAndArgs ...interface{}) bool {
375
375
h .Helper ()
376
376
}
377
377
zero := reflect .Zero (reflect .TypeOf (e ))
378
- return compareTwoValues (t , e , zero .Interface (), []CompareType {compareLess }, "\" %v\" is not negative" , msgAndArgs )
378
+ return compareTwoValues (t , e , zero .Interface (), []CompareType {compareLess }, "\" %v\" is not negative" , msgAndArgs ... )
379
379
}
380
380
381
381
func compareTwoValues (t TestingT , e1 interface {}, e2 interface {}, allowedComparesResults []CompareType , failMessage string , msgAndArgs ... interface {}) bool {
0 commit comments