Debian Codegraph @

ansible_collections/community/docker/.azure-pipelines/templates/test.yml

raw symbols SCIP
1 ---
2 # Copyright (c) Ansible Project
3 # GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)
4 # SPDX-License-Identifier: GPL-3.0-or-later
5
6 # This template uses the provided list of jobs to create test one or more test jobs.
7 # It can be used directly if needed, or through the matrix template.
8
9 parameters:
10 # A required list of dictionaries, one per test job.
11 # Each item in the list must contain a "job" and "name" key.
12 - name: jobs
13 type: object
14
15 jobs:
16 - ${{ each job in parameters.jobs }}:
17 - job: test_${{ replace(replace(replace(job.test, '/', '_'), '.', '_'), '-', '_') }}
18 displayName: ${{ job.name }}
19 container: default
20 workspace:
21 clean: all
22 steps:
23 - checkout: self
24 fetchDepth: $(fetchDepth)
25 path: $(checkoutPath)
26 - bash: .azure-pipelines/scripts/run-tests.sh "$(entryPoint)" "${{ job.test }}" "$(coverageBranches)"
27 displayName: Run Tests
28 - bash: .azure-pipelines/scripts/process-results.sh
29 condition: succeededOrFailed()
30 displayName: Process Results
31 - bash: .azure-pipelines/scripts/aggregate-coverage.sh "$(Agent.TempDirectory)"
32 condition: eq(variables.haveCoverageData, 'true')
33 displayName: Aggregate Coverage Data
34 - task: PublishTestResults@2
35 condition: eq(variables.haveTestResults, 'true')
36 inputs:
37 testResultsFiles: "$(outputPath)/junit/*.xml"
38 displayName: Publish Test Results
39 - task: PublishPipelineArtifact@1
40 condition: eq(variables.haveBotResults, 'true')
41 displayName: Publish Bot Results
42 inputs:
43 targetPath: "$(outputPath)/bot/"
44 artifactName: "Bot $(System.JobAttempt) $(System.StageDisplayName) $(System.JobDisplayName)"
45 - task: PublishPipelineArtifact@1
46 condition: eq(variables.haveCoverageData, 'true')
47 displayName: Publish Coverage Data
48 inputs:
49 targetPath: "$(Agent.TempDirectory)/coverage/"
50 artifactName: "Coverage $(System.JobAttempt) $(System.StageDisplayName) $(System.JobDisplayName)"