Fixes review comments

Use correct acronym for OCI resources

Signed-off-by: James Payne <jamoflaw@gmail.com>
pull/30826/head
James Payne 3 months ago
parent da26816c56
commit 634aa31c1f

@ -280,28 +280,28 @@ func TestIsOCI(t *testing.T) {
tests := []struct {
name string
url string
uri string
isValid bool
}{
{
name: "Valid url",
url: "oci://example.com/myregistry:1.2.3",
name: "Valid URI",
uri: "oci://example.com/myregistry:1.2.3",
isValid: true,
},
{
name: "Invalid URL prefix (boundary test 1)",
url: "noci://example.com/myregistry:1.2.3",
name: "Invalid URI prefix (boundary test 1)",
uri: "noci://example.com/myregistry:1.2.3",
isValid: false,
},
{
name: "Invalid URL prefix (boundary test 2)",
url: "ocin://example.com/myregistry:1.2.3",
name: "Invalid URI prefix (boundary test 2)",
uri: "ocin://example.com/myregistry:1.2.3",
isValid: false,
},
}
for _, tt := range tests {
assert.Equal(t, tt.isValid, IsOCI(tt.url), tt.name)
assert.Equal(t, tt.isValid, IsOCI(tt.uri), tt.name)
}
}

Loading…
Cancel
Save