integration/image: pull ppc64le and s390x in TestSaveAndLoadPlatform

When savePlatforms is nil, ImageSave exports all platforms referenced
in the image index. On ppc64le and s390x hosts, this includes the
native platform which was never pulled, causing a "content digest not
found" error.

Pull ppc64le and s390x alongside the other platforms so their content
is available in the local store when the full-index save is attempted.

Signed-off-by: Ricardo Branco <rbranco@suse.de>
This commit is contained in:
Ricardo Branco
2026-02-28 00:19:19 +01:00
parent 1e418bd6ec
commit 425bc6efcb

View File

@@ -235,19 +235,25 @@ func TestSaveAndLoadPlatform(t *testing.T) {
containerdStoreOnly: true,
pullPlatforms: []ocispec.Platform{
{OS: "linux", Architecture: "amd64"},
{OS: "linux", Architecture: "ppc64le"},
{OS: "linux", Architecture: "riscv64"},
{OS: "linux", Architecture: "s390x"},
{OS: "linux", Architecture: "arm64", Variant: "v8"},
},
savePlatforms: nil,
loadPlatforms: nil,
expectedSavedPlatforms: []ocispec.Platform{
{OS: "linux", Architecture: "amd64"},
{OS: "linux", Architecture: "ppc64le"},
{OS: "linux", Architecture: "riscv64"},
{OS: "linux", Architecture: "s390x"},
{OS: "linux", Architecture: "arm64", Variant: "v8"},
},
expectedLoadedPlatforms: []ocispec.Platform{
{OS: "linux", Architecture: "amd64"},
{OS: "linux", Architecture: "ppc64le"},
{OS: "linux", Architecture: "riscv64"},
{OS: "linux", Architecture: "s390x"},
{OS: "linux", Architecture: "arm64", Variant: "v8"},
},
},