ci/pytest: make sure tests run on correct branch (MR 6418)
This works around a situation where pmbootstrap init checks out the wrong branch and we end up executing the wrong version of the tests. For context: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6418#note_477266
This commit is contained in:
parent
00919cd2c0
commit
7fd9e01f7f
1 changed files with 2 additions and 0 deletions
|
|
@ -10,6 +10,8 @@ if [ "$(id -u)" = 0 ]; then
|
|||
set -x
|
||||
wget "https://gitlab.postmarketos.org/postmarketOS/ci-common/-/raw/master/install_pmbootstrap.sh"
|
||||
sh ./install_pmbootstrap.sh pytest
|
||||
# FIXME: workaround for pmb init switching the branch on us...
|
||||
su "${TESTUSER:-pmos}" -c "git -C $CI_PROJECT_DIR checkout $CI_COMMIT_SHA"
|
||||
exec su "${TESTUSER:-pmos}" -c "sh -e $0"
|
||||
fi
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue