@@ -71,6 +71,10 @@ parameters:
7171 type : boolean
7272 default : true
7373
74+ - name : PublishCodeCoverage
75+ type : boolean
76+ default : true
77+
7478# Whether this is a special one-off build for inserting into VS for a validation insertion PR (that will never be merged).
7579- name : SkipCodesignVerify
7680 type : boolean
@@ -198,7 +202,7 @@ jobs:
198202 IsOptProf : ${{ parameters.IsOptProf }}
199203
200204 - ${{ if and(parameters.EnableDotNetFormatCheck, not(parameters.EnableLinuxBuild)) }} :
201- - script : dotnet format --verify-no-changes
205+ - script : dotnet format --verify-no-changes --no-restore
202206 displayName : 💅 Verify formatted code
203207 env :
204208 dotnetformat : true # part of a workaround for https://github.com/dotnet/sdk/issues/44951
@@ -240,7 +244,7 @@ jobs:
240244 Is1ESPT : ${{ parameters.Is1ESPT }}
241245 RunTests : ${{ parameters.RunTests }}
242246 - ${{ if parameters.EnableDotNetFormatCheck }} :
243- - script : dotnet format --verify-no-changes
247+ - script : dotnet format --verify-no-changes --no-restore
244248 displayName : 💅 Verify formatted code
245249 env :
246250 dotnetformat : true # part of a workaround for https://github.com/dotnet/sdk/issues/44951
@@ -303,7 +307,7 @@ jobs:
303307 parameters :
304308 EnableLinuxBuild : ${{ parameters.EnableLinuxBuild }}
305309 EnableMacOSBuild : ${{ parameters.EnableMacOSBuild }}
306- - ${{ if parameters.RunTests }} :
310+ - ${{ if and( parameters.RunTests, parameters.PublishCodeCoverage) }} :
307311 - template : publish-codecoverage.yml
308312 parameters :
309313 EnableLinuxBuild : ${{ parameters.EnableLinuxBuild }}
0 commit comments