Check timestamps in snapshot storage test suite

also use t.Helper()
convert assertions to canonical

Signed-off-by: Daniel Nephin <dnephin@gmail.com>
This commit is contained in:
Daniel Nephin
2018-01-18 17:34:09 -05:00
parent 37aa41b164
commit 3279acca82
6 changed files with 76 additions and 74 deletions

View File

@@ -4,7 +4,6 @@ import (
"testing"
"github.com/gotestyourself/gotestyourself/assert"
is "github.com/gotestyourself/gotestyourself/assert/cmp"
"github.com/opencontainers/go-digest"
ocispec "github.com/opencontainers/image-spec/specs-go/v1"
)
@@ -32,7 +31,7 @@ func TestNormalizeImageRef(t *testing.T) {
},
} {
normalized, err := normalizeImageRef(imageBaseName, test.input)
assert.Check(t, is.NilError(err))
assert.Check(t, is.Equal(test.expect, normalized))
assert.NilError(t, err)
assert.Equal(t, test.expect, normalized)
}
}