testing without db tags
This commit is contained in:
10
lazy.go
10
lazy.go
@@ -149,11 +149,11 @@ func RandomStruct(c StructConfig) (*StructMock, error) {
|
|||||||
filled = reflect.Append(filled, reflect.ValueOf(c.Example))
|
filled = reflect.Append(filled, reflect.ValueOf(c.Example))
|
||||||
for y := 0; y < maxFieldCount; y++ {
|
for y := 0; y < maxFieldCount; y++ {
|
||||||
field := retType.Field(y)
|
field := retType.Field(y)
|
||||||
dbTag := field.Tag.Get(DB_TAG)
|
// dbTag := field.Tag.Get(DB_TAG)
|
||||||
// no db tag, we skip
|
// // no db tag, we skip
|
||||||
if dbTag == "" {
|
// if dbTag == "" {
|
||||||
continue
|
// continue
|
||||||
}
|
// }
|
||||||
|
|
||||||
//get random value
|
//get random value
|
||||||
nv := kindToRandom(field)
|
nv := kindToRandom(field)
|
||||||
|
Reference in New Issue
Block a user