Test updates

Signed-off-by: Dan Ryan <dan@danryan.co>
This commit is contained in:
Dan Ryan
2018-06-26 18:42:39 -04:00
parent bb7ea4bf41
commit 6a15ee2456
2 changed files with 54 additions and 15 deletions
+47 -15
View File
@@ -13,36 +13,66 @@ init:
git config --global core.autocrlf input
if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod `
https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | `
Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { `
Write-Host "There are newer queued builds for this pull request, skipping build."
Exit-AppveyorBuild
}
If (($env:SKIP_NOTAG -eq "true") -and ($env:APPVEYOR_REPO_TAG -ne "true")) {
Write-Host "Skipping build, not at a tag."
Exit-AppveyorBuild
}
environment:
PYPI_VENDOR_DIR: .\tests\pypi\
PYTHONIOENCODING: utf-8
GIT_ASK_YESNO: false
SHELL: windows
PYTHON_ARCH: 64
APPVEYOR_SAVE_CACHE_ON_ERROR: true
APPVEYOR_SKIP_FINALIZE_ON_EXIT: true
PYPI_VENDOR_DIR: '.\tests\pypi\'
GIT_ASK_YESNO: 'false'
SHELL: 'windows'
PYTHON_ARCH: '64'
PYTHONIOENCODING: 'utf-8'
matrix:
- PYTHON: C:\Python27-x64
PYTHON_VERSION: 2.7.x
PIPENV_PYTHON: 2.7
- PYTHON: 'C:\Python27-x64'
PYTHON_VERSION: '2.7.x'
TEST_SUITE: 'not install'
- PYTHON: 'C:\Python27-x64'
PYTHON_VERSION: '2.7.x'
TEST_SUITE: 'install'
PYTEST_ADDOPTS: '--cache-clear'
RUN_INTEGRATION_TESTS: 'True'
- PYTHON: 'C:\Python36-x64'
PYTHON_VERSION: '3.6.x'
TEST_SUITE: 'not install'
- PYTHON: 'C:\Python36-x64'
PYTHON_VERSION: '3.6.x'
TEST_SUITE: 'install'
PYTEST_ADDOPTS: '--cache-clear'
RUN_INTEGRATION_TESTS: 'True'
- PYTHON: 'C:\Python37-x64'
PYTHON_VERSION: '3.7.x'
TEST_SUITE: 'not install'
- PYTHON: 'C:\Python37-x64'
PYTHON_VERSION: '3.7.x'
TEST_SUITE: 'install'
PYTEST_ADDOPTS: '--cache-clear'
RUN_INTEGRATION_TESTS: 'True'
- PYTHON: C:\Python36-x64
PYTHON_VERSION: 3.6.x
PIPENV_PYTHON: 3.6
install:
@@ -56,7 +86,7 @@ install:
$env:PATH = "$py_path;$script_path;$env:PATH"
Invoke-Expression "$py_exe -m pip install --upgrade pip"
Invoke-Expression "$py_exe -m pip install --upgrade pip invoke"
Invoke-Expression "$py_exe -m pip install -e ."
@@ -81,4 +111,6 @@ test_script:
$env:PATH = "$py_path;$script_path;$env:PATH"
Invoke-Expression "$pipenv_exe run pytest -v -n 4 --ignore=pipenv\patched --ignore=pipenv\vendor tests"
If (($env:RUN_INTEGRATION_TESTS -eq "True") -and ($env:PYTHON_VERSION -eq "3.6.x")) { Invoke-Expression "invoke vendoring.update" }
Invoke-Expression "$pipenv_exe run pytest -v -n 4 --ignore=pipenv\patched --ignore=pipenv\vendor -m $env:TEST_SUITE tests"
+7
View File
@@ -41,8 +41,10 @@ fi
echo "Installing dependencies…"
PIPENV_PYTHON=2.7 pipenv run pip install -e . --upgrade
PIPENV_PYTHON=3.6 pipenv run pip install -e . --upgrade
PIPENV_PYTHON=3.7 pipenv run pip install -e . --upgrade
PIPENV_PYTHON=2.7 pipenv install --dev
PIPENV_PYTHON=3.6 pipenv install --dev
PIPENV_PYTHON=3.7 pipenv install --dev
echo "$ pipenv run time pytest -v -n auto tests -m \"$TEST_SUITE\""
# PIPENV_PYTHON=2.7 pipenv run time pytest -v -n auto tests -m "$TEST_SUITE" | prefix 2.7 &
@@ -50,5 +52,10 @@ echo "$ pipenv run time pytest -v -n auto tests -m \"$TEST_SUITE\""
# Better to run them sequentially.
PIPENV_PYTHON=2.7 pipenv run time pytest -v -n auto tests -m "$TEST_SUITE"
PIPENV_PYTHON=3.6 pipenv run time pytest -v -n auto tests -m "$TEST_SUITE"
PIPENV_PYTHON=3.7 pipenv run time pytest -v -n auto tests -m "$TEST_SUITE"
# test revendoring
pip install --upgrade invoke
inv vendoring.update
# Cleanup junk.
rm -fr .venv