Skip to content

Commit 6540d87

Browse files
committed
Fix TestOCI1IndexChooseInstanceByCompression on non-amd64
Setting SystemContext.ArchitectureChoice to "" does not mean "match any/the first platform"; it's the default behavior of SystemContext, and it means "choose for the current runtime architecture". (Originally discussed in containers#1789 (comment) ) I.e. on amd64 these two test cases are redundant with the first two instances above, and on other architectures (notably ARM) they cause failures. So just drop them. Signed-off-by: Miloslav Trmač <mitr@redhat.com>
1 parent 26afd95 commit 6540d87

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

internal/manifest/oci_index_test.go

-4
Original file line numberDiff line numberDiff line change
@@ -213,10 +213,6 @@ func TestOCI1IndexChooseInstanceByCompression(t *testing.T) {
213213
{"arm64", "", "sha256:6dc14a60d2ba724646cfbf5fccbb9a618a5978a64a352e060b17caf5e005da9d", true},
214214
// must return first zstd even if the first entry for same platform is gzip
215215
{"arm64", "", "sha256:1c98002b30a71b08ab175915ce7c8fb8da9e9b502ae082d6f0c572bac9dee324", false},
216-
// must return first zstd instance agnostic of platform
217-
{"", "", "sha256:cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc", false},
218-
// must return first gzip instance agnostic of platform
219-
{"", "", "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", true},
220216
// must return first zstd instance with no platform
221217
{"matchesImageWithNoPlatform", "", "sha256:f2f5f52a2cf2c51d4cac6df0545f751c0adc3f3427eb47c59fcb32894503e18f", false},
222218
// must return first gzip instance with no platform

0 commit comments

Comments
 (0)