diff --git a/bin/run_ci_tests.sh b/bin/run_ci_tests.sh index d2a51cf..b896a21 100755 --- a/bin/run_ci_tests.sh +++ b/bin/run_ci_tests.sh @@ -1,6 +1,6 @@ #!/bin/bash -BASE_DIR="$(mktemp -d)" +BASE_DIR="$(mktemp -d '/tmp/platypush-ci-tests-XXXXX')" VENV_DIR="$BASE_DIR/venv" REPO_DIR="$BASE_DIR/repo" TEST_LOG="$BASE_DIR/test.log" @@ -16,19 +16,18 @@ prepare_venv() { python -m venv "$VENV_DIR" cd "$VENV_DIR" source ./bin/activate + cd - } install_repo() { echo "Installing latest version of the repository" - git clone "$REPO_URL" "$REPO_DIR" - cd "$REPO_DIR" pip install '.[http]' } run_tests() { echo "Running tests" - cd "$REPO_DIR" pytest 2>&1 | tee "$TEST_LOG" + grep -e '^FAILED ' "$TEST_LOG" if [[ $? == 0 ]]; then return 2 # FAILURE