Skip to content

Commit 6544f55

Browse files
committed
[GR-14439] Add jacoco coverage.
PullRequest: graalpython/435
2 parents a901ca5 + f1beb41 commit 6544f55

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

ci.jsonnet

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,17 @@
244244
name: "deploy-binaries-"+platform,
245245
},
246246

247+
local coverageGate = commonBuilder + {
248+
targets: TARGET.weekly,
249+
run +: [
250+
// cannot run with excluded "GeneratedBy" since that would lead to "command line too long"
251+
// ['mx', '--jacoco-whitelist-package', 'com.oracle.graal.python', '--jacoco-exclude-annotation', '@GeneratedBy', '--strict-compliance', "--dynamicimports", super.dynamicImports, "--primary", 'gate', '-B=--force-deprecation-as-warning-for-dependencies', '--strict-mode', '--tags', "python-junit", '--jacocout', 'html'],
252+
// ['mx', '--jacoco-whitelist-package', 'com.oracle.graal.python', '--jacoco-exclude-annotation', '@GeneratedBy', 'sonarqube-upload', "-Dsonar.host.url=$SONAR_HOST_URL", "-Dsonar.projectKey=com.oracle.graalvm.python", "-Dsonar.projectName=GraalVM - Python", '--exclude-generated'],
253+
['mx', '--jacoco-whitelist-package', 'com.oracle.graal.python', '--strict-compliance', "--dynamicimports", super.dynamicImports, "--primary", 'gate', '-B=--force-deprecation-as-warning-for-dependencies', '--strict-mode', '--tags', "python-junit", '--jacocout', 'html'],
254+
['mx', '--jacoco-whitelist-package', 'com.oracle.graal.python', 'sonarqube-upload', "-Dsonar.host.url=$SONAR_HOST_URL", "-Dsonar.projectKey=com.oracle.graalvm.python", "-Dsonar.projectName=GraalVM - Python", '--exclude-generated'],
255+
],
256+
name: "python-coverage"
257+
} + getPlatform(platform="linux"),
247258
// ------------------------------------------------------------------------------------------------------
248259
//
249260
// the gates
@@ -263,6 +274,9 @@
263274
// style
264275
styleGate,
265276

277+
// coverage
278+
coverageGate,
279+
266280
// graalvm gates
267281
graalVmGate,
268282

mx.graalpython/suite.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@
165165
"dependencies": [
166166
"truffle:ANTLR4_COMPLETE",
167167
],
168+
"jacoco": "include",
168169
"native": True,
169170
"vpath": True,
170171
},
@@ -176,6 +177,7 @@
176177
"sdk:GRAAL_SDK",
177178
"sdk:LAUNCHER_COMMON",
178179
],
180+
"jacoco": "include",
179181
"javaCompliance": "8+",
180182
"checkstyle": "com.oracle.graal.python",
181183
},
@@ -191,6 +193,7 @@
191193
"regex:TREGEX",
192194
],
193195
"buildDependencies": ["com.oracle.graal.python.parser.antlr"],
196+
"jacoco": "include",
194197
"javaCompliance" : "8+",
195198
"checkstyleVersion" : "8.8",
196199
"annotationProcessors": ["truffle:TRUFFLE_DSL_PROCESSOR"],

0 commit comments

Comments
 (0)