rework metadata
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
		| @@ -532,6 +532,9 @@ func Equal(src interface{}, dst interface{}, excptFields ...string) bool { | ||||
| 			} | ||||
| 			s := srcVal.MapIndex(key) | ||||
| 			d := dstVal.MapIndex(key) | ||||
| 			if !s.IsValid() || !d.IsValid() { | ||||
| 				return false | ||||
| 			} | ||||
| 			if !Equal(s.Interface(), d.Interface(), excptFields...) { | ||||
| 				return false | ||||
| 			} | ||||
|   | ||||
| @@ -35,7 +35,7 @@ func TestUnmarshalJSON(t *testing.T) { | ||||
| 	err = json.Unmarshal([]byte(`{"ttl":"1y"}`), v) | ||||
| 	if err != nil { | ||||
| 		t.Fatal(err) | ||||
| 	} else if v.TTL != 31536000000000000 { | ||||
| 	} else if v.TTL != 31622400000000000 { | ||||
| 		t.Fatalf("invalid duration %v != 31536000000000000", v.TTL) | ||||
| 	} | ||||
| } | ||||
| @@ -55,7 +55,7 @@ func TestParseDuration(t *testing.T) { | ||||
| 	if err != nil { | ||||
| 		t.Fatalf("ParseDuration error: %v", err) | ||||
| 	} | ||||
| 	if td.String() != "8760h0m0s" { | ||||
| 	if td.String() != "8784h0m0s" { | ||||
| 		t.Fatalf("ParseDuration 1y != 8760h0m0s : %s", td.String()) | ||||
| 	} | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user