From 487835183e1ce0855db4644918995b870ce2cffe Mon Sep 17 00:00:00 2001 From: Billy Zha Date: Mon, 29 Jan 2024 09:23:04 +0000 Subject: [PATCH] fix e2e Signed-off-by: Billy Zha --- test/e2e/suite/command/cp.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/e2e/suite/command/cp.go b/test/e2e/suite/command/cp.go index 430e298fb..110c56679 100644 --- a/test/e2e/suite/command/cp.go +++ b/test/e2e/suite/command/cp.go @@ -277,12 +277,13 @@ var _ = Describe("1.1 registry users:", func() { src := RegistryRef(ZOTHost, ArtifactRepo, ma.Tag) dstRepo := cpTestRepo("platform-referrers-no-tag") dst := RegistryRef(ZOTHost, dstRepo, "") + digest := ma.LinuxAMD64.Digest.String() ORAS("cp", src, dst, "-r", "--platform", "linux/amd64", "-v"). MatchStatus(stateKeys, true, len(stateKeys)). - MatchKeyWords("Digest: " + ma.LinuxAMD64.Digest.String()). + MatchKeyWords("Digest: " + digest). Exec() // validate - CompareRef(src, RegistryRef(ZOTHost, dstRepo, ma.LinuxAMD64.Digest.String())) + CompareRef(RegistryRef(ZOTHost, ArtifactRepo, digest), RegistryRef(ZOTHost, dstRepo, digest)) digests := ORAS("discover", dst, "--format", "{{range .Manifests}}{{println .Digest}}{{end}}").Exec().Out.Contents() for _, digest := range strings.Split(strings.TrimSpace(string(digests)), "\n") { CompareRef(RegistryRef(ZOTHost, ArtifactRepo, digest), RegistryRef(ZOTHost, dstRepo, digest))