Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: project-zot/zot
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 2d66cb5040ee267cc083f15f4218da3df7c8c0e8
Choose a base ref
..
head repository: project-zot/zot
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 4750b9a7b28145c1dd20e45655e202239f94a4f3
Choose a head ref
Showing with 3 additions and 3 deletions.
  1. +3 −3 test/blackbox/pushpull.bats
6 changes: 3 additions & 3 deletions test/blackbox/pushpull.bats
Original file line number Diff line number Diff line change
@@ -149,17 +149,17 @@ function teardown_file() {
zot_port=`cat ${BATS_FILE_TMPDIR}/zot.port`
# attach signature
echo "{\"artifact\": \"\", \"signature\": \"pat hancock\"}" > ${BATS_FILE_TMPDIR}/signature.json
run oras attach --plain-http 127.0.0.1:${zot_port}/golang:1.20 --image-spec v1.1-image --artifact-type 'signature/example' ${BATS_FILE_TMPDIR}/signature.json:application/json
run oras attach --disable-path-validation --plain-http 127.0.0.1:${zot_port}/golang:1.20 --artifact-type 'signature/example' ${BATS_FILE_TMPDIR}/signature.json:application/json
[ "$status" -eq 0 ]
# attach sbom
echo "{\"version\": \"0.0.0.0\", \"artifact\": \"'127.0.0.1:${zot_port}/golang:1.20'\", \"contents\": \"good\"}" > ${BATS_FILE_TMPDIR}/sbom.json
run oras attach --plain-http 127.0.0.1:${zot_port}/golang:1.20 --image-spec v1.1-image --artifact-type 'sbom/example' ${BATS_FILE_TMPDIR}/sbom.json:application/json
run oras attach --disable-path-validation --plain-http 127.0.0.1:${zot_port}/golang:1.20 --artifact-type 'sbom/example' ${BATS_FILE_TMPDIR}/sbom.json:application/json
[ "$status" -eq 0 ]
}

@test "discover oras artifacts" {
zot_port=`cat ${BATS_FILE_TMPDIR}/zot.port`
run oras discover --plain-http -o json 127.0.0.1:${zot_port}/golang:1.20
run oras discover --plain-http --format json 127.0.0.1:${zot_port}/golang:1.20
[ "$status" -eq 0 ]
[ $(echo "$output" | jq -r ".manifests | length") -eq 2 ]
}