5
5
- job :
6
6
strategy :
7
7
matrix :
8
- Python_27_Linux :
8
+ Python_27_Linux (Public) :
9
9
PythonVersion : ' 2.7'
10
10
InstallAsyncRequirements : false
11
11
OSVmImage : ubuntu-18.04
12
- Python_37_Linux :
12
+ CloudType : public
13
+ Python_37_Linux (Public) :
13
14
PythonVersion : ' 3.7'
14
15
OSVmImage : ubuntu-18.04
15
- Python_38_Linux :
16
+ CloudType : public
17
+ Python_38_Linux (Public) :
16
18
PythonVersion : ' 3.8'
17
19
OSVmImage : ubuntu-18.04
18
- Python_37_Windows :
20
+ CloudType : public
21
+ Python_37_Windows (Public) :
19
22
PythonVersion : ' 3.7'
20
23
OSVmImage : windows-2019
21
- Python_38_Windows :
24
+ CloudType : public
25
+ Python_38_Windows (Public) :
22
26
PythonVersion : ' 3.8'
23
27
OSVmImage : windows-2019
24
- Python_37_Mac :
28
+ CloudType : public
29
+ Python_37_Mac (Public) :
25
30
PythonVersion : ' 3.7'
26
31
OSVmImage : macOS-10.15
27
- Python_38_Mac :
32
+ CloudType : public
33
+ Python_38_Mac (Public) :
28
34
PythonVersion : ' 3.8'
29
35
OSVmImage : macOS-10.15
36
+ CloudType : public
37
+ Python_38_Linux (Gov) :
38
+ PythonVersion : ' 3.8'
39
+ OSVmImage : ubuntu-18.04
40
+ CloudType : gov
41
+ Python_37_Windows (Gov) :
42
+ PythonVersion : ' 3.7'
43
+ OSVmImage : windows-2019
44
+ CloudType : gov
30
45
31
46
pool :
32
47
vmImage : $(OSVmImage)
@@ -46,17 +61,53 @@ jobs:
46
61
- script : pip install -r ./common/smoketest/requirements.txt
47
62
displayName : " Install requirements.txt"
48
63
64
+ - script : pip install -r ./common/smoketest/requirements_async.txt
65
+ displayName : " Install requirements_async.txt"
66
+ condition : and(succeeded(), eq(variables['InstallAsyncRequirements'], 'true'))
67
+
49
68
- script : python ./eng/tox/install_dev_build_dependency.py -r ./common/smoketest/requirements.txt
50
69
displayName : " Install dev dependencies from feed"
51
70
71
+ # Set secret environment variables for different clouds
72
+ - pwsh : |
73
+ $variables = @{
74
+ AZURE_CLIENT_ID='$(aad-azure-sdk-test-client-id)'
75
+ AZURE_CLIENT_SECRET='$(aad-azure-sdk-test-client-secret)'
76
+ AZURE_TENANT_ID='$(aad-azure-sdk-test-tenant-id)'
77
+ AZURE_AUTHORITY_HOST='$(aad-azure-sdk-test-authority-host)'
78
+ AZURE_PROJECT_URL='$(smoke-tests-key-vault-project-url)'
79
+ EVENT_HUBS_CONNECTION_STRING='$(smoke-tests-event-hubs-connection-string)'
80
+ COSMOS_ENDPOINT='$(smoke-tests-cosmos-endpoint)'
81
+ COSMOS_KEY='$(smoke-tests-cosmos-key)'
82
+ STORAGE_CONNECTION_STRING='$(smoke-tests-storage-connection-string)'
83
+ };
84
+ foreach ($key in $variables.Keys) {
85
+ Write-Host "Setting variable '$key'"
86
+ Write-Host "##vso[task.setvariable variable=_$key;issecret=true;]$($variables[$key])"
87
+ Write-Host "##vso[task.setvariable variable=$key;]$($variables[$key])"
88
+ }
89
+ displayName: Set secrets for public cloud
90
+ condition: and(succeeded(), eq(variables['CloudType'], 'public'))
91
+
92
+ - pwsh : |
93
+ $variables = @{
94
+ AZURE_CLIENT_ID='$(aad-azure-sdk-test-client-id-gov)'
95
+ AZURE_CLIENT_SECRET='$(aad-azure-sdk-test-client-secret-gov)'
96
+ AZURE_TENANT_ID='$(aad-azure-sdk-test-tenant-id-gov)'
97
+ AZURE_AUTHORITY_HOST='$(aad-azure-sdk-test-authority-host-gov)'
98
+ AZURE_PROJECT_URL='$(smoke-tests-key-vault-project-url-gov)'
99
+ EVENT_HUBS_CONNECTION_STRING='$(smoke-tests-event-hubs-connection-string-gov)'
100
+ COSMOS_ENDPOINT='$(smoke-tests-cosmos-endpoint-gov)'
101
+ COSMOS_KEY='$(smoke-tests-cosmos-key-gov)'
102
+ STORAGE_CONNECTION_STRING='$(smoke-tests-storage-connection-string-gov)'
103
+ };
104
+ foreach ($key in $variables.Keys) {
105
+ Write-Host "Setting variable '$key'"
106
+ Write-Host "##vso[task.setvariable variable=_$key;issecret=true;]$($variables[$key])"
107
+ Write-Host "##vso[task.setvariable variable=$key;]$($variables[$key])"
108
+ }
109
+ displayName: Set secrets for public cloud
110
+ condition: and(succeeded(), eq(variables['CloudType'], 'gov'))
111
+
52
112
- script : python ./common/smoketest/program.py
53
113
displayName : " Run Smoke Test"
54
- env :
55
- AZURE_CLIENT_ID : $(aad-azure-sdk-test-client-id)
56
- AZURE_CLIENT_SECRET : $(aad-azure-sdk-test-client-secret)
57
- AZURE_TENANT_ID : $(aad-azure-sdk-test-tenant-id)
58
- AZURE_PROJECT_URL : $(smoke-tests-key-vault-project-url)
59
- EVENT_HUBS_CONNECTION_STRING : $(smoke-tests-event-hubs-connection-string)
60
- COSMOS_ENDPOINT : $(smoke-tests-cosmos-endpoint)
61
- COSMOS_KEY : $(smoke-tests-cosmos-key)
62
- STORAGE_CONNECTION_STRING : $(smoke-tests-storage-connection-string)
0 commit comments