tests: use -z / -n to test for string empty / non-empty
[babeltrace.git] / tests / plugins / sink.text.pretty / test_enum
index ed241c3b39cac53722e878b30f54e6cd2e2bc796..723448b72ea85768ed828866f5a7704892869c29 100755 (executable)
@@ -8,7 +8,7 @@
 # not all covered by the main babeltrace tests with traces.
 SH_TAP=1
 
-if [ "x${BT_TESTS_SRCDIR:-}" != "x" ]; then
+if [ -n "${BT_TESTS_SRCDIR:-}" ]; then
        UTILSSH="$BT_TESTS_SRCDIR/utils/utils.sh"
 else
        UTILSSH="$(dirname "$0")/../../utils/utils.sh"
@@ -36,7 +36,7 @@ function compare_enum_sorted
        # data structures differently (e.g. dictionaries are insertion sorted
        # since Python 3.7).
 
-       run_python_bt2 python3 "${BT_TESTS_SRCDIR}/utils/python/split_sort_compare.py" \
+       run_python_bt2 "${BT_TESTS_PYTHON_BIN}" "${BT_TESTS_SRCDIR}/utils/python/split_sort_compare.py" \
                "$(cat $expected_file)" "$(cat $actual_file)"
 }
 
This page took 0.023912 seconds and 4 git commands to generate.