Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for fungus (0.17 sec)

  1. tests/callbacks_test.go

    	"testing"
    
    	"gorm.io/gorm"
    )
    
    func assertCallbacks(v interface{}, fnames []string) (result bool, msg string) {
    	var (
    		got   []string
    		funcs = reflect.ValueOf(v).Elem().FieldByName("fns")
    	)
    
    	for i := 0; i < funcs.Len(); i++ {
    		got = append(got, getFuncName(funcs.Index(i)))
    	}
    
    	return fmt.Sprint(got) == fmt.Sprint(fnames), fmt.Sprintf("expects %v, got %v", fnames, got)
    }
    
    Go
    - Registered: Sun May 05 09:35:13 GMT 2024
    - Last Modified: Tue Mar 26 03:33:36 GMT 2024
    - 7.2K bytes
    - Viewed (0)
Back to top