test: new weldr client compatibility for test scripts
- Handle the array responses from the new weldr-client (>= 35.6). - Move the `get_build_info` function to shared_libs.sh to source and reuse in multiple places.
This commit is contained in:
parent
8e24f5720d
commit
3b14828669
25 changed files with 57 additions and 247 deletions
|
|
@ -2,6 +2,8 @@
|
|||
|
||||
set -euxo pipefail
|
||||
|
||||
source /usr/libexec/tests/osbuild-composer/shared_lib.sh
|
||||
|
||||
WORKSPACE=$(mktemp -d)
|
||||
function cleanup() {
|
||||
echo "== Script execution stopped or finished - Cleaning up =="
|
||||
|
|
@ -9,15 +11,6 @@ function cleanup() {
|
|||
}
|
||||
trap cleanup EXIT
|
||||
|
||||
function get_build_info() {
|
||||
key="$1"
|
||||
fname="$2"
|
||||
if rpm -q --quiet weldr-client; then
|
||||
key=".body${key}"
|
||||
fi
|
||||
jq -r "${key}" "${fname}"
|
||||
}
|
||||
|
||||
# Get the compose log.
|
||||
get_compose_log () {
|
||||
COMPOSE_ID=$1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue