Conditionally skip container test when using older osbuild version
Introduced in https://github.com/osbuild/osbuild-composer/pull/3336
This commit is contained in:
parent
3686223a40
commit
2c23894e2a
2 changed files with 18 additions and 0 deletions
|
|
@ -141,6 +141,11 @@ else
|
|||
exit 1
|
||||
fi
|
||||
|
||||
if ! nvrGreaterOrEqual "osbuild" "83"; then
|
||||
echo "INFO: osbuild version is older. Exiting test here"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Check that the local name was set in the names array
|
||||
FEDORA_NAME_EXISTS=$(jq -e --arg name "${FEDORA_LOCAL_NAME}" 'any(."container-images"[].Names[] | select(. != null and . == $name); .)' <<< "${INFO}")
|
||||
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ set -euo pipefail
|
|||
|
||||
# Get OS and architecture details.
|
||||
source /usr/libexec/osbuild-composer-test/set-env-variables.sh
|
||||
source /usr/libexec/tests/osbuild-composer/shared_lib.sh
|
||||
|
||||
if [[ -n "$CI_BUILD_ID" ]]; then
|
||||
BUILD_ID="${BUILD_ID:-${CI_BUILD_ID}}"
|
||||
|
|
@ -57,6 +58,18 @@ get_test_cases () {
|
|||
else
|
||||
SKIP_CASES=("${SKIP_OSTREE[@]}")
|
||||
fi
|
||||
|
||||
# skip container test if running on old osbuild version
|
||||
# b/c manifests have been modified to include the
|
||||
# "manifest-lists" and "skopeo-index" options which are
|
||||
# not yet supported on 8.8 and 9.2 downstream
|
||||
if nvrGreaterOrEqual "osbuild" "83"; then
|
||||
echo
|
||||
else
|
||||
SKIP_ME=$(grep edge_commit_with_container-boot <<< "$ALL_CASES")
|
||||
SKIP_CASES=("${SKIP_CASES[@]}" "$SKIP_ME")
|
||||
fi
|
||||
|
||||
mapfile -t TEST_CASES < <(grep -vxFf <(printf '%s\n' "${SKIP_CASES[@]}") <(printf '%s\n' "${ALL_CASES[@]}"))
|
||||
echo "${TEST_CASES[@]}"
|
||||
popd > /dev/null
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue