diff --git a/resources/com.sap.piper/pipeline/cloudSdkContainersMap.yml b/resources/com.sap.piper/pipeline/cloudSdkContainersMap.yml deleted file mode 100644 index a24f41aba..000000000 --- a/resources/com.sap.piper/pipeline/cloudSdkContainersMap.yml +++ /dev/null @@ -1,54 +0,0 @@ -# Mapping of Go step names to their YAML metadata resource file -stepMetadata: - artifactPrepareVersion: versioning.yaml - mavenExecute: mavenExecute.yaml - mavenExecuteStaticCodeChecks: mavenStaticCodeChecks.yaml - mtaBuild: mtaBuild.yaml - nexusUpload: nexusUpload.yaml - npmExecuteScripts: npmExecuteScripts.yaml - npmExecuteLint: npmExecuteLint.yaml - sonarExecuteScan: sonar.yaml - -# Mapping of stages to the steps (and by extension Docker images) they use -containerMaps: - init: - - artifactPrepareVersion - - mavenExecute - - executeNpm - build: - - mavenBuild - - mtaBuild - - npmExecuteScripts - - mavenExecute - - executeNpm - - mtaBuild - - mavenExecuteStaticCodeChecks - - npmExecuteLint - integration: - - mavenExecute - - executeNpm - - createHdiContainer - - npmExecuteScripts - additionalUnitTests: - - npmExecuteScripts - endToEndTests: - - mavenExecute - - npmExecuteScripts - - cloudFoundryDeploy - - neoDeploy - - cloudFoundryCreateService - performanceTests: - - mavenExecute - - checkJMeter - - cloudFoundryDeploy - - neoDeploy - artifactDeployment: - - nexusUpload - compliance: - - sonarExecuteScan - productionDeployment: - - mavenExecute - - npmExecuteScripts - - cloudFoundryDeploy - - neoDeploy - - cloudFoundryCreateService diff --git a/resources/com.sap.piper/pipeline/cloudSdkJavaStashSettings.yml b/resources/com.sap.piper/pipeline/cloudSdkJavaStashSettings.yml deleted file mode 100644 index 5ccf7b4eb..000000000 --- a/resources/com.sap.piper/pipeline/cloudSdkJavaStashSettings.yml +++ /dev/null @@ -1,82 +0,0 @@ -# This stage names are used for stashing and un-stashing of files - -init: - unstash: [] - stashes: - - name: "SOURCE" - includes: "**" - excludes: "**/.git/**, s4hana_pipeline/reports/**, s4hana_pipeline/maven_local_repo/**" - - name: "M2" - includes: "s4hana_pipeline/maven_local_repo/**" - # Following stash will contain only empty directory. - # This is required to support the concurrency in the stashing mechanism where - # we merge the stashes from multiple stages into one. - - name: "REPORTS" - includes: "s4hana_pipeline/reports/**" - -build: - unstash: ["SOURCE", "M2"] - stashes: - - name: "M2" - includes: "s4hana_pipeline/maven_local_repo/**" - - name: "TARGET" - includes: "**/target/**" - - name: "NODE_MODULES" - includes: "**/node_modules/**" - - name: "PACKAGE_LOCK" - includes: "**/package-lock.json, **/npm-shrinkwrap.json" - - name: "GENERATED_CAP_FILES" - includes: "**/src/main/resources/edmx/**, db/src/gen/**, gen/**" - - name: "EXEC_FILES" - includes: "**/target/**/*.exec" - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**, **/target/site/**/jacoco.xml" - -integration: - unstash: ["SOURCE", "M2", "TARGET", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**, **/target/site/**/jacoco.xml" - - name: "EXEC_FILES" - merge: true - includes: "**/target/**/*.exec" - -compliance: - unstash: ['SOURCE', 'M2', 'REPORTS', 'TARGET', 'EXEC_FILES'] - stashes: [] - -security: - unstash: ["SOURCE"] - stashes: [] - -additionalUnitTests: - unstash: ["SOURCE", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**, **/target/site/**/jacoco.xml" - -endToEndTests: - unstash: ["SOURCE", "TARGET", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: [] - -performanceTests: - unstash: ["SOURCE", "TARGET", "GENERATED_CAP_FILES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**" - -artifactDeployment: - unstash: ["SOURCE", "M2", "TARGET", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: [] - -productionDeployment: - unstash: ["SOURCE", "TARGET", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: [] - -postPipelineHook: - unstash: ["SOURCE"] - stashes: [] diff --git a/resources/com.sap.piper/pipeline/cloudSdkJavascriptStashSettings.yml b/resources/com.sap.piper/pipeline/cloudSdkJavascriptStashSettings.yml deleted file mode 100644 index 5fcaf1ef7..000000000 --- a/resources/com.sap.piper/pipeline/cloudSdkJavascriptStashSettings.yml +++ /dev/null @@ -1,65 +0,0 @@ -# This stage names are used for stashing and un-stashing of files - -init: - unstash: [] - stashes: - - name: "SOURCE" - includes: "**" - excludes: "**/.git/**, s4hana_pipeline/reports/**" - # Following stash will contain only empty directory. - # This is required to support the concurrency in the stashing mechanism where - # we merge the stashes from multiple stages into one. - - name: "REPORTS" - includes: "s4hana_pipeline/reports/**" - -build: - unstash: ["SOURCE"] - stashes: - - name: "DIST" - includes: "**/dist/**" - - name: "NODE_MODULES" - includes: "**/node_modules/**" - - name: "PACKAGE_LOCK" - includes: "**/package-lock.json, **/npm-shrinkwrap.json" - - name: "GENERATED_CAP_FILES" - includes: "db/src/gen/**, gen/**" - - name: "DEPLOYMENTARTIFACT" - includes: "deployment/**" - -additionalUnitTests: - unstash: ["SOURCE", "DIST", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**" - -integration: - unstash: ["SOURCE", "DIST", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**" - -compliance: - unstash: ['SOURCE', 'NODE_MODULES', 'DIST'] - stashes: [] - -security: - unstash: ["SOURCE"] - stashes: [] - -endToEndTests: - unstash: ["SOURCE", "DEPLOYMENTARTIFACT", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: [] - -artifactDeployment: - unstash: ["SOURCE", "DEPLOYMENTARTIFACT", "GENERATED_CAP_FILES"] - stashes: [] - -productionDeployment: - unstash: ["DEPLOYMENTARTIFACT", "SOURCE", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: [] - -postPipelineHook: - unstash: ["SOURCE"] - stashes: [] diff --git a/resources/com.sap.piper/pipeline/cloudSdkLegacyConfigSettings.yml b/resources/com.sap.piper/pipeline/cloudSdkLegacyConfigSettings.yml deleted file mode 100644 index 85fe77d11..000000000 --- a/resources/com.sap.piper/pipeline/cloudSdkLegacyConfigSettings.yml +++ /dev/null @@ -1,113 +0,0 @@ -removedOrReplacedConfigKeys: - extensionRepository: - newConfigKey: "globalExtensionsRepository" - general: true - customMessage: "To configure a version please use globalExtensionsVersion. - You can also configure globalExtensionsRepositoryCredentialsId in case the extension repository is secured. - Please note that you can also configure these values as part of your custom defaults / shared configuration." - globalSettingsFile: - steps: ["mavenExecute"] - customMessage: "The SAP Cloud SDK Pipeline uses an own global settings file to inject its download proxy as maven repository mirror. - Please only specify the settings via the parameter 'projectSettingsFile'" - orgToken: - newConfigKey: "credentialsId" - stages: ["whitesourceScan"] - customMessage: "Store it as a 'Secret Text' in Jenkins and use the 'credentialsId' field instead." - archiveDebugLog: - postAction: true - customMessage: "Please use the step configuration for debugReportArchive instead." - tmsUpload: - stages: ["productionDeployment"] - customMessage: "Since version v39 it is required to configure the step tmsUpload instead. - Details can be found in the release notes at https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v39 as well as in the step documentation: https://sap.github.io/jenkins-library/steps/tmsUpload/." - sharedConfiguration: - newConfigKey: "customDefaults" - general: true - customMessage: "In addition please move it to the root level of the config file, i.e. before the 'general' section. - The value of this key needs to be a list of strings. - See also https://sap.github.io/jenkins-library/configuration/#custom-default-configuration for more information. - As an example for the necessary change, please consult the release notes of v33 at https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v33" - automaticVersioning: - general: true - customMessage: "Please configure the artifactPrepareVersion step instead. - Details can be found in the release notes of v37 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v37" - sapNpmRegistry: - steps: ["executeNpm", "npmExecuteScripts", "npmExecuteLint", "mtaBuild"] - warnInsteadOfError: true - customMessage: "The parameter will be ignored during execution. - This configuration option was removed in version v41, since the packages of the public SAP NPM Registry were migrated to the default public registry at npmjs.org. - Please configure the defaultNpmRegistry parameter instead, in case a custom NPM registry configuration is required." - sendNotification: - postAction: true - customMessage: "Details can be found in the release notes of v43 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v43" - -removedOrReplacedSteps: - executeMaven: - newStepName: "mavenExecute" - deployToCfWithCli: - newStepName: "cloudFoundryDeploy" - deployToNeoWithCli: - newStepName: "deployToNeoWithCli" - executeFortifyScan: - newStepName: "fortifyExecuteScan" - artifactSetVersion: - newStepName: "artifactPrepareVersion" - onlyCheckProjectConfig: true - customMessage: "Details can be found in the release notes of v37 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v37" - createHdiContainer: - customMessage: "The backendIntegrationTests stage has been aligned with project 'Piper' in version v41 and activation of the createHdiContainer step was not migrated. - If you still need the functionalities provided by the createHdiContainer step, please open an issue at: https://github.com/SAP/cloud-s4-sdk-pipeline/issues/new?template=pipeline-issue.md - Apart from that it is also possible to implement an extension for the backendIntegrationTests stage using the extensibility concept explained in the documentation: https://sap.github.io/jenkins-library/extensibility/ - For the time being, the step createHdiContainer is still available in the Pipeline and can be called from an extension. - The extension must pass all required options to the step via parameters, it cannot be configured in your .pipeline/config.yml." - checkGatling: - newStepName: "gatlingExecuteTests" - -removedOrReplacedStages: - integrationTests: - newStageName: "integration" - backendIntegrationTests: - newStageName: "integration" - frontendIntegrationTests: - newStageName: "integration" - staticCodeChecks: - customMessage: "Since version v32 it is required to migrate the configuration into your pom.xml file or to the configuration of the new step mavenExecuteStaticCodeChecks. - Details can be found in the release notes as well as in the step documentation: https://sap.github.io/jenkins-library/steps/mavenExecuteStaticCodeChecks/." - fortifyScan: - customMessage: "To configure fortify please use the step configuration for fortifyExecuteScan. - Details can be found in the documentation: https://sap.github.io/jenkins-library/steps/fortifyExecuteScan/" - lint: - customMessage: "Since version v43 it is required to configure the step npmExecuteLint instead. - Details can be found in the release notes as well as in the step documentation: https://sap.github.io/jenkins-library/steps/npmExecuteLint/." - frontendUnitTests: - newStageName: "additionalUnitTests" - npmAudit: - customMessage: "Details can be found in the release notes of v43 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v43" - s4SdkQualityChecks: - customMessage: "Details can be found in the release notes of v43 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v43" - sonarQubeScan: - newStageName: "compliance" - customMessage: "Details can be found in the release notes of v43 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v43" - checkmarxScan: - newStageName: "security" - customMessage: "To configure Checkmarx please use the step configuration for checkmarxExecuteScan. - Details can be found in the documentation: https://sap.github.io/jenkins-library/steps/checkmarxExecuteScan/" - detectScan: - newStageName: "security" - customMessage: "To configure Synopsys Detect please use the step configuration for detectExecuteScan. - Details can be found in the documentation: https://sap.github.io/jenkins-library/steps/detectExecuteScan/" - additionalTools: - customMessage: "Details can be found in the release notes of v43 of the pipeline: https://github.com/SAP/cloud-s4-sdk-pipeline/releases/tag/v43" - -parameterTypeChanged: - appUrls: - oldType: "String" - newType: "List" - stages: ["productionDeployment", "endToEndTests"] - -renamedNpmScript: - ci-integration-test: - newScriptName: "ci-it-backend" - ci-test: - newScriptName: "ci-frontend-unit-test" - warnInsteadOfError: true diff --git a/resources/com.sap.piper/pipeline/cloudSdkMtaStashSettings.yml b/resources/com.sap.piper/pipeline/cloudSdkMtaStashSettings.yml deleted file mode 100644 index b57bf5bb6..000000000 --- a/resources/com.sap.piper/pipeline/cloudSdkMtaStashSettings.yml +++ /dev/null @@ -1,82 +0,0 @@ -# This stage names are used for stashing and un-stashing of files - -init: - unstash: [] - stashes: - - name: "SOURCE" - includes: "**" - excludes: "**/.git/**, s4hana_pipeline/reports/**, s4hana_pipeline/maven_local_repo/**" - # Following stash will contain only empty directory. - # This is required to support the concurrency in the stashing mechanism where - # we merge the stashes from multiple stages into one. - - name: "REPORTS" - includes: "s4hana_pipeline/reports/**" - - name: "M2" - includes: "s4hana_pipeline/maven_local_repo/**" - -build: - unstash: ["SOURCE", "M2"] - stashes: - - name: "M2" - includes: "s4hana_pipeline/maven_local_repo/**" - - name: "TARGET" - includes: "*.mtar, **/target/**" - - name: "NODE_MODULES" - includes: "**/node_modules/**" - - name: "PACKAGE_LOCK" - includes: "**/package-lock.json, **/npm-shrinkwrap.json" - - name: "GENERATED_CAP_FILES" - includes: "**/src/main/resources/edmx/**, db/src/gen/**, gen/**" - - name: "EXEC_FILES" - includes: "**/target/**/*.exec" - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**, **/target/site/**/jacoco.xml" - -integration: - unstash: ["SOURCE", "M2", "TARGET", "NODE_MODULES", "GENERATED_CAP_FILES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**, **/target/site/**/jacoco.xml" - - name: "EXEC_FILES" - merge: true - includes: "**/target/**/*.exec" - -compliance: - unstash: ['SOURCE', 'M2', 'NODE_MODULES', 'REPORTS', 'TARGET'] - stashes: [] - -security: - unstash: ["SOURCE"] - stashes: [] - -additionalUnitTests: - unstash: ["SOURCE", "NODE_MODULES"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**, **/target/site/**/jacoco.xml" - -endToEndTests: - unstash: ["SOURCE", "TARGET", "NODE_MODULES"] - stashes: [] - -performanceTests: - unstash: ["SOURCE", "TARGET"] - stashes: - - name: "REPORTS" - merge: true - includes: "s4hana_pipeline/reports/**" - -artifactDeployment: - unstash: ["SOURCE", "M2", "TARGET", "NODE_MODULES", "EXEC_FILES"] - stashes: [] - -productionDeployment: - unstash: ["SOURCE", "TARGET", "NODE_MODULES"] - stashes: [] - -postPipelineHook: - unstash: ["SOURCE"] - stashes: [] diff --git a/resources/com.sap.piper/pipeline/cloudSdkStageDefaults.yml b/resources/com.sap.piper/pipeline/cloudSdkStageDefaults.yml deleted file mode 100644 index 04e35b3c8..000000000 --- a/resources/com.sap.piper/pipeline/cloudSdkStageDefaults.yml +++ /dev/null @@ -1,127 +0,0 @@ -stages: - build: - stepConditions: - mavenExecuteStaticCodeChecks: - filePattern: 'pom.xml' - npmExecuteLint: - filePattern: - - '**/*.js' - - '**/*.jsx' - - '**/*.ts' - - '**/*.tsx' - integration: - stepConditions: - npmExecuteScripts: - npmScripts: - - 'ci-it-backend' - - 'ci-it-frontend' - mavenExecuteIntegration: - filePattern: 'integration-tests/pom.xml' - compliance: - stepConditions: - sonarExecuteScan: - configKeys: - - 'sonarTokenCredentialsId' - - 'projectKey' - - 'instance' - additionalUnitTests: - stepConditions: - npmExecuteScripts: - npmScripts: - - 'ci-frontend-unit-test' - endToEndTests: - stepConditions: - multicloudDeploy: - configKeys: - - 'cfTargets' - - 'neoTargets' - cloudFoundryDeploy: - configKeys: - - 'cfSpace' - - 'cloudFoundry/space' - healthExecuteCheck: - configKeys: - - 'testServerUrl' - newmanExecute: - filePatternFromConfig: 'newmanCollection' - configKeys: - - 'testRepository' - uiVeri5ExecuteTests: - filePattern: '**/conf.js' - configKeys: - - 'testRepository' - npmExecuteEndToEndTests: - configKeys: - - 'appUrls' - performanceTests: - stepConditions: - gatlingExecuteTests: - filePatternFromConfig: 'pomPath' - configKeys: - - 'appUrls' - performanceTests: - configKeys: - - 'cfTargets' - - 'neoTargets' - security: - stepConditions: - checkmarxExecuteScan: - configKeys: - - 'groupId' - detectExecuteScan: - configKeys: - - 'detectTokenCredentialsId' - fortifyExecuteScan: - configKeys: - - 'fortifyCredentialsId' - whitesourceExecuteScan: - configKeys: - - 'productName' - - 'orgAdminUserTokenCredentialsId' - - 'userTokenCredentialsId' - productionDeployment: - stepConditions: - multicloudDeploy: - configKeys: - - 'cfTargets' - - 'neoTargets' - cloudFoundryDeploy: - configKeys: - - 'cfSpace' - - 'cloudFoundry/space' - neoDeploy: - configKeys: - - 'neo/account' - tmsUpload: - configKeys: - - 'credentialsId' - - 'mtaPath' - - 'nodeName' - healthExecuteCheck: - configKeys: - - 'testServerUrl' - npmExecuteEndToEndTests: - configKeys: - - 'appUrls' - githubPublishRelease: - configKeys: - - 'githubTokenCredentialsId' - artifactDeployment: - stepConditions: - artifactDeployment: - configKeys: - - 'nexus' - nexusUpload: - configKeys: - - 'url' - postPipelineHook: - stepConditions: - postPipelineHook: - configKeys: - - 'enabled' - archiveReport: - stepConditions: - archiveReport: - filePattern: - - 'mta.yaml' - - 'pom.xml' diff --git a/resources/com.sap.piper/pipeline/cloudSdkToGppConfigSettings.yml b/resources/com.sap.piper/pipeline/cloudSdkToGppConfigSettings.yml index 943a9c0bd..a531a6fba 100644 --- a/resources/com.sap.piper/pipeline/cloudSdkToGppConfigSettings.yml +++ b/resources/com.sap.piper/pipeline/cloudSdkToGppConfigSettings.yml @@ -1,3 +1,6 @@ +# This file should be removed when existing cloud sdk consumers switched to general purpose pipeline +# This should be safe to do after Q2 2021 + removedOrReplacedConfigKeys: extensionRepository: newConfigKey: "globalExtensionsRepository" diff --git a/resources/com.sap.piper/templates/debug_report.txt b/resources/com.sap.piper/templates/debug_report.txt index d5e795a55..6dcf43943 100644 --- a/resources/com.sap.piper/templates/debug_report.txt +++ b/resources/com.sap.piper/templates/debug_report.txt @@ -1,4 +1,4 @@ -# SAP Cloud SDK `<% print shareConfidentialInformation ? "Confidential" : "Redacted" %>` Debug Log +# Project "Piper" `<% print shareConfidentialInformation ? "Confidential" : "Redacted" %>` Debug Log The debug log is generated with each build and should be included in every support request, don't worry in case you don't understand all of its contents. diff --git a/src/com/sap/piper/QualityCheck.groovy b/src/com/sap/piper/QualityCheck.groovy index bedf02d91..65862213e 100644 --- a/src/com/sap/piper/QualityCheck.groovy +++ b/src/com/sap/piper/QualityCheck.groovy @@ -16,8 +16,6 @@ enum QualityCheck { FortifyScan("Fortify Scan", QualityCheckCategory.SecurityScans), WhiteSourceScan("WhiteSource Scan", QualityCheckCategory.SecurityScans), SourceClearScan("SourceClearScan Scan", QualityCheckCategory.SecurityScans), - ResilienceCheck("Resilience Check", QualityCheckCategory.S4sdkQualityChecks), - OnlyPublicAPIsCheck("Only Public APIs Check", QualityCheckCategory.S4sdkQualityChecks) private String label private QualityCheckCategory category diff --git a/src/com/sap/piper/QualityCheckCategory.groovy b/src/com/sap/piper/QualityCheckCategory.groovy index 0afefeaca..8dc1523af 100644 --- a/src/com/sap/piper/QualityCheckCategory.groovy +++ b/src/com/sap/piper/QualityCheckCategory.groovy @@ -5,7 +5,6 @@ enum QualityCheckCategory { StaticCodeChecks("Static Code Checks"), SecurityScans("Security Scan"), PerformanceTests("Performance Tests"), - S4sdkQualityChecks("SAP Cloud SDK Quality Checks") private String label diff --git a/src/com/sap/piper/TemporaryCredentialsUtils.groovy b/src/com/sap/piper/TemporaryCredentialsUtils.groovy index 7b5933df8..7f91d17ca 100644 --- a/src/com/sap/piper/TemporaryCredentialsUtils.groovy +++ b/src/com/sap/piper/TemporaryCredentialsUtils.groovy @@ -55,7 +55,7 @@ class TemporaryCredentialsUtils implements Serializable { if (!systemsFileFound) { script.error("None of the directories ${credentialsDirectories} contains any of the files systems.yml, systems.yaml or systems.json. " + "One of those files is required in order to activate the integration test credentials configured in the pipeline configuration file of this project. " + - "Please add the file as explained in the SAP Cloud SDK documentation.") + "Please add the file as explained in project 'Piper' documentation.") } } diff --git a/test/groovy/com/sap/piper/TemporaryCredentialsUtilsTest.groovy b/test/groovy/com/sap/piper/TemporaryCredentialsUtilsTest.groovy index d8b41d7b8..e3780f9d7 100644 --- a/test/groovy/com/sap/piper/TemporaryCredentialsUtilsTest.groovy +++ b/test/groovy/com/sap/piper/TemporaryCredentialsUtilsTest.groovy @@ -100,7 +100,7 @@ class TemporaryCredentialsUtilsTest extends BasePiperTest { thrown.expect(hudson.AbortException) thrown.expectMessage("None of the directories [./, integration-tests/src/test/resources/] contains any of the files systems.yml, systems.yaml or systems.json. " + "One of those files is required in order to activate the integration test credentials configured in the pipeline configuration file of this project. " + - "Please add the file as explained in the SAP Cloud SDK documentation.") + "Please add the file as explained in project 'Piper' documentation.") credUtils.writeCredentials([credential], directories, filename ) } diff --git a/test/groovy/templates/PiperPipelineStageInitTest.groovy b/test/groovy/templates/PiperPipelineStageInitTest.groovy index 0948486d5..a6e7c7c2b 100644 --- a/test/groovy/templates/PiperPipelineStageInitTest.groovy +++ b/test/groovy/templates/PiperPipelineStageInitTest.groovy @@ -228,25 +228,4 @@ class PiperPipelineStageInitTest extends BasePiperTest { assertThat(stepParams.setupCommonPipelineEnvironment?.customDefaultsFromFiles, is(['my-custom-default-file.yml'])) } - @Test - void testInitWithCloudSdkStashInit() { - jsr.step.piperPipelineStageInit(script: nullScript, juStabUtils: utils, initCloudSdkStashSettings: true, buildTool: 'maven') - - assertThat(nullScript.commonPipelineEnvironment.configuration.stageStashes, hasKey('init')) - } - - @Test - void testLegacyConfigSettings() { - boolean checkForLegacyConfigurationCalled = false - helper.registerAllowedMethod('checkForLegacyConfiguration', [Map.class], { - checkForLegacyConfigurationCalled = true - }) - nullScript.commonPipelineEnvironment.configuration = [ - general: [legacyConfigSettings: 'com.sap.piper/pipeline/cloudSdkLegacyConfigSettings.yml'] - ] - - jsr.step.piperPipelineStageInit(script: nullScript, juStabUtils: utils, buildTool: 'maven') - - assertTrue(checkForLegacyConfigurationCalled) - } } diff --git a/vars/piperPipelineStageInit.groovy b/vars/piperPipelineStageInit.groovy index 1b88ab12c..859fb1f8a 100644 --- a/vars/piperPipelineStageInit.groovy +++ b/vars/piperPipelineStageInit.groovy @@ -30,11 +30,6 @@ import static com.sap.piper.Prerequisites.checkScript * Enables automatic inference from the build descriptor in case projectName is not configured. */ 'inferProjectName', - /** - * Toggle for initialization of the stash settings for Cloud SDK Pipeline. - * If this is set to true, the stashSettings parameter is **not** configurable. - */ - 'initCloudSdkStashSettings', /** * Defines the library resource containing the legacy configuration definition. */ @@ -144,25 +139,7 @@ void call(Map parameters = [:]) { ContainerMap.instance.initFromResource(script, config.containerMapResource, buildTool) } - //perform stashing based on library resource piper-stash-settings.yml if not configured otherwise or Cloud SDK Pipeline is initialized - if (config.initCloudSdkStashSettings) { - switch (buildTool) { - case 'maven': - initStashConfiguration(script, "com.sap.piper/pipeline/cloudSdkJavaStashSettings.yml", config.verbose?: false) - break - case 'npm': - initStashConfiguration(script, "com.sap.piper/pipeline/cloudSdkJavascriptStashSettings.yml", config.verbose?: false) - break - case 'mta': - initStashConfiguration(script, "com.sap.piper/pipeline/cloudSdkMtaStashSettings.yml", config.verbose?: false) - break - default: - error "[${STEP_NAME}] No stash settings for build tool ${buildTool} can be found. With `initCloudSdkStashSettings` active, only Maven, MTA or NPM projects are supported." - break - } - } else { - initStashConfiguration(script, config.stashSettings, config.verbose?: false) - } + initStashConfiguration(script, config.stashSettings, config.verbose?: false) if (config.verbose) { echo "piper-lib-os configuration: ${script.commonPipelineEnvironment.configuration}" diff --git a/vars/piperPipelineStageMavenStaticCodeChecks.groovy b/vars/piperPipelineStageMavenStaticCodeChecks.groovy index 769f29413..504667286 100644 --- a/vars/piperPipelineStageMavenStaticCodeChecks.groovy +++ b/vars/piperPipelineStageMavenStaticCodeChecks.groovy @@ -19,7 +19,7 @@ import groovy.transform.Field @Field Set PARAMETER_KEYS = STEP_CONFIG_KEYS /** - * Execute static code checks for Maven based projects. This stage enforces SAP Cloud SDK specific PMD rulesets as well as SpotBugs include filter. + * Execute static code checks for Maven based projects. * */ @GenerateDocumentation