tests/image-tests: filter out cases with ostree URL
These tests depend on external dependencies which are difficult to setup during image-test like http ostree repository. See https://github.com/osbuild/osbuild-composer/pull/2389#issuecomment-1060338127 for more details.
This commit is contained in:
parent
e147e41879
commit
ae07093404
1 changed files with 7 additions and 1 deletions
|
|
@ -42,10 +42,16 @@ test_divider () {
|
|||
}
|
||||
|
||||
# Get a list of test cases.
|
||||
# Exclude test cases that require external dependencies like a http ostree repo.
|
||||
# These manifests exist only for correct manifest creation testing and cannot
|
||||
# be built during this test.
|
||||
get_test_cases () {
|
||||
TEST_CASE_SELECTOR="${DISTRO_CODE/-/_}-${ARCH}"
|
||||
pushd $IMAGE_TEST_CASES_PATH > /dev/null
|
||||
ls "$TEST_CASE_SELECTOR"*.json
|
||||
ALL_CASES=$(ls "$TEST_CASE_SELECTOR"*.json)
|
||||
SKIP_CASES=$(jq -r 'if (.manifest.sources."org.osbuild.ostree" != null) then input_filename else empty end' "${TEST_CASE_SELECTOR}"*.json)
|
||||
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