Skip to content

Commit 9c695c5

Browse files
committed
Skip jacoco instrumentation/coverage in jenkins build
1 parent c2be33d commit 9c695c5

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

Jenkinsfile

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,13 @@ stage('Configure') {
4545
// We want to enable preview features when testing newer builds of OpenJDK:
4646
// even if we don't use these features, just enabling them can cause side effects
4747
// and it's useful to test that.
48-
new BuildEnvironment( testJdkVersion: '23', testJdkLauncherArgs: '--enable-preview' ),
49-
new BuildEnvironment( testJdkVersion: '24', testJdkLauncherArgs: '--enable-preview' ),
48+
new BuildEnvironment( testJdkVersion: '23', testJdkLauncherArgs: '--enable-preview', skipJacoco: true ),
49+
new BuildEnvironment( testJdkVersion: '24', testJdkLauncherArgs: '--enable-preview', skipJacoco: true ),
5050
// The following JDKs aren't supported by Hibernate ORM out-of-the box yet:
5151
// they require the use of -Dnet.bytebuddy.experimental=true.
5252
// Make sure to remove that argument as soon as possible
5353
// -- generally that requires upgrading bytebuddy after the JDK goes GA.
54-
new BuildEnvironment( testJdkVersion: '25', testJdkLauncherArgs: '--enable-preview -Dnet.bytebuddy.experimental=true' )
54+
new BuildEnvironment( testJdkVersion: '25', testJdkLauncherArgs: '--enable-preview -Dnet.bytebuddy.experimental=true', skipJacoco: true ),
5555
];
5656

5757
if ( env.CHANGE_ID ) {
@@ -130,6 +130,10 @@ stage('Build') {
130130
state[buildEnv.tag]['additionalOptions'] = state[buildEnv.tag]['additionalOptions'] +
131131
" -Pci.node=${buildEnv.node}"
132132
}
133+
if ( buildEnv.skipJacoco ) {
134+
state[buildEnv.tag]['additionalOptions'] = state[buildEnv.tag]['additionalOptions'] +
135+
" -Pjacoco.skip=true"
136+
}
133137
state[buildEnv.tag]['containerName'] = null;
134138
stage('Checkout') {
135139
checkout scm
@@ -215,6 +219,7 @@ class BuildEnvironment {
215219
String additionalOptions
216220
String notificationRecipients
217221
boolean longRunning
222+
boolean skipJacoco
218223

219224
String toString() { getTag() }
220225
String getTag() { "${node ? node + "_" : ''}${testJdkVersion ? 'jdk_' + testJdkVersion + '_' : '' }${dbName}" }

0 commit comments

Comments
 (0)