-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
- Loading branch information
1 parent
ffb78f5
commit 32cb35b
Showing
2 changed files
with
98 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,34 @@ | ||
parameters: | ||
pythonVersions: [] | ||
vmImage: '' | ||
jobName: '' | ||
pythonArchitecture: '' | ||
|
||
jobs: | ||
- job: ${{ parameters.jobName }} | ||
pool: | ||
vmImage: ${{ parameters.vmImage }} | ||
strategy: | ||
matrix: | ||
${{ each py in parameters.pythonVersions }}: | ||
python.version: ${{ py }} | ||
python.architecture: ${{ parameters.pythonArchitecture }} | ||
maxParallel: 8 | ||
|
||
variables: | ||
- group: CI | ||
|
||
steps: | ||
- task: UsePythonVersion@0 | ||
inputs: | ||
versionSpec: $(python.version) | ||
architecture: '$(python.architecture)' | ||
addToPath: true | ||
displayName: Use Python $(python.version) | ||
|
||
- template: install-dependencies.yml | ||
|
||
- script: | | ||
echo '##vso[task.setvariable variable=PIPENV_DEFAULT_PYTHON_VERSION]'$(python.version) | ||
env: | ||
PYTHON_VERSION: $(python.version) | ||
- template: create-virtualenv.yml | ||
steps: | ||
- task: UsePythonVersion@0 | ||
inputs: | ||
versionSpec: $(python.version) | ||
architecture: '$(python.architecture)' | ||
addToPath: true | ||
displayName: Use Python $(python.version) | ||
|
||
- template: install-dependencies.yml | ||
|
||
- script: | | ||
echo '##vso[task.setvariable variable=PIPENV_DEFAULT_PYTHON_VERSION]'$(python.version) | ||
env: | ||
PYTHON_VERSION: $(python.version) | ||
|
||
- template: create-virtualenv.yml | ||
parameters: | ||
python_version: $(python.version) | ||
|
||
- ${{ if eq(parameters.vmImage, 'windows-latest') }}: | ||
- template: run-tests-windows.yml | ||
parameters: | ||
python_version: $(python.version) | ||
- ${{ if ne(parameters.vmImage, 'windows-latest') }}: | ||
- template: run-tests-linux.yml | ||
parameters: | ||
python_version: $(python.version) | ||
|
||
- ${{ if eq(parameters.vmImage, 'windows-latest') }}: | ||
- template: run-tests-windows.yml | ||
parameters: | ||
python_version: $(python.version) | ||
- ${{ if ne(parameters.vmImage, 'windows-latest') }}: | ||
- template: run-tests-linux.yml | ||
parameters: | ||
python_version: $(python.version) | ||
|
||
- task: PublishTestResults@2 | ||
displayName: Publish Test Results | ||
inputs: | ||
testResultsFiles: '**/test-results.xml' | ||
testRunTitle: 'Python $(python.version)' | ||
condition: succeededOrFailed() | ||
- task: PublishTestResults@2 | ||
displayName: Publish Test Results | ||
inputs: | ||
testResultsFiles: '**/test-results.xml' | ||
testRunTitle: 'Python $(python.version)' | ||
condition: succeededOrFailed() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters