1
0
mirror of https://github.com/astaxie/beego.git synced 2025-06-11 14:20:38 +00:00

should use time.Since instead of time.Now().Sub

Signed-off-by: wgliang <liangcszzu@163.com>
This commit is contained in:
wangguoliang
2017-09-07 19:01:34 +08:00
parent d96289a81b
commit c8c25549e7
6 changed files with 7 additions and 7 deletions

View File

@ -7,7 +7,7 @@ import (
// MethodParamOption defines a func which apply options on a MethodParam
type MethodParamOption func(*MethodParam)
// IsRequired indicates that this param is required and can not be ommited from the http request
// IsRequired indicates that this param is required and can not be omitted from the http request
var IsRequired MethodParamOption = func(p *MethodParam) {
p.required = true
}

View File

@ -75,7 +75,7 @@ func checkParser(def testDefinition, t *testing.T, methodParam ...MethodParam) {
}
convResult, err := safeConvert(reflect.ValueOf(result), toType)
if err != nil {
t.Errorf("Convertion error for %v. from value: %v, toType: %v, error: %v", def.strValue, result, toType, err)
t.Errorf("Conversion error for %v. from value: %v, toType: %v, error: %v", def.strValue, result, toType, err)
return
}
if !reflect.DeepEqual(convResult.Interface(), def.expectedValue) {