-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstep.yml
151 lines (131 loc) · 6.36 KB
/
step.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
#
# A couple of useful guides & docs:
#
# - Main Bitrise CLI docs: https://github.com/bitrise-io/bitrise/tree/master/_docs
# - Step Development Guideline: https://github.com/bitrise-io/bitrise/blob/master/_docs/step-development-guideline.md
# - Bitrise.yml format spec: https://github.com/bitrise-io/bitrise/blob/master/_docs/bitrise-yml-format-spec.md
# - Bitrise docs: http://devcenter.bitrise.io/
# - Bitrise CLI guides: http://devcenter.bitrise.io/bitrise-cli/
title: |-
JaCoCo Report Parser
summary: |
Parse a JaCoCo generated report and output the code coverage percentages to be used by other steps.
description: |
This step parses a JaCoCo generated XML report in the `jacoco_report_path` and outputs the coverage
percentages in a String format to environment / output variables to be used in other steps.
It basically gets the top-level counter information for each coverage type and calculates de percentage
by doing `covered` / `covered` + `missed`.
Input:
`jacoco_report_path` receives the reported file path (it must be an xml)
Outputs:
`JACOCO_INSTRUCTION_COVERAGE` contains the instruction coverage percentage calculated from the report
`JACOCO_BRANCH_COVERAGE` contains the branch coverage percentage calculated from the report
`JACOCO_LINE_COVERAGE` contains the line coverage percentage calculated from the report
`JACOCO_COMPLEXITY_COVERAGE` contains the complexity coverage percentage calculated from the report
`JACOCO_METHOD_COVERAGE` contains the method coverage percentage calculated from the report
`JACOCO_CLASS_COVERAGE` contains the class coverage percentage calculated from the report
website: https://github.com/thomashorta/bitrise-step-jacoco-parser
source_code_url: https://github.com/thomashorta/bitrise-step-jacoco-parser
support_url: https://github.com/thomashorta/bitrise-step-jacoco-parser/issues
host_os_tags:
- osx-10.10
- ubuntu-16.04
# If this step should be available only for certain project types
# just uncomment this `project_type_tags` section and include all the
# project types supported by the step. If the step can be used for all
# project types then you can just remove this section.
# If no `project_type_tags` specified (or specified as an empty array)
# that means the step can be used for any project type.
# You can find more information about project type tags in the Step Development Guideline:
# https://github.com/bitrise-io/bitrise/blob/master/_docs/step-development-guideline.md
#
project_type_tags:
- android
- xamarin
- react-native
- cordova
- ionic
- flutter
# Type tags are used for categorizing steps, for easier step discovery in Step Libraries.
# You can find more information about type tags in the Step Development Guideline:
# https://github.com/bitrise-io/bitrise/blob/master/_docs/step-development-guideline.md
type_tags:
- test
- utility
is_requires_admin_user: false
is_always_run: false
is_skippable: false
deps:
brew:
- name: git
- name: wget
apt_get:
- name: git
- name: wget
toolkit:
go:
package_name: github.com/thomashorta/bitrise-step-jacoco-parser
inputs:
- jacoco_report_path: $BITRISE_SOURCE_DIR/build/reports/jacoco.xml
opts:
is_required: true
title: "The JaCoCo report file path"
summary: Exact path location to the JaCoCo report file (usually points to a jacoco.xml file).
description: |
The report will be parsed from this input to run this step.
Default value: `$BITRISE_SOURCE_DIR/build/reports/jacoco.xml`
outputs:
- JACOCO_INSTRUCTION_COVERAGE:
opts:
title: "Instruction coverage percentage"
summary: Total instruction coverage percentage parsed from the report.
description: |
This is the total instruciton coverage percentage parsed from the report
taking into consideration the report summary for the whole run.
This is calculated by taking the `covered` amount divided by the `covered` + `missed` amount.
It returns "N/A" if the coverage information was not found.
- JACOCO_BRANCH_COVERAGE:
opts:
title: "Branch coverage percentage"
summary: Total branch coverage percentage parsed from the report.
description: |
This is the total branch coverage percentage parsed from the report
taking into consideration the report summary for the whole run.
This is calculated by taking the `covered` amount divided by the `covered` + `missed` amount.
It returns "N/A" if the coverage information was not found.
- JACOCO_LINE_COVERAGE:
opts:
title: "Line coverage percentage"
summary: Total line coverage percentage parsed from the report.
description: |
This is the total line coverage percentage parsed from the report
taking into consideration the report summary for the whole run.
This is calculated by taking the `covered` amount divided by the `covered` + `missed` amount.
It returns "N/A" if the coverage information was not found.
- JACOCO_COMPLEXITY_COVERAGE:
opts:
title: "Complexity coverage percentage"
summary: Total complexity coverage percentage parsed from the report.
description: |
This is the total complexity coverage percentage parsed from the report
taking into consideration the report summary for the whole run.
This is calculated by taking the `covered` amount divided by the `covered` + `missed` amount.
It returns "N/A" if the coverage information was not found.
- JACOCO_METHOD_COVERAGE:
opts:
title: "Method coverage percentage"
summary: Total method coverage percentage parsed from the report.
description: |
This is the total method coverage percentage parsed from the report
taking into consideration the report summary for the whole run.
This is calculated by taking the `covered` amount divided by the `covered` + `missed` amount.
It returns "N/A" if the coverage information was not found.
- JACOCO_CLASS_COVERAGE:
opts:
title: "Class coverage percentage"
summary: Total class coverage percentage parsed from the report.
description: |
This is the total class coverage percentage parsed from the report
taking into consideration the report summary for the whole run.
This is calculated by taking the `covered` amount divided by the `covered` + `missed` amount.
It returns "N/A" if the coverage information was not found.