mirror of
https://xff.cz/git/u-boot/
synced 2025-08-31 16:22:36 +02:00
travis/gitlab/azure: Simplify the exit code for test.py
It seems unnecessary to read the exit code and then check it again. Drop this and just let the test.py provide the exit code directly. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
@@ -278,10 +278,6 @@ jobs:
|
|||||||
export PYTHONPATH=/tmp/uboot-test-hooks/py/travis-ci;
|
export PYTHONPATH=/tmp/uboot-test-hooks/py/travis-ci;
|
||||||
# "${var:+"-k $var"}" expands to "" if $var is empty, "-k $var" if not
|
# "${var:+"-k $var"}" expands to "" if $var is empty, "-k $var" if not
|
||||||
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID} ${TEST_PY_TEST_SPEC:+"-k ${TEST_PY_TEST_SPEC}"} --build-dir "$UBOOT_TRAVIS_BUILD_DIR";
|
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID} ${TEST_PY_TEST_SPEC:+"-k ${TEST_PY_TEST_SPEC}"} --build-dir "$UBOOT_TRAVIS_BUILD_DIR";
|
||||||
ret=$?;
|
|
||||||
if [[ $ret -ne 0 ]]; then
|
|
||||||
exit $ret;
|
|
||||||
fi
|
|
||||||
# the below corresponds to .gitlab-ci.yml "after_script"
|
# the below corresponds to .gitlab-ci.yml "after_script"
|
||||||
rm -rf /tmp/uboot-test-hooks /tmp/venv
|
rm -rf /tmp/uboot-test-hooks /tmp/venv
|
||||||
EOF
|
EOF
|
||||||
|
@@ -54,11 +54,7 @@ stages:
|
|||||||
export PYTHONPATH=/tmp/uboot-test-hooks/py/travis-ci;
|
export PYTHONPATH=/tmp/uboot-test-hooks/py/travis-ci;
|
||||||
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID}
|
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID}
|
||||||
${TEST_PY_TEST_SPEC:+"-k ${TEST_PY_TEST_SPEC}"}
|
${TEST_PY_TEST_SPEC:+"-k ${TEST_PY_TEST_SPEC}"}
|
||||||
--build-dir "$UBOOT_TRAVIS_BUILD_DIR";
|
--build-dir "$UBOOT_TRAVIS_BUILD_DIR"
|
||||||
ret=$?;
|
|
||||||
if [[ $ret -ne 0 ]]; then
|
|
||||||
exit $ret;
|
|
||||||
fi
|
|
||||||
|
|
||||||
build all 32bit ARM platforms:
|
build all 32bit ARM platforms:
|
||||||
tags: [ 'all' ]
|
tags: [ 'all' ]
|
||||||
|
@@ -245,11 +245,7 @@ script:
|
|||||||
pip install -r test/py/requirements.txt;
|
pip install -r test/py/requirements.txt;
|
||||||
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID}
|
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID}
|
||||||
${TEST_PY_TEST_SPEC:+"-k ${TEST_PY_TEST_SPEC}"}
|
${TEST_PY_TEST_SPEC:+"-k ${TEST_PY_TEST_SPEC}"}
|
||||||
--build-dir "$UBOOT_TRAVIS_BUILD_DIR";
|
--build-dir "$UBOOT_TRAVIS_BUILD_DIR" || exit;
|
||||||
ret=$?;
|
|
||||||
if [[ $ret -ne 0 ]]; then
|
|
||||||
exit $ret;
|
|
||||||
fi;
|
|
||||||
if [[ -n "${TEST_PY_TOOLS}" ]]; then
|
if [[ -n "${TEST_PY_TOOLS}" ]]; then
|
||||||
export PYTHONPATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc/pylibfdt";
|
export PYTHONPATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc/pylibfdt";
|
||||||
export PATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc:${PATH}";
|
export PATH="${UBOOT_TRAVIS_BUILD_DIR}/scripts/dtc:${PATH}";
|
||||||
|
Reference in New Issue
Block a user