From a9aa8788e0b4a05cbca04c4509705710ba63049c Mon Sep 17 00:00:00 2001 From: Hans-Christoph Steiner Date: Wed, 3 Jul 2019 22:33:01 +0200 Subject: [PATCH] tests: only run source tarball test if running from git clone --- tests/run-tests | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/tests/run-tests b/tests/run-tests index 353005e1..742a1cfc 100755 --- a/tests/run-tests +++ b/tests/run-tests @@ -636,19 +636,21 @@ $fdroid install || true #------------------------------------------------------------------------------# -echo_header "create a source tarball" +# only run this test if running from a git repo, not all files are in the tarball +if [ -e .git/config ]; then + echo_header "create a source tarball" -cd $WORKSPACE -./setup.py compile_catalog sdist - -REPOROOT=`create_test_dir` -cd $REPOROOT -tar xzf `ls -1 $WORKSPACE/dist/fdroidserver-*.tar.gz | sort -n | tail -1` -cd $REPOROOT -./fdroidserver-*/fdroid init -copy_apks_into_repo $REPOROOT -./fdroidserver-*/fdroid update --create-metadata --verbose + cd $WORKSPACE + ./setup.py compile_catalog sdist + REPOROOT=`create_test_dir` + cd $REPOROOT + tar xzf `ls -1 $WORKSPACE/dist/fdroidserver-*.tar.gz | sort -n | tail -1` + cd $REPOROOT + ./fdroidserver-*/fdroid init + copy_apks_into_repo $REPOROOT + ./fdroidserver-*/fdroid update --create-metadata --verbose +fi #------------------------------------------------------------------------------# echo_header "test config checks of local_copy_dir"