Merge remote-tracking branch 'origin/dev' into feature/1602-update-docs

This commit is contained in:
Marek Wolan
2023-07-11 13:13:02 +01:00

View File

@@ -6,35 +6,51 @@ trigger:
- bugfix/* - bugfix/*
- release/* - release/*
strategy: parameters:
matrix: # https://stackoverflow.com/a/70046417
UbuntuPython38: - name: matrix
python.version: '3.8' type: object
imageName: 'ubuntu-latest' default:
UbuntuPython310: - job_name: 'UbuntuPython38'
python.version: '3.10' py: '3.8'
imageName: 'ubuntu-latest' img: 'ubuntu-latest'
WindowsPython38: every_time: false
python.version: '3.8' - job_name: 'UbuntuPython310'
imageName: 'windows-latest' py: '3.10'
WindowsPython310: img: 'ubuntu-latest'
python.version: '3.10' every_time: true
imageName: 'windows-latest' - job_name: 'WindowsPython38'
MacOSPython38: py: '3.8'
python.version: '3.8' img: 'windows-latest'
imageName: 'macOS-latest' every_time: false
MacOSPython310: - job_name: 'WindowsPython310'
python.version: '3.10' py: '3.10'
imageName: 'macOS-latest' img: 'windows-latest'
every_time: false
- job_name: 'MacOSPython38'
py: '3.8'
img: 'macOS-latest'
every_time: false
- job_name: 'MacOSPython310'
py: '3.10'
img: 'macOS-latest'
every_time: false
stages:
- stage: Test
jobs:
- ${{ each item in parameters.matrix }}:
- job: ${{ item.job_name }}
pool: pool:
vmImage: $(imageName) vmImage: ${{ item.img }}
condition: or( eq(variables['Build.Reason'], 'PullRequest'), ${{ item.every_time }} )
steps: steps:
- task: UsePythonVersion@0 - task: UsePythonVersion@0
inputs: inputs:
versionSpec: '$(python.version)' versionSpec: ${{ item.py }}
displayName: 'Use Python $(python.version)' displayName: 'Use Python ${{ item.py }}'
- script: | - script: |
python -m pip install pre-commit python -m pip install pre-commit