Skip to content

Commit 8dd545a

Browse files
committed
combining all tests into one pipeline?
1 parent 8a69332 commit 8dd545a

File tree

1 file changed

+42
-18
lines changed

1 file changed

+42
-18
lines changed
Lines changed: 42 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,21 @@
1-
jobs:
2-
- job: "TestPython"
3-
displayName: "Run Base Tests"
1+
parameters:
2+
- name: python_versions
3+
type: object
4+
default:
5+
# 3.8 is EOL, don't run tests for it
6+
- python39: '3.9'
7+
- python310: '3.10'
8+
- python311: '3.11'
9+
- python312: '3.12'
10+
- python313: '3.13'
411

12+
jobs:
13+
- job: "BaseTests"
14+
displayName: "Base Extension Tests"
15+
dependsOn: []
516
strategy:
6-
matrix:
7-
python38:
8-
PYTHON_VERSION: '3.8'
9-
python39:
10-
PYTHON_VERSION: '3.9'
11-
python310:
12-
PYTHON_VERSION: '3.10'
13-
python311:
14-
PYTHON_VERSION: '3.11'
15-
python312:
16-
PYTHON_VERSION: '3.12'
17-
17+
matrix: ${{ parameters.python_versions }}
18+
condition: always()
1819
steps:
1920
- task: UsePythonVersion@0
2021
inputs:
@@ -23,7 +24,30 @@ jobs:
2324
python -m pip install --upgrade pip
2425
cd azurefunctions-extensions-base
2526
python -m pip install -U -e .[dev]
26-
displayName: 'Install dependencies'
27+
displayName: 'Install Base Dependencies'
28+
- bash: |
29+
python -m pytest -q --instafail azurefunctions-extensions-base/tests/
30+
displayName: "Run Base Extension Tests for Python $(PYTHON_VERSION)"
31+
32+
- job: "BlobTests"
33+
displayName: "Blob Extension Tests"
34+
dependsOn: []
35+
strategy:
36+
matrix: ${{ parameters.python_versions }}
37+
condition: always()
38+
steps:
39+
- task: UsePythonVersion@0
40+
inputs:
41+
versionSpec: $(PYTHON_VERSION)
42+
- bash: |
43+
python -m pip install --upgrade pip
44+
cd azurefunctions-extensions-bindings-blob
45+
python -m pip install -U -e .[dev]
46+
displayName: 'Install Blob Dependencies'
2747
- bash: |
28-
python -m pytest -q --instafail azurefunctions-extensions-base/tests/ --ignore='azurefunctions-extensions-bindings-blob', --ignore='azurefunctions-extensions-http-fastapi', --ignore='azurefunctions-extensions-bindings-eventhub'
29-
displayName: "Running Base $(PYTHON_VERSION) Python Extension Tests"
48+
python -m pytest -q --instafail azurefunctions-extensions-bindings-blob/tests/
49+
env:
50+
AzureWebJobsStorage: $(AzureWebJobsStorage)
51+
input: $(input__serviceUri)
52+
trigger: $(trigger__blobServiceUri)
53+
displayName: "Run Blob Extension Tests for Python $(PYTHON_VERSION)"

0 commit comments

Comments
 (0)