gitlab/azure: Use -w flag for all test.py builds
Avoid needing to know about the internal .bm-work directory, by passing the -w flag to buildman. This is not needed on travis since the -w flag is already used (from a previous patch). Drop the -P flag since this has no effect if -w is used. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
parent
5bd95d63d1
commit
4e32fed4d3
|
@ -264,16 +264,16 @@ jobs:
|
||||||
fi
|
fi
|
||||||
# the below corresponds to .gitlab-ci.yml "script"
|
# the below corresponds to .gitlab-ci.yml "script"
|
||||||
cd ${WORK_DIR}
|
cd ${WORK_DIR}
|
||||||
|
export UBOOT_TRAVIS_BUILD_DIR=/tmp/${TEST_PY_BD};
|
||||||
ret=0;
|
ret=0;
|
||||||
tools/buildman/buildman -o /tmp -P -E --board ${TEST_PY_BD} ${OVERRIDE} || ret=$?;
|
tools/buildman/buildman -o ${UBOOT_TRAVIS_BUILD_DIR} -w -E --board ${TEST_PY_BD} ${OVERRIDE} || ret=$?;
|
||||||
if [[ $ret -ne 0 && $ret -ne 129 ]]; then
|
if [[ $ret -ne 0 && $ret -ne 129 ]]; then
|
||||||
tools/buildman/buildman -o /tmp -seP --board ${TEST_PY_BD};
|
tools/buildman/buildman -o ${UBOOT_TRAVIS_BUILD_DIR} -w -se --board ${TEST_PY_BD};
|
||||||
exit $ret;
|
exit $ret;
|
||||||
fi
|
fi
|
||||||
virtualenv -p /usr/bin/python3 /tmp/venv
|
virtualenv -p /usr/bin/python3 /tmp/venv
|
||||||
. /tmp/venv/bin/activate
|
. /tmp/venv/bin/activate
|
||||||
pip install -r test/py/requirements.txt
|
pip install -r test/py/requirements.txt
|
||||||
export UBOOT_TRAVIS_BUILD_DIR=/tmp/.bm-work/${TEST_PY_BD};
|
|
||||||
export PATH=/opt/qemu/bin:/tmp/uboot-test-hooks/bin:${PATH};
|
export PATH=/opt/qemu/bin:/tmp/uboot-test-hooks/bin:${PATH};
|
||||||
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} -k "${TEST_PY_TEST_SPEC:-not a_test_which_does_not_exist}" --build-dir "$UBOOT_TRAVIS_BUILD_DIR";
|
./test/py/test.py --bd ${TEST_PY_BD} ${TEST_PY_ID} -k "${TEST_PY_TEST_SPEC:-not a_test_which_does_not_exist}" --build-dir "$UBOOT_TRAVIS_BUILD_DIR";
|
||||||
|
|
|
@ -38,11 +38,13 @@ stages:
|
||||||
script:
|
script:
|
||||||
# From buildman, exit code 129 means warnings only. If we've been asked to
|
# From buildman, exit code 129 means warnings only. If we've been asked to
|
||||||
# use clang only do one configuration.
|
# use clang only do one configuration.
|
||||||
|
- export UBOOT_TRAVIS_BUILD_DIR=/tmp/${TEST_PY_BD}
|
||||||
- ret=0;
|
- ret=0;
|
||||||
tools/buildman/buildman -o /tmp -P -E --board ${TEST_PY_BD} ${OVERRIDE}
|
tools/buildman/buildman -o ${UBOOT_TRAVIS_BUILD_DIR} -w -E
|
||||||
|| ret=$?;
|
--board ${TEST_PY_BD} ${OVERRIDE} || ret=$?;
|
||||||
if [[ $ret -ne 0 && $ret -ne 129 ]]; then
|
if [[ $ret -ne 0 && $ret -ne 129 ]]; then
|
||||||
tools/buildman/buildman -o /tmp -seP --board ${TEST_PY_BD};
|
tools/buildman/buildman -o ${UBOOT_TRAVIS_BUILD_DIR} -w -se
|
||||||
|
--board ${TEST_PY_BD};
|
||||||
exit $ret;
|
exit $ret;
|
||||||
fi
|
fi
|
||||||
# "not a_test_which_does_not_exist" is a dummy -k parameter which will
|
# "not a_test_which_does_not_exist" is a dummy -k parameter which will
|
||||||
|
@ -52,8 +54,7 @@ stages:
|
||||||
- virtualenv -p /usr/bin/python3 /tmp/venv
|
- virtualenv -p /usr/bin/python3 /tmp/venv
|
||||||
- . /tmp/venv/bin/activate
|
- . /tmp/venv/bin/activate
|
||||||
- pip install -r test/py/requirements.txt
|
- pip install -r test/py/requirements.txt
|
||||||
- export UBOOT_TRAVIS_BUILD_DIR=/tmp/.bm-work/${TEST_PY_BD};
|
- export PATH=/opt/qemu/bin:/tmp/uboot-test-hooks/bin:${PATH};
|
||||||
export PATH=/opt/qemu/bin:/tmp/uboot-test-hooks/bin:${PATH};
|
|
||||||
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}
|
||||||
-k "${TEST_PY_TEST_SPEC:-not a_test_which_does_not_exist}"
|
-k "${TEST_PY_TEST_SPEC:-not a_test_which_does_not_exist}"
|
||||||
|
|
Loading…
Reference in New Issue