File tree Expand file tree Collapse file tree 1 file changed +6
-14
lines changed
Expand file tree Collapse file tree 1 file changed +6
-14
lines changed Original file line number Diff line number Diff line change @@ -27,29 +27,21 @@ The script checks for changes to:
2727
2828### Azure Pipelines
2929
30- ``` yaml
31- - powershell : |
32- .build/Test-ShouldRunDscResourceIntegrationTests.ps1
33- displayName : ' Determine if DSC resource tests should run'
34- ` ` `
35-
3630The Azure Pipelines task sets an output variable that downstream stages can
3731use to conditionally run DSC resource integration tests. The script returns
38- a boolean value that the pipeline captures using :
32+ a boolean value that the pipeline captures, e.g. :
3933
40- ` ` ` powershell
41- Write-Host "##vso[task.setvariable variable=ShouldRunDscResourceIntegrationTests;isOutput=true]$shouldRun"
34+ ``` yaml
35+ - powershell : |
36+ $shouldRun = ./.build/Test-ShouldRunDscResourceIntegrationTests.ps1 -BaseBranch $targetBranch -CurrentBranch HEAD
37+ Write-Host "##vso[task.setvariable variable=ShouldRunDscResourceIntegrationTests;isOutput=true]$shouldRun"
38+ displayName : ' Determine if DSC resource tests should run'
4239` ` `
4340
4441Downstream stages reference this output variable using the pattern:
4542` dependencies.JobName.outputs['StepName.VariableName']` to gate their
4643execution based on whether DSC resource tests should run.
4744
48- ** Note** : The step sets an output variable with ` isOutput=true ` using the
49- variable name ` ShouldRunDscResourceIntegrationTests ` . Downstream stages consume
50- this using the syntax:
51- ` dependencies.Quality_Test_and_Unit_Test.outputs['Determine_DSC_Resource_Test_Requirements.determineDscResourceTests.ShouldRunDscResourceIntegrationTests'] `
52-
5345# ## Command Line
5446
5547` ` ` powershell
You can’t perform that action at this time.
0 commit comments