From 3e556f4afbabad2d310d0f6e5578e5cc6b8d514a Mon Sep 17 00:00:00 2001 From: Marcus Holl Date: Thu, 27 Sep 2018 15:45:28 +0200 Subject: [PATCH 01/12] test asserting setupCPE works with config properties file --- .../SetupCommonPipelineEnvironmentTest.groovy | 29 +++++++++++++++++-- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git a/test/groovy/SetupCommonPipelineEnvironmentTest.groovy b/test/groovy/SetupCommonPipelineEnvironmentTest.groovy index 8b4a022c9..d44ac3225 100644 --- a/test/groovy/SetupCommonPipelineEnvironmentTest.groovy +++ b/test/groovy/SetupCommonPipelineEnvironmentTest.groovy @@ -35,13 +35,21 @@ class SetupCommonPipelineEnvironmentTest extends BasePiperTest { usedConfigFile = parameters.file return yamlParser.load(examplePipelineConfig) }) - helper.registerAllowedMethod("fileExists", [String], { String path -> - return path.endsWith('.pipeline/config.yml') + helper.registerAllowedMethod("readProperties", [Map], { Map parameters -> + usedConfigFile = parameters.file + Properties props = new Properties() + props.setProperty('key', 'value') + return props }) } @Test - void testIsConfigurationAvailable() throws Exception { + void testIsYamlConfigurationAvailable() throws Exception { + + helper.registerAllowedMethod("fileExists", [String], { String path -> + return path.endsWith('.pipeline/config.yml') + }) + jsr.step.call(script: nullScript) assertEquals('.pipeline/config.yml', usedConfigFile) @@ -49,4 +57,19 @@ class SetupCommonPipelineEnvironmentTest extends BasePiperTest { assertEquals('develop', nullScript.commonPipelineEnvironment.configuration.general.productiveBranch) assertEquals('my-maven-docker', nullScript.commonPipelineEnvironment.configuration.steps.mavenExecute.dockerImage) } + + @Test + void testIsPropertiesConfigurationAvailable() { + + helper.registerAllowedMethod("fileExists", [String], { String path -> + return path.endsWith('.pipeline/config.properties') + }) + + jsr.step.call(script: nullScript) + + assertEquals('.pipeline/config.properties', usedConfigFile) + assertNotNull(nullScript.commonPipelineEnvironment.configProperties) + assertEquals('value', nullScript.commonPipelineEnvironment.configProperties['key']) + } + } From 18d27532080de60063d321b3874399d2b7d71ffc Mon Sep 17 00:00:00 2001 From: Marcus Holl Date: Mon, 17 Sep 2018 16:51:13 +0200 Subject: [PATCH 02/12] Remove explict getters and setters from common pipeline environment We get getters and setters generated automatically. --- vars/commonPipelineEnvironment.groovy | 49 +++------------------------ 1 file changed, 4 insertions(+), 45 deletions(-) diff --git a/vars/commonPipelineEnvironment.groovy b/vars/commonPipelineEnvironment.groovy index eade1b078..b3e4ebfd9 100644 --- a/vars/commonPipelineEnvironment.groovy +++ b/vars/commonPipelineEnvironment.groovy @@ -1,12 +1,12 @@ class commonPipelineEnvironment implements Serializable { - private Map configProperties = [:] + Map configProperties = [:] //stores version of the artifact which is build during pipeline run def artifactVersion //stores the gitCommitId as well as additional git information for the build during pipeline run - private String gitCommitId - private String gitSshUrl + String gitCommitId + String gitSshUrl //stores properties for a pipeline which build an artifact and then bundles it into a container private Map appContainerProperties = [:] @@ -19,7 +19,7 @@ class commonPipelineEnvironment implements Serializable { //influxCustomData represents measurement jenkins_custom_data in Influx. Metrics can be written into this map private Map influxCustomData = [:] - private String mtarFilePath + String mtarFilePath def reset() { appContainerProperties = [:] @@ -45,22 +45,6 @@ class commonPipelineEnvironment implements Serializable { return appContainerProperties[property] } - def setArtifactVersion(version) { - artifactVersion = version - } - - def getArtifactVersion() { - return artifactVersion - } - - def setConfigProperties(map) { - configProperties = map - } - - def getConfigProperties() { - return configProperties - } - def setConfigProperty(property, value) { configProperties[property] = value } @@ -72,22 +56,6 @@ class commonPipelineEnvironment implements Serializable { return configProperties[property] } - def setGitCommitId(commitId) { - gitCommitId = commitId - } - - def getGitCommitId() { - return gitCommitId - } - - def setGitSshUrl(url) { - gitSshUrl = url - } - - def getGitSshUrl() { - return gitSshUrl - } - def getInfluxCustomData() { return influxCustomData } @@ -103,15 +71,6 @@ class commonPipelineEnvironment implements Serializable { return influxCustomDataMap.step_data[dataKey] } - - def getMtarFilePath() { - return mtarFilePath - } - - void setMtarFilePath(mtarFilePath) { - this.mtarFilePath = mtarFilePath - } - def setPipelineMeasurement (measurementName, value) { influxCustomDataMap.pipeline_data[measurementName] = value } From 252c6da4bd05e65e95c10c3536747bf1fbb3c3dd Mon Sep 17 00:00:00 2001 From: Marcus Holl Date: Mon, 1 Oct 2018 13:56:59 +0200 Subject: [PATCH 03/12] Ensure the order of the git commands Up to now we checked for git commands, but the order was not taken into account. Test would pass even if the commit happens before git add. Now the order of the git commits is asserted. --- test/groovy/ArtifactSetVersionTest.groovy | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/test/groovy/ArtifactSetVersionTest.groovy b/test/groovy/ArtifactSetVersionTest.groovy index 82931b8d3..d55c9858d 100644 --- a/test/groovy/ArtifactSetVersionTest.groovy +++ b/test/groovy/ArtifactSetVersionTest.groovy @@ -22,6 +22,7 @@ import util.Rules import static org.hamcrest.Matchers.hasItem import static org.hamcrest.Matchers.hasItems import static org.hamcrest.Matchers.notNullValue +import static org.hamcrest.Matchers.stringContainsInOrder import static org.hamcrest.Matchers.containsString import static org.junit.Assert.assertThat @@ -89,10 +90,13 @@ class ArtifactSetVersionTest extends BasePiperTest { assertEquals('testCommitId', jer.env.getGitCommitId()) assertThat(jscr.shell, hasItem("mvn --file 'pom.xml' --batch-mode -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn versions:set -DnewVersion=1.2.3-20180101010203_testCommitId -DgenerateBackupPoms=false")) - assertThat(jscr.shell, hasItems(containsString("git add ."), - containsString("git commit -m 'update version 1.2.3-20180101010203_testCommitId'"), - containsString('git tag build_1.2.3-20180101010203_testCommitId'), - containsString('git push myGitSshUrl build_1.2.3-20180101010203_testCommitId'))) + assertThat(jscr.shell.join(), stringContainsInOrder([ + "git add .", + "git commit -m 'update version 1.2.3-20180101010203_testCommitId'", + 'git tag build_1.2.3-20180101010203_testCommitId', + 'git push myGitSshUrl build_1.2.3-20180101010203_testCommitId', + ] + )) } @Test From 34b675a030e10780dc5a818f57aa7f56705896fc Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 11:30:42 +0200 Subject: [PATCH 04/12] handle test repositories (#324) * handle test repositories * use GitUtils * add test case * fix test cases * return stash name * handle seleniumExecuteTests step * Revert "handle seleniumExecuteTests step" This reverts commit 2b33d274fe48ee4d294189bf55d007ba15bc2824. * handle seleniumExecuteTests step * add import of GitUtils --- src/com/sap/piper/GitUtils.groovy | 15 +++++++ test/groovy/BatsExecuteTestsTest.groovy | 7 ++-- test/groovy/SeleniumExecuteTestsTest.groovy | 1 + test/groovy/com/sap/piper/GitUtilsTest.groovy | 42 ++++++++++++++++--- vars/batsExecuteTests.groovy | 19 +++------ vars/newmanExecute.groovy | 17 +++----- vars/seleniumExecuteTests.groovy | 12 ++---- 7 files changed, 71 insertions(+), 42 deletions(-) diff --git a/src/com/sap/piper/GitUtils.groovy b/src/com/sap/piper/GitUtils.groovy index cb41f911c..d3c67e4d6 100644 --- a/src/com/sap/piper/GitUtils.groovy +++ b/src/com/sap/piper/GitUtils.groovy @@ -37,3 +37,18 @@ String[] extractLogLines(String filter = '', ?.findAll { line -> line ==~ /${filter}/ } } + +static String handleTestRepository(Script steps, Map config){ + def stashName = "testContent-${UUID.randomUUID()}".toString() + def options = [url: config.testRepository] + if (config.gitSshKeyCredentialsId) + options.put('credentialsId', config.gitSshKeyCredentialsId) + if (config.gitBranch) + options.put('branch', config.gitBranch) + // checkout test repository + steps.git options + // stash test content + steps.stash stashName + // return stash name + return stashName +} diff --git a/test/groovy/BatsExecuteTestsTest.groovy b/test/groovy/BatsExecuteTestsTest.groovy index 1616ca92a..0e8bd3350 100644 --- a/test/groovy/BatsExecuteTestsTest.groovy +++ b/test/groovy/BatsExecuteTestsTest.groovy @@ -7,6 +7,7 @@ import util.* import static org.hamcrest.Matchers.hasItem import static org.hamcrest.Matchers.is +import static org.hamcrest.Matchers.startsWith import static org.junit.Assert.assertThat class BatsExecuteTestsTest extends BasePiperTest { @@ -104,7 +105,7 @@ class BatsExecuteTestsTest extends BasePiperTest { gitRepository = m }) helper.registerAllowedMethod('stash', [String.class], {s -> - assertThat(s, is('batsTests')) + assertThat(s, startsWith('testContent-')) }) jsr.step.batsExecuteTests( @@ -115,7 +116,7 @@ class BatsExecuteTestsTest extends BasePiperTest { assertThat(gitRepository.size(), is(1)) assertThat(gitRepository.url, is('testRepo')) - assertThat(jder.dockerParams.stashContent, hasItem('batsTests')) + assertThat(jder.dockerParams.stashContent, hasItem(startsWith('testContent-'))) } @Test @@ -125,7 +126,7 @@ class BatsExecuteTestsTest extends BasePiperTest { gitRepository = m }) helper.registerAllowedMethod('stash', [String.class], {s -> - assertThat(s, is('batsTests')) + assertThat(s, startsWith('testContent-')) }) jsr.step.batsExecuteTests( diff --git a/test/groovy/SeleniumExecuteTestsTest.groovy b/test/groovy/SeleniumExecuteTestsTest.groovy index ec9f10e8f..1b73081cd 100644 --- a/test/groovy/SeleniumExecuteTestsTest.groovy +++ b/test/groovy/SeleniumExecuteTestsTest.groovy @@ -31,6 +31,7 @@ class SeleniumExecuteTestsTest extends BasePiperTest { @Before void init() throws Exception { bodyExecuted = false + helper.registerAllowedMethod('stash', [String.class], null) helper.registerAllowedMethod('git', [Map.class], {m -> gitMap = m }) diff --git a/test/groovy/com/sap/piper/GitUtilsTest.groovy b/test/groovy/com/sap/piper/GitUtilsTest.groovy index 121cc2c76..3b23df1a4 100644 --- a/test/groovy/com/sap/piper/GitUtilsTest.groovy +++ b/test/groovy/com/sap/piper/GitUtilsTest.groovy @@ -1,20 +1,26 @@ package com.sap.piper +import static org.hamcrest.Matchers.equalTo +import static org.hamcrest.Matchers.hasEntry +import static org.hamcrest.Matchers.hasItem +import static org.hamcrest.Matchers.is +import static org.hamcrest.Matchers.notNullValue +import static org.hamcrest.Matchers.startsWith + import org.junit.Before import org.junit.Rule import org.junit.Test import org.junit.rules.ExpectedException import org.junit.rules.RuleChain + import util.BasePiperTest +import util.JenkinsLoggingRule import util.JenkinsShellCallRule import util.Rules import static org.junit.Assert.assertEquals -import static org.hamcrest.Matchers.equalTo import static org.junit.Assert.assertTrue import static org.junit.Assert.assertFalse -import static org.hamcrest.Matchers.is -import static org.hamcrest.Matchers.notNullValue import static org.junit.Assert.assertNotNull import static org.junit.Assert.assertNull import static org.junit.Assert.assertThat @@ -26,11 +32,15 @@ class GitUtilsTest extends BasePiperTest { @Autowired GitUtils gitUtils - JenkinsShellCallRule jscr = new JenkinsShellCallRule(this) - ExpectedException thrown = ExpectedException.none() + private JenkinsLoggingRule jlr = new JenkinsLoggingRule(this) + private JenkinsShellCallRule jscr = new JenkinsShellCallRule(this) + private ExpectedException thrown = ExpectedException.none() @Rule - public RuleChain ruleChain = Rules.getCommonRules(this).around(jscr).around(thrown) + public RuleChain ruleChain = Rules.getCommonRules(this) + .around(jlr) + .around(jscr) + .around(thrown) @Before void init() throws Exception { @@ -96,4 +106,24 @@ class GitUtilsTest extends BasePiperTest { assertNotNull(log) assertThat(log.size(),is(equalTo(0))) } + + @Test + void testHandleTestRepository() { + def result, gitMap, stashName, config = [ + testRepository: 'repoUrl', + gitSshKeyCredentialsId: 'abc', + gitBranch: 'master' + ] + + helper.registerAllowedMethod('git', [Map.class], {m -> gitMap = m }) + helper.registerAllowedMethod("stash", [String.class], { s -> stashName = s}) + + result = GitUtils.handleTestRepository(nullScript, config) + // asserts + assertThat(gitMap, hasEntry('url', config.testRepository)) + assertThat(gitMap, hasEntry('credentialsId', config.gitSshKeyCredentialsId)) + assertThat(gitMap, hasEntry('branch', config.gitBranch)) + assertThat(stashName, startsWith('testContent-')) + assertThat(result, startsWith('testContent-')) + } } diff --git a/vars/batsExecuteTests.groovy b/vars/batsExecuteTests.groovy index c9bf894bd..67a8e3c1c 100644 --- a/vars/batsExecuteTests.groovy +++ b/vars/batsExecuteTests.groovy @@ -1,11 +1,12 @@ -import com.sap.piper.Utils import com.sap.piper.ConfigurationHelper +import com.sap.piper.GitUtils +import com.sap.piper.Utils import groovy.text.SimpleTemplateEngine import groovy.transform.Field @Field String STEP_NAME = 'batsExecuteTests' @Field Set STEP_CONFIG_KEYS = [ - 'dockerImage', // + 'dockerImage', 'dockerWorkspace', 'envVars', 'failOnError', @@ -39,17 +40,9 @@ def call(Map parameters = [:]) { script.commonPipelineEnvironment.setInfluxStepData('bats', false) - - if (config.testRepository) { - def gitParameters = [url: config.testRepository] - if (config.gitSshKeyCredentialsId?.length()>0) gitParameters.credentialsId = config.gitSshKeyCredentialsId - if (config.gitBranch?.length()>0) gitParameters.branch = config.gitBranch - git gitParameters - stash 'batsTests' - config.stashContent = ['batsTests'] - } else { - config.stashContent = utils.unstashAll(config.stashContent) - } + config.stashContent = config.testRepository + ?[GitUtils.handleTestRepository(this, config)] + :utils.unstashAll(config.stashContent) //resolve commonPipelineEnvironment references in envVars config.envVarList = [] diff --git a/vars/newmanExecute.groovy b/vars/newmanExecute.groovy index 543ce4a96..00a78c40a 100644 --- a/vars/newmanExecute.groovy +++ b/vars/newmanExecute.groovy @@ -1,8 +1,8 @@ -import com.sap.piper.Utils import com.sap.piper.ConfigurationHelper +import com.sap.piper.GitUtils import com.sap.piper.Utils -import groovy.transform.Field import groovy.text.SimpleTemplateEngine +import groovy.transform.Field @Field String STEP_NAME = 'newmanExecute' @Field Set STEP_CONFIG_KEYS = [ @@ -35,16 +35,9 @@ def call(Map parameters = [:]) { new Utils().pushToSWA([step: STEP_NAME], config) - if (config.testRepository) { - def gitParameters = [url: config.testRepository] - if (config.gitSshKeyCredentialsId) gitParameters.credentialsId = config.gitSshKeyCredentialsId - if (config.gitBranch) gitParameters.branch = config.gitBranch - git gitParameters - stash 'newmanContent' - config.stashContent = ['newmanContent'] - } else { - config.stashContent = utils.unstashAll(config.stashContent) - } + config.stashContent = config.testRepository + ?[GitUtils.handleTestRepository(this, config)] + :utils.unstashAll(config.stashContent) List collectionList = findFiles(glob: config.newmanCollection)?.toList() if (collectionList.isEmpty()) { diff --git a/vars/seleniumExecuteTests.groovy b/vars/seleniumExecuteTests.groovy index 0404839ca..79895eae3 100644 --- a/vars/seleniumExecuteTests.groovy +++ b/vars/seleniumExecuteTests.groovy @@ -1,5 +1,6 @@ import com.sap.piper.Utils import com.sap.piper.ConfigurationHelper +import com.sap.piper.GitUtils import com.sap.piper.Utils import com.sap.piper.k8s.ContainerMap import groovy.transform.Field @@ -54,14 +55,9 @@ def call(Map parameters = [:], Closure body) { sidecarVolumeBind: config.sidecarVolumeBind ) { try { - if (config.testRepository) { - def gitParameters = [url: config.testRepository] - if (config.gitSshKeyCredentialsId) gitParameters.credentialsId = config.gitSshKeyCredentialsId - if (config.gitBranch) gitParameters.branch = config.gitBranch - git gitParameters - } else { - config.stashContent = utils.unstashAll(config.stashContent) - } + config.stashContent = config.testRepository + ?[GitUtils.handleTestRepository(this, config)] + :utils.unstashAll(config.stashContent) body() } catch (err) { if (config.failOnError) { From d6f47e802ac0f9679eeb5f84755bbce2003807ab Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 11:54:13 +0200 Subject: [PATCH 05/12] executeDockerOnKubernetes: support workspace/container stashing for sidecar case (#330) * simplify parameter handover * extract default contaner name and map * condense pod execution methods * simplify closure handling * fix map issue * simplify * stash only if needed * fix test case --- .../DockerExecuteOnKubernetesTest.groovy | 20 +++--- vars/dockerExecuteOnKubernetes.groovy | 62 +++++++------------ 2 files changed, 32 insertions(+), 50 deletions(-) diff --git a/test/groovy/DockerExecuteOnKubernetesTest.groovy b/test/groovy/DockerExecuteOnKubernetesTest.groovy index a531cb6f8..55cb9d2a5 100644 --- a/test/groovy/DockerExecuteOnKubernetesTest.groovy +++ b/test/groovy/DockerExecuteOnKubernetesTest.groovy @@ -71,7 +71,7 @@ class DockerExecuteOnKubernetesTest extends BasePiperTest { podLabel = options.label options.containers.each { option -> containersList.add(option.name) - imageList.add(option.image) + imageList.add(option.image.toString()) envList.add(option.envVars) portList.add(option.ports) if (option.command) { @@ -91,19 +91,19 @@ class DockerExecuteOnKubernetesTest extends BasePiperTest { dockerImage: 'maven:3.5-jdk-8-alpine', dockerOptions: '-it', dockerVolumeBind: ['my_vol': '/my_vol'], - dockerEnvVars: ['http_proxy': 'http://proxy:8000'], dockerWorkspace: '/home/piper'){ - bodyExecuted = true + dockerEnvVars: ['http_proxy': 'http://proxy:8000'], dockerWorkspace: '/home/piper' + ){ + bodyExecuted = true } - assertTrue(containersList.contains('container-exec')) - assertTrue(imageList.contains('maven:3.5-jdk-8-alpine')) - assertTrue(envList.toString().contains('http_proxy')) - assertTrue(envList.toString().contains('http://proxy:8000')) - assertTrue(envList.toString().contains('/home/piper')) - assertTrue(bodyExecuted) + assertThat(containersList, hasItem('container-exec')) + assertThat(imageList, hasItem('maven:3.5-jdk-8-alpine')) + assertThat(envList.toString(), containsString('http_proxy')) + assertThat(envList.toString(), containsString('http://proxy:8000')) + assertThat(envList.toString(), containsString('/home/piper')) + assertThat(bodyExecuted, is(true)) assertThat(containerCommands.size(), is(1)) } - @Test void testDockerExecuteOnKubernetesWithCustomContainerMap() throws Exception { jsr.step.dockerExecuteOnKubernetes(script: nullScript, diff --git a/vars/dockerExecuteOnKubernetes.groovy b/vars/dockerExecuteOnKubernetes.groovy index 65f475029..0edcda9ca 100644 --- a/vars/dockerExecuteOnKubernetes.groovy +++ b/vars/dockerExecuteOnKubernetes.groovy @@ -36,34 +36,14 @@ void call(Map parameters = [:], body) { .mixinStageConfig(script.commonPipelineEnvironment, parameters.stageName ?: env.STAGE_NAME, STEP_CONFIG_KEYS) .mixin(parameters, PARAMETER_KEYS) .addIfEmpty('uniqueId', UUID.randomUUID().toString()) - Map config = [:] + Map config = configHelper.use() - if (parameters.containerMap) { - config = configHelper.use() - executeOnPodWithCustomContainerList(config: config) { body() } - - } else { - config = configHelper - .withMandatoryProperty('dockerImage') - .use() - executeOnPodWithSingleContainer(config: config) { body() } - } - } -} - -void executeOnPodWithCustomContainerList(Map parameters, body) { - def config = parameters.config - podTemplate(getOptions(config)) { - node(config.uniqueId) { - //allow execution in dedicated container - if (config.containerName) { - container(name: config.containerName){ - body() - } - } else { - body() - } + if (!parameters.containerMap) { + configHelper.withMandatoryProperty('dockerImage') + config.containerName = 'container-exec' + config.containerMap = ["${config.get('dockerImage')}": config.containerName] } + executeOnPod(config, body) } } @@ -73,37 +53,39 @@ def getOptions(config) { containers: getContainerList(config)] } -void executeOnPodWithSingleContainer(Map parameters, body) { - Map containerMap = [:] - def config = parameters.config - containerMap[config.get('dockerImage').toString()] = 'container-exec' - config.containerMap = containerMap +void executeOnPod(Map config, Closure body) { /* * There could be exceptions thrown by - The podTemplate - The container method - The body * We use nested exception handling in this case. - * In the first 2 cases, the 'container' stash is not created because the inner try/finally is not reached. + * In the first 2 cases, the 'container' stash is not created because the inner try/finally is not reached. * However, the workspace has not been modified and don't need to be restored. * In case third case, we need to create the 'container' stash to bring the modified content back to the host. */ try { - stashWorkspace(config, 'workspace') + if (config.containerName) + stashWorkspace(config, 'workspace') podTemplate(getOptions(config)) { node(config.uniqueId) { - container(name: 'container-exec') { - try { - unstashWorkspace(config, 'workspace') - body() - } finally { - stashWorkspace(config, 'container') + if (config.containerName) { + container(name: config.containerName){ + try { + unstashWorkspace(config, 'workspace') + body() + } finally { + stashWorkspace(config, 'container') + } } + } else { + body() } } } } finally { - unstashWorkspace(config, 'container') + if (config.containerName) + unstashWorkspace(config, 'container') } } From a24c1457d27374cb329ec2373844288a9e71f58b Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:36:29 +0200 Subject: [PATCH 06/12] remove unnecessary import --- src/com/sap/piper/ConfigurationMerger.groovy | 1 - 1 file changed, 1 deletion(-) diff --git a/src/com/sap/piper/ConfigurationMerger.groovy b/src/com/sap/piper/ConfigurationMerger.groovy index 0e95a782c..4c3ec4675 100644 --- a/src/com/sap/piper/ConfigurationMerger.groovy +++ b/src/com/sap/piper/ConfigurationMerger.groovy @@ -1,7 +1,6 @@ package com.sap.piper import com.cloudbees.groovy.cps.NonCPS -import com.sap.piper.MapUtils class ConfigurationMerger { @NonCPS From e068c52f6cae20d1277fa7396caee2c36ff95a88 Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:38:16 +0200 Subject: [PATCH 07/12] remove unnecessary import --- vars/transportRequestUploadFile.groovy | 2 -- 1 file changed, 2 deletions(-) diff --git a/vars/transportRequestUploadFile.groovy b/vars/transportRequestUploadFile.groovy index 98d388667..c7050a946 100644 --- a/vars/transportRequestUploadFile.groovy +++ b/vars/transportRequestUploadFile.groovy @@ -1,9 +1,7 @@ -import com.sap.piper.GitUtils import com.sap.piper.Utils import groovy.transform.Field import com.sap.piper.ConfigurationHelper -import com.sap.piper.ConfigurationMerger import com.sap.piper.cm.ChangeManagement import com.sap.piper.cm.ChangeManagementException From 0bc21ed7e24910090583fc58adae476411b09366 Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:38:54 +0200 Subject: [PATCH 08/12] remove unnecessary import --- vars/transportRequestRelease.groovy | 2 -- 1 file changed, 2 deletions(-) diff --git a/vars/transportRequestRelease.groovy b/vars/transportRequestRelease.groovy index e5ecbcd9f..8789c55fa 100644 --- a/vars/transportRequestRelease.groovy +++ b/vars/transportRequestRelease.groovy @@ -1,9 +1,7 @@ -import com.sap.piper.GitUtils import com.sap.piper.Utils import groovy.transform.Field import com.sap.piper.ConfigurationHelper -import com.sap.piper.ConfigurationMerger import com.sap.piper.cm.ChangeManagement import com.sap.piper.cm.ChangeManagementException From 475b977f17652e877d66cdb8ee2e09acb964ede5 Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:39:23 +0200 Subject: [PATCH 09/12] remove unnecessary import --- vars/transportRequestCreate.groovy | 2 -- 1 file changed, 2 deletions(-) diff --git a/vars/transportRequestCreate.groovy b/vars/transportRequestCreate.groovy index 504ee725a..59fa6b029 100644 --- a/vars/transportRequestCreate.groovy +++ b/vars/transportRequestCreate.groovy @@ -1,9 +1,7 @@ -import com.sap.piper.GitUtils import com.sap.piper.Utils import groovy.transform.Field import com.sap.piper.ConfigurationHelper -import com.sap.piper.ConfigurationMerger import com.sap.piper.cm.ChangeManagement import com.sap.piper.cm.ChangeManagementException From bab477270487704e873425d8fc193cf14d90a988 Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:39:57 +0200 Subject: [PATCH 10/12] remove unnecessary imports --- vars/testsPublishResults.groovy | 1 - 1 file changed, 1 deletion(-) diff --git a/vars/testsPublishResults.groovy b/vars/testsPublishResults.groovy index d168eaaca..eedb69acb 100644 --- a/vars/testsPublishResults.groovy +++ b/vars/testsPublishResults.groovy @@ -1,7 +1,6 @@ import com.cloudbees.groovy.cps.NonCPS import com.sap.piper.ConfigurationHelper -import com.sap.piper.ConfigurationMerger import com.sap.piper.MapUtils import com.sap.piper.Utils import groovy.transform.Field From 27959e4644abd9b90fa3056dcc9a0abb30168661 Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:41:00 +0200 Subject: [PATCH 11/12] remove unnecessary imports --- src/com/sap/piper/cm/ChangeManagement.groovy | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/com/sap/piper/cm/ChangeManagement.groovy b/src/com/sap/piper/cm/ChangeManagement.groovy index 06db849ce..fdab14c91 100644 --- a/src/com/sap/piper/cm/ChangeManagement.groovy +++ b/src/com/sap/piper/cm/ChangeManagement.groovy @@ -1,7 +1,5 @@ package com.sap.piper.cm -import java.util.Map - import com.sap.piper.GitUtils import hudson.AbortException From e0aa95645b01bd3494e0d4d3985c7ae606f76201 Mon Sep 17 00:00:00 2001 From: Christopher Fenner Date: Mon, 8 Oct 2018 09:43:22 +0200 Subject: [PATCH 12/12] remove unnecessary import --- vars/seleniumExecuteTests.groovy | 1 - 1 file changed, 1 deletion(-) diff --git a/vars/seleniumExecuteTests.groovy b/vars/seleniumExecuteTests.groovy index 79895eae3..23a7d9e52 100644 --- a/vars/seleniumExecuteTests.groovy +++ b/vars/seleniumExecuteTests.groovy @@ -1,4 +1,3 @@ -import com.sap.piper.Utils import com.sap.piper.ConfigurationHelper import com.sap.piper.GitUtils import com.sap.piper.Utils