Skip to content

Commit

Permalink
avoid duplicate tests
Browse files Browse the repository at this point in the history
  • Loading branch information
pierky committed Oct 13, 2017
1 parent e4549ec commit a62fc65
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
4 changes: 1 addition & 3 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,7 @@
envlist=py34-syntax, py27-flake8, py34-flake8, py27, py34, py27-coverage

[testenv]
commands=
nosetests -vs -x tests/static/
nosetests -vs -x tests/live_tests/
commands=nosetests -vs -x --tests=tests/static/,tests/live_tests/
deps=nose
passenv=TRAVIS BUILD_ONLY

Expand Down
4 changes: 2 additions & 2 deletions utils/update_real_tests
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ function join_last_results() {
function build() {
IXP_ID="$1"
DAEMON="$2"
nosetests -vs $TESTS_DIR/test_${IXP_ID}.py -m "test_${DAEMON}.*_010_build" 2>&1 | tee $LAST_RESULTS_DIR/test_${IXP_ID}.py.build.$DAEMON
nosetests -vs --tests=$TESTS_DIR/test_${IXP_ID}.py -m "test_${DAEMON}.*_010_build" 2>&1 | tee $LAST_RESULTS_DIR/test_${IXP_ID}.py.build.$DAEMON
}

function load() {
Expand All @@ -132,7 +132,7 @@ function load() {
if [ -n "$3" ]; then
echo "Using remote host $3"
fi
REMOTE_IP="$3" nosetests -vs $TESTS_DIR/test_${IXP_ID}.py -m "test_${DAEMON}.*_020_load" 2>&1 | tee $LAST_RESULTS_DIR/test_${IXP_ID}.py.load.$DAEMON
REMOTE_IP="$3" nosetests -vs --tests=$TESTS_DIR/test_${IXP_ID}.py -m "test_${DAEMON}.*_020_load" 2>&1 | tee $LAST_RESULTS_DIR/test_${IXP_ID}.py.load.$DAEMON
}

function vultr_get_sshkeyid() {
Expand Down
6 changes: 3 additions & 3 deletions utils/update_tests
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,11 @@ fi

if [[ -z "$1" || `echo "$1" | grep -P "\bstatic\b"` ]]; then
echo "Running static tests..."
nosetests -vs -x $TESTS_DIR/static 2>&1 | tee $LAST_RESULTS_DIR/static.last
nosetests -vs -x --tests=$TESTS_DIR/static 2>&1 | tee $LAST_RESULTS_DIR/static.last
fi

echo "Testing live scenarios with BUILD_ONLY=1..."
BUILD_ONLY=1 nosetests -vs -x $TESTS_DIR/live_tests
BUILD_ONLY=1 nosetests -vs -x --tests=$TESTS_DIR/live_tests

echo "Running live tests..."
for d in $TESTS_DIR/live_tests/scenarios/*; do
Expand All @@ -89,7 +89,7 @@ for d in $TESTS_DIR/live_tests/scenarios/*; do
if [[ -z "$1" || `echo "$1" | grep -P "\b$LIVE_TEST_NAME\b"` ]]; then
echo " - live test: $LIVE_TEST_NAME"
TARGET_FILE="live_$LIVE_TEST_NAME.last"
nosetests -vs -x $d 2>&1 | tee $LAST_RESULTS_DIR/$TARGET_FILE
nosetests -vs -x --tests=$d 2>&1 | tee $LAST_RESULTS_DIR/$TARGET_FILE
fi
fi
done
Expand Down

0 comments on commit a62fc65

Please sign in to comment.