summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.appveyor.yml69
-rw-r--r--.azure-pipelines/jobs/test-windows.yml11
-rw-r--r--.azure-pipelines/steps/run-tests-windows.yml6
3 files changed, 15 insertions, 71 deletions
diff --git a/.appveyor.yml b/.appveyor.yml
deleted file mode 100644
index 0da6202b2..000000000
--- a/.appveyor.yml
+++ /dev/null
@@ -1,69 +0,0 @@
-environment:
- matrix:
- # Unit and integration tests.
- - PYTHON: "C:\\Python27-x64"
- RUN_INTEGRATION_TESTS: "True"
- - PYTHON: "C:\\Python36-x64"
- RUN_INTEGRATION_TESTS: "True"
- # Unit tests only.
- # Nothing for the moment
-
-matrix:
- fast_finish: true
-
-clone_depth: 50
-
-install:
- - "SET PATH=%PYTHON%;%PYTHON%\\Scripts;%PATH%"
- - "python --version"
- - "python -m pip install --upgrade --disable-pip-version-check pip setuptools wheel"
- - "pip install --upgrade certifi tox tox-venv"
- - "pip freeze --all"
- # Fix git SSL errors.
- - "python -m certifi >cacert.txt"
- - "set /p GIT_SSL_CAINFO=<cacert.txt"
- - "set GIT_SSL_CAINFO"
-
-build: off
-
-cache:
- - '%LOCALAPPDATA%\pip\Cache'
-
-test_script:
- - ps: |
- $ErrorActionPreference = "Stop"
-
- function should_run_tests {
- if ("$env:APPVEYOR_PULL_REQUEST_NUMBER" -eq "") {
- Write-Host "Not a pull request - running tests"
- return $true
- }
- Write-Host "Pull request $env:APPVEYOR_PULL_REQUEST_NUMBER based on branch $env:APPVEYOR_REPO_BRANCH"
- git fetch -q origin +refs/heads/$env:APPVEYOR_REPO_BRANCH
- $changes = (git diff --name-only HEAD (git merge-base HEAD FETCH_HEAD))
- Write-Host "Files changed:"
- Write-Host $changes
- $important = $changes | Where-Object { $_ -NotLike "*.rst" } |
- Where-Object { $_ -NotLike "docs*" } |
- Where-Object { $_ -NotLike "news*" } |
- Where-Object { $_ -NotLike "*travis*" } |
- Where-Object { $_ -NotLike ".github*" }
- if (!$important) {
- Write-Host "Only documentation changes - skipping tests"
- return $false
- }
-
- Write-Host "Pull request $env:APPVEYOR_PULL_REQUEST_NUMBER alters code - running tests"
- return $true
- }
-
- if (should_run_tests) {
- # Shorten paths, workaround https://bugs.python.org/issue18199
- subst T: $env:TEMP
- $env:TEMP = "T:\"
- $env:TMP = "T:\"
- 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 -n auto --durations=20
- }
- }
diff --git a/.azure-pipelines/jobs/test-windows.yml b/.azure-pipelines/jobs/test-windows.yml
index 3d25587de..f0ab8f812 100644
--- a/.azure-pipelines/jobs/test-windows.yml
+++ b/.azure-pipelines/jobs/test-windows.yml
@@ -12,18 +12,27 @@ jobs:
Python27-x86:
python.version: '2.7'
python.architecture: x86
+ Python27-x64:
+ python.version: '2.7'
+ python.architecture: x64
+ useVenv: true
Python35-x64:
python.version: '3.5'
python.architecture: x64
+ Python36-x64:
+ python.version: '3.6'
+ python.architecture: x64
+ useVenv: true
Python37-x64:
python.version: '3.7'
python.architecture: x64
- maxParallel: 3
+ maxParallel: 5
steps:
- template: ../steps/run-tests-windows.yml
parameters:
runIntegrationTests: true
+ useVenv: '$(useVenv)'
- job: Test_Secondary
displayName: Test Secondary
diff --git a/.azure-pipelines/steps/run-tests-windows.yml b/.azure-pipelines/steps/run-tests-windows.yml
index 9926754b0..30b0021cb 100644
--- a/.azure-pipelines/steps/run-tests-windows.yml
+++ b/.azure-pipelines/steps/run-tests-windows.yml
@@ -1,5 +1,6 @@
parameters:
runIntegrationTests:
+ useVenv: false
steps:
- task: UsePythonVersion@0
@@ -43,8 +44,11 @@ steps:
# https://bugs.python.org/issue18199
$env:TEMP = "R:\Temp"
- tox -e py -- -m integration -n auto --duration=5 --junit-xml=junit/integration-test.xml
+ tox -e py -- $env:USE_VENV_ARG -m integration -n auto --duration=5 --junit-xml=junit/integration-test.xml
displayName: Tox run integration tests
+ env:
+ ${{ if eq(parameters.useVenv, 'true') }}:
+ USE_VENV_ARG: "--use-venv"
- task: PublishTestResults@2
displayName: Publish Test Results