File tree Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Expand file tree Collapse file tree 1 file changed +46
-0
lines changed Original file line number Diff line number Diff line change
1
+ trigger :
2
+ - main
3
+
4
+ pool :
5
+ vmImage : ubuntu-latest
6
+
7
+ strategy :
8
+ matrix :
9
+ Python310 :
10
+ python.version : ' 3.10'
11
+ Python311 :
12
+ python.version : ' 3.11'
13
+ Python312 :
14
+ python.version : ' 3.12'
15
+
16
+ steps :
17
+ - task : UsePythonVersion@0
18
+ inputs :
19
+ versionSpec : ' $(python.version)'
20
+ displayName : ' Use Python $(python.version)'
21
+
22
+ - script : |
23
+ python -m pip install --upgrade pip
24
+ pip install -r requirements.txt
25
+ displayName: 'Install dependencies'
26
+
27
+ - task : ArchiveFiles@2
28
+ displayName : ' Archive files'
29
+ inputs :
30
+ rootFolderOrFile : ' $(System.DefaultWorkingDirectory)'
31
+ includeRootFolder : false
32
+ archiveType : zip
33
+ archiveFile : ' $(Build.ArtifactStagingDirectory)/$(Build.BuildId)-$(python.version).zip'
34
+ replaceExistingArchive : true
35
+
36
+ - task : PublishBuildArtifacts@1
37
+ displayName : ' Publish artifacts'
38
+ inputs :
39
+ PathtoPublish : ' $(Build.ArtifactStagingDirectory)'
40
+ ArtifactName : ' drop'
41
+ publishLocation : ' Container'
42
+
43
+ - script : |
44
+ pip install pytest pytest-azurepipelines
45
+ pytest
46
+ displayName: 'Run pytest'
You can’t perform that action at this time.
0 commit comments