mirror of
https://github.com/project-zot/zot.git
synced 2026-06-17 21:17:58 +08:00
fix: minor fixes based on intermittent test failures (#3465)
1. preload busybox image to fix: https://github.com/project-zot/zot/actions/runs/18614431126/job/53077015870?pr=3465 2. stabilize test coverage in by using different error type: https://app.codecov.io/gh/project-zot/zot/pull/3444/indirect-changes 3. attempt to fx an intermitent sync test failure: Failures: * /home/andaaron/zot/pkg/extensions/sync/sync_test.go Line 4857: Expected: digest.Digest("sha256:dc1377539a9db8bf077100bfa3118052feb6b5c67509ca09bdd841e4ac14c4cc") Actual: digest.Digest("sha256:3a3fb31a422846a680f0a07b8b666bdcb1122d912d1adca79523c7bf2715996e") (Should equal)! 4. fix a race condition in sync by, I don't have a link, but this is the failure: * zotregistry.dev/zot/pkg/extensions/sync/sync_test.go Line 5963: Expected: 1 Actual: 2 (Should equal)! 1426 total assertions --- FAIL: TestOnDemandPullsOnce (0.42s) sync_test.go:5921: Goroutine 0: Sending request to http://127.0.0.1:36421/v2/zot-test/manifests/0.0.1 sync_test.go:5921: Goroutine 1: Sending request to http://127.0.0.1:36421/v2/zot-test/manifests/0.0.1 sync_test.go:5921: Goroutine 4: Sending request to http://127.0.0.1:36421/v2/zot-test/manifests/0.0.1 sync_test.go:5921: Goroutine 3: Sending request to http://127.0.0.1:36421/v2/zot-test/manifests/0.0.1 sync_test.go:5921: Goroutine 2: Sending request to http://127.0.0.1:36421/v2/zot-test/manifests/0.0.1 FAIL coverage: 21.4% of statements in ./... FAIL zotregistry.dev/zot/pkg/extensions/sync 255.189s 5. Fix flaky coverage in https://app.codecov.io/gh/project-zot/zot/pull/3465/indirect-changes 6. Stability fix for https://github.com/project-zot/zot/actions/runs/18632536285/job/53119244557?pr=3465 Signed-off-by: Andrei Aaron <andreifdaaron@gmail.com>
This commit is contained in:
@@ -377,7 +377,7 @@ EOF
|
||||
@test "push docker image" {
|
||||
zot_port=`cat ${BATS_FILE_TMPDIR}/zot.port`
|
||||
cat > Dockerfile <<EOF
|
||||
FROM public.ecr.aws/docker/library/busybox:latest
|
||||
FROM ghcr.io/project-zot/test-images/busybox-docker:1.37
|
||||
RUN echo "hello world" > /testfile
|
||||
EOF
|
||||
docker build -f Dockerfile . -t localhost:${zot_port}/test
|
||||
|
||||
Reference in New Issue
Block a user