Normalize parallelization parameter.

This commit is contained in:
Chris Hunt 2019-10-29 02:04:55 -04:00
parent 3ff414be9f
commit a7edcc730e
4 changed files with 10 additions and 10 deletions

View File

@ -64,8 +64,8 @@ test_script:
subst T: $env:TEMP
$env:TEMP = "T:\"
$env:TMP = "T:\"
tox -e py -- -m unit
tox -e py -- -m unit -n auto
if ($LastExitCode -eq 0 -and $env:RUN_INTEGRATION_TESTS -eq "True") {
tox -e py -- --use-venv -m integration -n2 --durations=20
tox -e py -- --use-venv -m integration -n auto --durations=20
}
}

View File

@ -27,7 +27,7 @@ steps:
- bash: pip install --upgrade setuptools tox
displayName: Install Tox
- script: tox -e py -- -m unit -n 3 --junit-xml=junit/unit-test.xml
- script: tox -e py -- -m unit -n auto --junit-xml=junit/unit-test.xml
env:
TEMP: "R:\\Temp"
displayName: Tox run unit tests
@ -43,7 +43,7 @@ steps:
# https://bugs.python.org/issue18199
$env:TEMP = "R:\Temp"
tox -e py -- -m integration -n 3 --duration=5 --junit-xml=junit/integration-test.xml
tox -e py -- -m integration -n auto --duration=5 --junit-xml=junit/integration-test.xml
displayName: Tox run integration tests
- task: PublishTestResults@2

View File

@ -7,14 +7,14 @@ steps:
- bash: pip install --upgrade setuptools tox
displayName: Install Tox
- script: tox -e py -- -m unit --junit-xml=junit/unit-test.xml
- script: tox -e py -- -m unit -n auto --junit-xml=junit/unit-test.xml
displayName: Tox run unit tests
# Run integration tests in two groups so we will fail faster if there is a failure in the first group
- script: tox -e py -- -m integration -n 4 --duration=5 -k "not test_install" --junit-xml=junit/integration-test-group0.xml
- script: tox -e py -- -m integration -n auto --duration=5 -k "not test_install" --junit-xml=junit/integration-test-group0.xml
displayName: Tox run Group 0 integration tests
- script: tox -e py -- -m integration -n 4 --duration=5 -k "test_install" --junit-xml=junit/integration-test-group1.xml
- script: tox -e py -- -m integration -n auto --duration=5 -k "test_install" --junit-xml=junit/integration-test-group1.xml
displayName: Tox run Group 1 integration tests
- task: PublishTestResults@2

View File

@ -41,12 +41,12 @@ echo "TOXENV=${TOXENV}"
set -x
if [[ "$GROUP" == "1" ]]; then
# Unit tests
tox -- --use-venv -m unit
tox -- --use-venv -m unit -n auto
# Integration tests (not the ones for 'pip install')
tox -- --use-venv -m integration -n 4 --duration=5 -k "not test_install"
tox -- --use-venv -m integration -n auto --duration=5 -k "not test_install"
elif [[ "$GROUP" == "2" ]]; then
# Separate Job for running integration tests for 'pip install'
tox -- --use-venv -m integration -n 4 --duration=5 -k "test_install"
tox -- --use-venv -m integration -n auto --duration=5 -k "test_install"
else
# Non-Testing Jobs should run once
tox