run-tests: always cleanup testfiles

This commit is contained in:
Jochen Sprickerhof 2022-11-25 11:32:15 +01:00 committed by Hans-Christoph Steiner
parent 6ba40b7349
commit b1fca3f722
1 changed files with 11 additions and 5 deletions

View File

@ -80,6 +80,17 @@ exit(c.get('apksigner') is None)
"
}
err_handler() {
# remove this to prevent git conflicts and complaining
rm -rf "$WORKSPACE"/fdroidserver.egg-info/
rm -rf "$WORKSPACE"/.testfiles/run-tests.*
rm -rf "$WORKSPACE"/.testfiles/test_*
rm -f "$WORKSPACE"/.testfiles/tmp.*
rmdir --ignore-fail-on-non-empty "$WORKSPACE"/.testfiles
}
trap err_handler INT EXIT
#------------------------------------------------------------------------------#
# "main"
@ -1427,9 +1438,4 @@ grep "CurrentVersionCode: 1" metadata/fake.yml
unset GIT_ALLOW_PROTOCOL
#------------------------------------------------------------------------------#
# remove this to prevent git conflicts and complaining
rm -rf $WORKSPACE/fdroidserver.egg-info/
echo SUCCESS