From: Jérémie Astor Date: Sat, 7 Dec 2019 13:28:07 +0000 (+0100) Subject: :art: Fix tuple printfxxx X-Git-Tag: nightly~2021 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=b90bc486ca63529e94fedeb236fdbab4143dbbb2;p=gwion.git :art: Fix tuple printfxxx --- diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index e2a6a6f9..789611bb 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -30,5 +30,6 @@ jobs: echo "::set-env name=test_dir::${{ runner.temp }}\test" echo "::set-env name=VALGRIND::NO_VALGRIND" echo "::set-env name=SEVERITY::3" + echo "::set-env name=separator::\" mkdir ${{ env.test_dir }} make VALGRIND=NO_VALGRIND SEVERITY=3 GWION_TEST_DIR=${{ env.test_dir }} test diff --git a/scripts/test.sh b/scripts/test.sh index c996e29c..3ed65824 100644 --- a/scripts/test.sh +++ b/scripts/test.sh @@ -20,6 +20,10 @@ : "${SEVERITY:=11}" : "${severity:=$SEVERITY}" + +: "${separator:=/}" + + assert_returns() { [ "$1" -eq 0 ] && return 0 [ "$1" -eq 139 ] && echo "segfault" > "$2" @@ -176,11 +180,11 @@ test_gw(){ local n file log ret n=$2 file=$1 - log=${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$n") - slog=${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$n").std.log - elog=${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$n").err.log - vlog=${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$n").valgrind.log - rlog=${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$n").log + log=${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$n") + slog=${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$n").std.log + elog=${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$n").err.log + vlog=${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$n").valgrind.log + rlog=${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$n").log if [ "$VALGRIND" == "NO_VALGRIND" ] then LANG=C ./"$PRG" "$GWOPT" -d "$DRIVER" "$file" > "$slog" 2>"$elog" |: else @@ -277,7 +281,7 @@ test_dir() { wait for i in $(seq "$offset" "$n") do - read_test "${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$i").log" + read_test "${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$i").log" done offset=$((offset + async)); fi @@ -289,7 +293,7 @@ test_dir() { wait local rest=$(( $((n-base-1)) %async)) for i in $(seq $((n-rest)) $((n-1))) - do read_test "${GWION_TEST_DIR}/${GWION_TEST_PREFIX}$(printf "%04i" "$i").log" + do read_test "${GWION_TEST_DIR}${separator}${GWION_TEST_PREFIX}$(printf "%04i" "$i").log" done } fi @@ -462,7 +466,7 @@ consummer() { } clean() { - rm -f ${GWION_TEST_DIR}/{${GWION_TEST_PREFIX}{*.log,bailout},In.gw} + rm -f ${GWION_TEST_DIR}${separator}{${GWION_TEST_PREFIX}{*.log,bailout},In.gw} } [ -f test.log ] && rm test.log