Skip to content

Commit

Permalink
fix string parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
leej3 committed Apr 29, 2024
1 parent 205a2a3 commit 6f9390b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/run_cpu_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
set -xeu

if [ "${SKIP_DISTRIB_TESTS:-0}" -eq "1" ]; then
skip_distrib_opt=(-m "not distributed and not tpu and not multinode_distributed")
skip_distrib_opt="not distributed and not tpu and not multinode_distributed"
else
skip_distrib_opt=()
skip_distrib_opt=""
fi

MATCH_TESTS_EXPRESSION=${1:-""}
Expand All @@ -15,7 +15,7 @@ EXIT_CODE_ALL_TESTS_DESELECTED=5

CACHE_DIR=.cpu-not-distrib
echo [pytest] > pytest.ini ; echo "cache_dir=${CACHE_DIR}" >> pytest.ini
PYTEST_ARGS="--tx 4*popen//python=python --cov ignite --cov-report term-missing --cov-report xml -vvv tests ${skip_distrib_opt[@]} ${MATCH_TESTS_EXPRESSION}"
PYTEST_ARGS="--tx 4*popen//python=python --cov ignite --cov-report term-missing --cov-report xml -vvv tests -m '${skip_distrib_opt}' -k '${MATCH_TESTS_EXPRESSION}'"
if [ "${USE_LAST_FAILED:-0}" -eq "1" ] && [ -d "${CACHE_DIR}" ]; then
PYTEST_ARGS="--last-failed --last-failed-no-failures none ${PYTEST_ARGS}"
fi
Expand All @@ -29,7 +29,7 @@ fi
export WORLD_SIZE=2
CACHE_DIR=.cpu-distrib
echo [pytest] > pytest.ini ; echo "cache_dir=${CACHE_DIR}" >> pytest.ini
PYTEST_ARGS="--cov ignite --cov-append --cov-report term-missing --cov-report xml --dist=each --tx ${WORLD_SIZE}*popen//python=python tests -m distributed -vvv ${MATCH_TESTS_EXPRESSION}"
PYTEST_ARGS="--cov ignite --cov-append --cov-report term-missing --cov-report xml --dist=each --tx ${WORLD_SIZE}*popen//python=python tests -m distributed -vvv -k '${MATCH_TESTS_EXPRESSION}'"
if [ "${USE_LAST_FAILED:-0}" -eq "1" ] && [ -d "${CACHE_DIR}" ]; then
PYTEST_ARGS="--last-failed --last-failed-no-failures none ${PYTEST_ARGS}"
fi
Expand Down

0 comments on commit 6f9390b

Please sign in to comment.