mirror of
https://github.com/restic/restic.git
synced 2026-06-24 17:44:17 +00:00
test: use generics in Equal function signature
This simplifies comparing a typed value against nil. Previously it was necessary to case nil into the proper type.
This commit is contained in:
@@ -29,7 +29,7 @@ func TestParse(t *testing.T) {
|
||||
u, err := location.Parse(registry, path)
|
||||
test.OK(t, err)
|
||||
test.Equals(t, "local", u.Scheme)
|
||||
test.Equals(t, &testConfig{loc: path}, u.Config)
|
||||
test.Equals(t, any(&testConfig{loc: path}), u.Config)
|
||||
}
|
||||
|
||||
func TestParseFallback(t *testing.T) {
|
||||
|
||||
Reference in New Issue
Block a user