From 592f605cadb21ab58b940d97e10ae093ef5b752f Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Thu, 4 May 2023 00:31:03 +0200 Subject: [PATCH] Fixed `run_tests` --- bin/run_ci_tests.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/bin/run_ci_tests.sh b/bin/run_ci_tests.sh index bc0e2e7..68d13b6 100755 --- a/bin/run_ci_tests.sh +++ b/bin/run_ci_tests.sh @@ -2,9 +2,8 @@ BASE_DIR="$(mktemp -d '/tmp/platypush-ci-tests-XXXXX')" VENV_DIR="$BASE_DIR/venv" -REPO_DIR="$BASE_DIR/repo" +REPO_DIR="/opt/repos/platypush" TEST_LOG="$BASE_DIR/test.log" -REPO_URL=https://git.platypush.tech/platypush/platypush.git cleanup() { echo "Cleaning up environment" @@ -21,11 +20,14 @@ prepare_venv() { install_repo() { echo "Installing latest version of the repository" + cd "$REPO_DIR" pip install '.[http]' + cd - } run_tests() { echo "Running tests" + cd "$REPO_DIR" pytest 2>&1 | tee "$TEST_LOG" deactivate @@ -34,6 +36,7 @@ run_tests() { return 2 # FAILURE fi + cd - return 0 # PASSED }