diff --git a/Jenkinsfile.internal b/Jenkinsfile.internal
index de0bdeea..6589c1b0 100644
--- a/Jenkinsfile.internal
+++ b/Jenkinsfile.internal
@@ -34,6 +34,8 @@ pipeline {
failFast false
parallel {
stage('System Tests') {
+ // The needed artifact is only built for main and pull requests -> skip this job otherwise
+ when { branch pattern: "PR-\\d+|main", comparator: "REGEXP"}
steps {
build job: '../systemTests', parameters: [string(name: 'artifactName', value: "${JOB_BASE_NAME}"), string(name: 'commitHash', value: "${GIT_COMMIT}")]
}
diff --git a/config/spotbugs/spotbugs-exclude.xml b/config/spotbugs/spotbugs-exclude.xml
index 418d779d..fee606c4 100644
--- a/config/spotbugs/spotbugs-exclude.xml
+++ b/config/spotbugs/spotbugs-exclude.xml
@@ -6,4 +6,21 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/gradle.properties b/gradle.properties
index 4a336729..e17d25b4 100644
--- a/gradle.properties
+++ b/gradle.properties
@@ -4,7 +4,7 @@ jpiVersion=0.43.0
jenkinsVersion=2.332.3
gradleVersion=7.3
openapiVersion=6.1.0
-spotBugsPlugin=5.0.13
+spotBugsPlugin=5.1.3
spotBugsVersion=4.7.3
cyclonedxVersion=1.7.2
depCheckVersion=7.4.1
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/ETInstallation.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/ETInstallation.groovy
index 383a6142..63ff27b9 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/ETInstallation.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/ETInstallation.groovy
@@ -47,7 +47,7 @@ class ETInstallation extends ToolInstallation implements
* @param home path to the tool executable
* @param properties properties of the tool installation
*/
- ETInstallation(String name, String home, List extends ToolProperty>> properties) {
+ ETInstallation(String name, String home, List extends ToolProperty extends ToolInstallation>> properties) {
super(Util.fixEmptyAndTrim(name), Util.fixEmptyAndTrim(home), properties)
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunPackageAction.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunPackageAction.groovy
index bc777315..3a0031ae 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunPackageAction.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunPackageAction.groovy
@@ -23,10 +23,10 @@ class RunPackageAction extends RunTestAction {
}
PackageConfig getPackageConfig() {
- return packageConfig
+ return new PackageConfig(packageConfig)
}
AnalysisConfig getAnalysisConfig() {
- return analysisConfig
+ return new AnalysisConfig(analysisConfig)
}
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunTestAction.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunTestAction.groovy
index d59703fe..e32805c5 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunTestAction.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/actions/RunTestAction.groovy
@@ -26,10 +26,10 @@ abstract class RunTestAction extends InvisibleAction {
}
TestConfig getTestConfig() {
- return testConfig
+ return new TestConfig(testConfig)
}
TestResult getTestResult() {
- return testResult
+ return new TestResult(testResult)
}
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/AbstractTestBuilder.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/AbstractTestBuilder.groovy
index 165b2d6b..463eb266 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/AbstractTestBuilder.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/AbstractTestBuilder.groovy
@@ -25,10 +25,10 @@ import java.util.concurrent.TimeoutException
* Common base class for all test related steps implemented in this plugin.
*/
abstract class AbstractTestBuilder implements Serializable {
- static String testCasePath
- static TestConfig testConfig
- static ExecutionConfig executionConfig
- static StepContext context
+ final String testCasePath
+ final TestConfig testConfig
+ final ExecutionConfig executionConfig
+ final StepContext context
protected abstract String getTestArtifactName()
protected abstract LogConfigUtil getLogConfig()
@@ -43,6 +43,14 @@ abstract class AbstractTestBuilder implements Serializable {
this.context = context
}
+ ExecutionConfig getExecutionConfig() {
+ return executionConfig ? new ExecutionConfig(executionConfig) : null
+ }
+
+ TestConfig getTestConfig() {
+ return testConfig ? new TestConfig(testConfig) : null
+ }
+
TestResult runTest() {
def toolInstallations = getToolInstallationsOnNode()
@@ -52,7 +60,7 @@ abstract class AbstractTestBuilder implements Serializable {
getTestArtifactName(), getLogConfig(), getExecutionOrderBuilder(), toolInstallations))
}
- private static ArrayList getToolInstallationsOnNode() {
+ private ArrayList getToolInstallationsOnNode() {
/**
* This method gets the executable names of the tool installations on the node given by the context. Context is
* not reasonably available in the MasterToSlaveCallable, so all info which needs a context must be fetched
@@ -73,6 +81,9 @@ abstract class AbstractTestBuilder implements Serializable {
}
private static final class RunTestCallable extends MasterToSlaveCallable {
+
+ private static final long serialVersionUID = 1L
+
private final String testCasePath
private final EnvVars envVars
private final TaskListener listener
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/ExecutionOrderBuilder.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/ExecutionOrderBuilder.groovy
index b1e4b05d..911449eb 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/ExecutionOrderBuilder.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/ExecutionOrderBuilder.groovy
@@ -14,6 +14,8 @@ import de.tracetronic.jenkins.plugins.ecutestexecution.util.ConverterUtil
* thus avoid serialization errors.
*/
class ExecutionOrderBuilder implements Serializable {
+
+ private static final long serialVersionUID = 1L
private final String testCasePath
private final TestConfig testConfig
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilder.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilder.groovy
index 13642aaf..5419f3d1 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilder.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilder.groovy
@@ -12,12 +12,14 @@ import org.jenkinsci.plugins.workflow.steps.StepContext
* builder providing test package configuration.
*/
class TestPackageBuilder extends AbstractTestBuilder {
+ private static final long serialVersionUID = 1L
+
/**
* Defines the test artifact name.
*/
private final static String TEST_ARTIFACT_NAME = 'package'
- private static PackageConfig packageConfig
- private static AnalysisConfig analysisConfig
+ private final PackageConfig packageConfig
+ private final AnalysisConfig analysisConfig
TestPackageBuilder(String testCasePath, TestConfig testConfig, ExecutionConfig executionConfig,
StepContext context, PackageConfig packageConfig, AnalysisConfig analysisConfig){
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilder.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilder.groovy
index d701ee6d..2e985ffc 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilder.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilder.groovy
@@ -10,6 +10,9 @@ import org.jenkinsci.plugins.workflow.steps.StepContext
* builder providing test project configuration.
*/
class TestProjectBuilder extends AbstractTestBuilder {
+
+ private static final long serialVersionUID = 1L
+
/**
* Defines the test artifact name.
*/
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/AnalysisConfig.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/AnalysisConfig.groovy
index 40ce0f64..82b5869a 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/AnalysisConfig.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/AnalysisConfig.groovy
@@ -33,6 +33,12 @@ class AnalysisConfig extends AbstractDescribableImpl implements
this.recordings = []
}
+ AnalysisConfig(AnalysisConfig config) {
+ this.analysisName = config.getAnalysisName()
+ this.mapping = config.getMapping()
+ this.recordings = config.getRecordings()
+ }
+
String getAnalysisName() {
return analysisName
}
@@ -52,7 +58,7 @@ class AnalysisConfig extends AbstractDescribableImpl implements
}
List getRecordings() {
- return recordings
+ return recordings.collect({new RecordingAsSetting(it)})
}
@DataBoundSetter
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/ExecutionConfig.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/ExecutionConfig.groovy
index 310b1db7..82ae063a 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/ExecutionConfig.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/ExecutionConfig.groovy
@@ -32,6 +32,12 @@ class ExecutionConfig extends AbstractDescribableImpl implement
this.stopUndefinedTools = true
}
+ ExecutionConfig(ExecutionConfig config) {
+ this.timeout = config.getTimeout()
+ this.stopOnError = config.isStopOnError()
+ this.stopUndefinedTools = config.getStopUndefinedTools()
+ }
+
int getTimeout() {
return timeout
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/PackageConfig.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/PackageConfig.groovy
index b85d36ce..9231767c 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/PackageConfig.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/PackageConfig.groovy
@@ -13,7 +13,7 @@ import hudson.model.Descriptor
import org.apache.commons.lang.StringUtils
import org.kohsuke.stapler.DataBoundConstructor
-class PackageConfig extends AbstractDescribableImpl implements ExpandableConfig, Serializable {
+class PackageConfig extends AbstractDescribableImpl implements ExpandableConfig, Serializable{
private static final long serialVersionUID = 1L
@@ -24,8 +24,12 @@ class PackageConfig extends AbstractDescribableImpl implements Ex
this.packageParameters = packageParameters ? removeEmptyParameters(packageParameters) : []
}
+ PackageConfig(PackageConfig config) {
+ this.packageParameters = config.getPackageParameters()
+ }
+
List getPackageParameters() {
- return packageParameters
+ return packageParameters.collect({new PackageParameter(it)})
}
@Override
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/TestConfig.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/TestConfig.groovy
index 5b2e508e..f0155ce7 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/TestConfig.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/configs/TestConfig.groovy
@@ -34,6 +34,13 @@ class TestConfig extends AbstractDescribableImpl implements Expandab
this.constants = []
}
+ TestConfig(TestConfig config) {
+ this.tbcPath = config.getTbcPath()
+ this.tcfPath = config.getTcfPath()
+ this.constants = config.getConstants()
+ this.forceConfigurationReload = config.forceConfigurationReload
+ }
+
String getTbcPath() {
return tbcPath
}
@@ -62,7 +69,7 @@ class TestConfig extends AbstractDescribableImpl implements Expandab
}
List getConstants() {
- return constants
+ return constants.collect({new Constant(it)})
}
@DataBoundSetter
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/AdditionalSetting.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/AdditionalSetting.groovy
index 8491f5e1..071eb011 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/AdditionalSetting.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/AdditionalSetting.groovy
@@ -29,6 +29,11 @@ class AdditionalSetting extends AbstractDescribableImpl imple
this.value = StringUtils.trimToEmpty(value)
}
+ AdditionalSetting(AdditionalSetting setting) {
+ this.name = setting.getName()
+ this.value = setting.getValue()
+ }
+
String getName() {
return name
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/Constant.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/Constant.groovy
index 7361c32e..df015046 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/Constant.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/Constant.groovy
@@ -29,6 +29,11 @@ class Constant extends AbstractDescribableImpl implements ExpandableCo
this.value = StringUtils.trimToEmpty(value)
}
+ Constant(Constant constant) {
+ this.label = constant.getLabel()
+ this.value = constant.getValue()
+ }
+
String getLabel() {
return label
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/PackageParameter.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/PackageParameter.groovy
index 5f3ef53e..dd5b1c04 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/PackageParameter.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/PackageParameter.groovy
@@ -29,6 +29,11 @@ class PackageParameter extends AbstractDescribableImpl impleme
this.value = StringUtils.trimToEmpty(value)
}
+ PackageParameter(PackageParameter param) {
+ this.label = param.getLabel()
+ this.value = param.getValue()
+ }
+
String getLabel() {
return label
}
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/RecordingAsSetting.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/RecordingAsSetting.groovy
index dc0669d5..d0387fa6 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/RecordingAsSetting.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/RecordingAsSetting.groovy
@@ -37,6 +37,14 @@ class RecordingAsSetting extends AbstractDescribableImpl imp
this.formatDetails = ''
}
+ RecordingAsSetting(RecordingAsSetting setting) {
+ this.path = setting.getPath()
+ this.recordingGroup = setting.getRecordingGroup()
+ this.mappingNames = setting.getMappingNames()
+ this.deviceName = setting.getDeviceName()
+ this.formatDetails = setting.getFormatDetails()
+ }
+
String getPath() {
return path
}
@@ -51,7 +59,7 @@ class RecordingAsSetting extends AbstractDescribableImpl imp
}
List getMappingNames() {
- return mappingNames
+ return mappingNames.collect()
}
@DataBoundSetter
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/TestResult.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/TestResult.groovy
index 63a2119b..2129de9f 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/TestResult.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/model/TestResult.groovy
@@ -21,6 +21,12 @@ class TestResult implements Serializable {
this.reportDir = reportDir
}
+ TestResult(TestResult result) {
+ this.reportId = result.getReportId()
+ this.reportDir = result.getReportDir()
+ this.testResult = result.getTestResult()
+ }
+
@Whitelisted
String getReportId() {
return reportId
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/scan/AbstractTestScanner.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/scan/AbstractTestScanner.groovy
index 2cc3dacb..c84627be 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/scan/AbstractTestScanner.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/scan/AbstractTestScanner.groovy
@@ -56,6 +56,9 @@ abstract class AbstractTestScanner {
* {@link hudson.remoting.Callable} providing remote access to scan a directory with a include file pattern.
*/
private static final class ScanTestCallable extends MasterToSlaveCallable, IOException> {
+
+ private static final long serialVersionUID = 1L
+
private final String inputDir
private final filePattern
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/GenerateReportsStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/GenerateReportsStep.groovy
index b5504231..0f0a09e4 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/GenerateReportsStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/GenerateReportsStep.groovy
@@ -45,7 +45,7 @@ class GenerateReportsStep extends Step {
}
List getAdditionalSettings() {
- return additionalSettings
+ return additionalSettings.collect({new AdditionalSetting(it)})
}
@DataBoundSetter
@@ -54,7 +54,7 @@ class GenerateReportsStep extends Step {
}
List getReportIds() {
- return reportIds
+ return reportIds.collect()
}
@DataBoundSetter
@@ -85,6 +85,8 @@ class GenerateReportsStep extends Step {
static class Execution extends SynchronousNonBlockingStepExecution {
+ private static final long serialVersionUID = 1L
+
private final transient GenerateReportsStep step
Execution(GenerateReportsStep step, StepContext context) {
@@ -104,6 +106,8 @@ class GenerateReportsStep extends Step {
}
private static final class ExecutionCallable extends MasterToSlaveCallable {
+
+ private static final long serialVersionUID = 1L
private final String generatorName
private final Map additionalSettings
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunPackageStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunPackageStep.groovy
index 1f27bb45..fd3e98c1 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunPackageStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunPackageStep.groovy
@@ -51,7 +51,7 @@ class RunPackageStep extends RunTestStep {
@Nonnull
PackageConfig getPackageConfig() {
- return packageConfig
+ return new PackageConfig(packageConfig)
}
@DataBoundSetter
@@ -61,7 +61,7 @@ class RunPackageStep extends RunTestStep {
@Nonnull
AnalysisConfig getAnalysisConfig() {
- return analysisConfig
+ return new AnalysisConfig(analysisConfig)
}
@DataBoundSetter
@@ -75,6 +75,8 @@ class RunPackageStep extends RunTestStep {
}
static class Execution extends SynchronousNonBlockingStepExecution {
+
+ private static final long serialVersionUID = 1L
private final transient RunPackageStep step
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunProjectStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunProjectStep.groovy
index b8516c74..b235774b 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunProjectStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunProjectStep.groovy
@@ -43,6 +43,8 @@ class RunProjectStep extends RunTestStep {
static class Execution extends SynchronousNonBlockingStepExecution {
+ private static final long serialVersionUID = 1L
+
private final transient RunProjectStep step
Execution(RunProjectStep step, StepContext context) {
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestFolderStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestFolderStep.groovy
index 4bcf1758..b589284c 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestFolderStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestFolderStep.groovy
@@ -60,7 +60,7 @@ class RunTestFolderStep extends RunTestStep {
@Nonnull
ScanMode getScanMode() {
- return scanMode;
+ return scanMode.toString() as ScanMode
}
@DataBoundSetter
@@ -88,7 +88,7 @@ class RunTestFolderStep extends RunTestStep {
@Nonnull
PackageConfig getPackageConfig() {
- return packageConfig
+ return new PackageConfig(packageConfig)
}
@DataBoundSetter
@@ -98,7 +98,7 @@ class RunTestFolderStep extends RunTestStep {
@Nonnull
AnalysisConfig getAnalysisConfig() {
- return analysisConfig
+ return new AnalysisConfig(analysisConfig)
}
@DataBoundSetter
@@ -113,6 +113,8 @@ class RunTestFolderStep extends RunTestStep {
static class Execution extends SynchronousNonBlockingStepExecution> {
+ private static final long serialVersionUID = 1L
+
private final transient RunTestFolderStep step
Execution(RunTestFolderStep step, StepContext context) {
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestStep.groovy
index 497709fb..566034e6 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/RunTestStep.groovy
@@ -36,7 +36,7 @@ abstract class RunTestStep extends Step {
@Nonnull
TestConfig getTestConfig() {
- return testConfig
+ return new TestConfig(testConfig)
}
@DataBoundSetter
@@ -46,7 +46,7 @@ abstract class RunTestStep extends Step {
@Nonnull
ExecutionConfig getExecutionConfig() {
- return executionConfig
+ return new ExecutionConfig(executionConfig)
}
@DataBoundSetter
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StartToolStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StartToolStep.groovy
index 7081ecda..4c6830b1 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StartToolStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StartToolStep.groovy
@@ -187,6 +187,8 @@ class StartToolStep extends Step {
private static final class ExecutionCallable extends MasterToSlaveCallable {
+ private static final long serialVersionUID = 1L
+
private final ETInstallation installation
private final String workspaceDir
private final String settingsDir
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StopToolStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StopToolStep.groovy
index 97519719..bf96beb4 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StopToolStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/StopToolStep.groovy
@@ -77,6 +77,8 @@ class StopToolStep extends Step {
static class Execution extends SynchronousNonBlockingStepExecution {
+ private static final long serialVersionUID = 1L
+
private final transient StopToolStep step
Execution(StopToolStep step, StepContext context) {
@@ -117,6 +119,8 @@ class StopToolStep extends Step {
private static final class ExecutionCallable extends MasterToSlaveCallable {
+ private static final long serialVersionUID = 1L
+
private final ETInstallation installation
private final int timeout
private final boolean stopUndefinedTools
diff --git a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/UploadReportsStep.groovy b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/UploadReportsStep.groovy
index b3b9e0d9..0c499d59 100644
--- a/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/UploadReportsStep.groovy
+++ b/src/main/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/steps/UploadReportsStep.groovy
@@ -94,7 +94,7 @@ class UploadReportsStep extends Step {
}
List getAdditionalSettings() {
- return additionalSettings
+ return additionalSettings.collect({new AdditionalSetting(it)})
}
@DataBoundSetter
@@ -103,7 +103,7 @@ class UploadReportsStep extends Step {
}
List getReportIds() {
- return reportIds
+ return reportIds.collect()
}
@DataBoundSetter
@@ -134,6 +134,8 @@ class UploadReportsStep extends Step {
static class Execution extends SynchronousNonBlockingStepExecution {
+ private static final long serialVersionUID = 1L
+
private final transient UploadReportsStep step
Execution(UploadReportsStep step, StepContext context) {
@@ -167,6 +169,8 @@ class UploadReportsStep extends Step {
private static final class ExecutionCallable extends MasterToSlaveCallable {
+ private static final long serialVersionUID = 1L
+
private final String testGuideUrl
private final String authKey
private final int projectId
diff --git a/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilderTest.groovy b/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilderTest.groovy
index 45cb8bc3..2214c63e 100644
--- a/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilderTest.groovy
+++ b/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestPackageBuilderTest.groovy
@@ -20,13 +20,13 @@ class TestPackageBuilderTest extends Specification {
def 'Test Null Values'() {
given:
- new TestPackageBuilder(null, null, null, null, null, null)
+ def tpb = new TestPackageBuilder(null, null, null, null, null, null)
expect:
- TestPackageBuilder.testCasePath == null
- TestPackageBuilder.testConfig == null
- TestPackageBuilder.executionConfig == null
- TestPackageBuilder.context == null
+ tpb.testCasePath == null
+ tpb.testConfig == null
+ tpb.executionConfig == null
+ tpb.context == null
}
def 'Test Default Values'() {
@@ -37,7 +37,7 @@ class TestPackageBuilderTest extends Specification {
final ExecutionConfig executionConfig = new ExecutionConfig()
final PackageConfig packageConfig = new PackageConfig(null)
final AnalysisConfig analysisConfig = new AnalysisConfig()
- new TestPackageBuilder(testCasePath, testConfig,
+ def tpb = new TestPackageBuilder(testCasePath, testConfig,
executionConfig, context, packageConfig, analysisConfig)
when:
@@ -46,15 +46,15 @@ class TestPackageBuilderTest extends Specification {
ExecutionOrder order = executionOrderBuilder.build()
then:
- assertBuilder()
+ assertBuilder(tpb)
assertExecutionOrder(order)
}
- void assertBuilder() {
- assert TestPackageBuilder.testCasePath == 'testFile'
- assert TestPackageBuilder.testConfig != null
- assert TestPackageBuilder.executionConfig != null
- assert TestPackageBuilder.context != null
+ void assertBuilder(TestPackageBuilder tpb) {
+ assert tpb.testCasePath == 'testFile'
+ assert tpb.testConfig != null
+ assert tpb.executionConfig != null
+ assert tpb.context != null
}
void assertExecutionOrder(ExecutionOrder order) {
diff --git a/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilderTest.groovy b/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilderTest.groovy
index 593c58d9..360f79f4 100644
--- a/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilderTest.groovy
+++ b/src/test/groovy/de/tracetronic/jenkins/plugins/ecutestexecution/builder/TestProjectBuilderTest.groovy
@@ -18,13 +18,13 @@ class TestProjectBuilderTest extends Specification {
def 'Test Null Values'() {
given:
- new TestProjectBuilder(null, null, null, null)
+ def tpb = new TestProjectBuilder(null, null, null, null)
expect:
- TestProjectBuilder.testCasePath == null
- TestProjectBuilder.testConfig == null
- TestProjectBuilder.executionConfig == null
- TestProjectBuilder.context == null
+ tpb.testCasePath == null
+ tpb.testConfig == null
+ tpb.executionConfig == null
+ tpb.context == null
}
def 'Test Default Values'() {
@@ -33,7 +33,7 @@ class TestProjectBuilderTest extends Specification {
final String testCasePath = 'testFile'
final TestConfig testConfig = new TestConfig()
final ExecutionConfig executionConfig = new ExecutionConfig()
- new TestProjectBuilder(testCasePath, testConfig,
+ def tpb = new TestProjectBuilder(testCasePath, testConfig,
executionConfig, context)
when:
@@ -41,15 +41,15 @@ class TestProjectBuilderTest extends Specification {
ExecutionOrder order = executionOrderBuilder.build()
then:
- assertBuilder()
+ assertBuilder(tpb)
assertExecutionOrder(order)
}
- void assertBuilder() {
- assert TestProjectBuilder.testCasePath == 'testFile'
- assert TestProjectBuilder.testConfig != null
- assert TestProjectBuilder.executionConfig != null
- assert TestProjectBuilder.context != null
+ void assertBuilder(TestProjectBuilder tpb) {
+ assert tpb.testCasePath == 'testFile'
+ assert tpb.testConfig != null
+ assert tpb.executionConfig != null
+ assert tpb.context != null
}
void assertExecutionOrder(ExecutionOrder order) {