Cleanup expr tests
This commit is contained in:
@@ -4,7 +4,6 @@ import (
|
||||
"reflect"
|
||||
|
||||
"github.com/PaesslerAG/gval"
|
||||
"github.com/davecgh/go-spew/spew"
|
||||
)
|
||||
|
||||
func GenericFunctions() []gval.Language {
|
||||
@@ -43,8 +42,6 @@ func isEmpty(i interface{}) bool {
|
||||
return true
|
||||
}
|
||||
|
||||
spew.Dump("A", reflect.ValueOf(i).IsZero())
|
||||
|
||||
switch reflect.TypeOf(i).Kind() {
|
||||
case reflect.Slice, reflect.Array, reflect.Ptr, reflect.Map:
|
||||
return reflect.ValueOf(i).Len() == 0
|
||||
|
||||
@@ -80,7 +80,7 @@ func Example_isLeapYear() {
|
||||
}
|
||||
|
||||
func Example_isWeekDay() {
|
||||
eval(`isWeekDay(now)`, exampleTimeParams)
|
||||
eval(`isWeekDay(ghd)`, exampleTimeParams)
|
||||
|
||||
// output:
|
||||
// true
|
||||
|
||||
Reference in New Issue
Block a user