1
0
mirror of https://github.com/SAP/jenkins-library.git synced 2024-12-14 11:03:09 +02:00
Commit Graph

2564 Commits

Author SHA1 Message Date
Stephan Aßmus
e51cfe276c
Fix copy-paste-bug for downloading settings (#1284)
* Fix copy-paste-bug for downloading settings
* Extend unit tests accordingly.
* Fix some expected versus actual mixup
2020-03-17 08:33:35 +01:00
Oliver Nocon
a0223a2a0e
Fix issue with deployment related stashing in piperPipeline (#1281)
relates to #1267
2020-03-16 12:52:58 +01:00
Christopher Fenner
5b344b8b7a
use sonar-scanner 4.3.0.2102 (#1271) 2020-03-16 10:40:38 +01:00
Christopher Fenner
a970507619
refactor(sonar): provide trust store via JVM parameter (#1270)
* provide trust store via JVM parameter

* adjust test cases

* Update vars/sonarExecuteScan.groovy

* Update vars/sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy
2020-03-16 10:34:07 +01:00
Marcus Holl
db8cb2bf62
Add missing config for tmpUpload (#1277) 2020-03-16 09:34:59 +01:00
Stephan Aßmus
e0c789a791
Add Evaluate() method to maven package (#1268)
Useful for evaluating properties from pom files using the Maven evaluate plugin.
2020-03-13 14:54:49 +01:00
Daniel Kurzynski
a923e4cfc2
Add maven build/install step (#1245) 2020-03-13 13:32:37 +01:00
Florian Geckeler
9a28e12d5d
Add groovy wrapper for mavenExecuteStaticCodeChecks and rename go step 2020-03-12 15:45:57 +01:00
Christopher Fenner
dd67be3d21
docs(command): Clarify runExecutable Env usage (#1264)
* Clarify runExecutable Env usage

* remove trailing spaces
2020-03-12 09:00:51 +01:00
Florian Wilhelm
4e9b7f6cbf
Release go-binary via piper action (#1243) 2020-03-11 16:58:56 +01:00
Christopher Fenner
922a1796e0
fix(mta): add os.Environ() only once to command (#1260)
* add os.Environ() only once

* correct imports
2020-03-11 15:15:00 +01:00
Maximilian Lenkeit
2021c8215a
Expose seleniumHubCredentialsId to higher-level Jenkins steps (#1265)
* expose seleniumHubCredentialsId in karmaExecuteTests

* expose seleniumHubCredentialsId in uiVeri5ExecuteTests

* refer to documentation of seleniumExecuteTests
2020-03-11 13:35:49 +01:00
Sven Merk
c645087517
NotSerializableException next part (#1262)
* Update dockerExecute.groovy

* Update dockerExecute.groovy

* Update dockerExecute.groovy
2020-03-11 10:05:03 +01:00
Kaj-Sören Mossdorf
4aeb9517a6
Fix writeToDisk in case value is instance of List (#1249)
* Added documentation of stepParameters being a Groovy map, requiring at least the script reference

* Fix writeToDisk in case value is instance of List

* Fix writeToDisk in case value is instance of List

* Added comments

* Keep String as is, serialize everything else

* Fixed import

Co-authored-by: Sven Merk <33895725+nevskrem@users.noreply.github.com>
2020-03-11 08:18:27 +01:00
Florian Geckeler
ed7f4831fb
Fix typo in mavenStaticCodeChecks.yaml 2020-03-10 09:59:22 +01:00
Florian Wilhelm
fdb9fd3c6e
Print "Status" in error case in http client (#1256)
This might provide useful context to the user.

For example when you try to upload a SNAPSHOT jar to a maven-release
repo in nexus, this will print an error like

returned with response 400 Repository version policy: RELEASE does
not allow version: 1.0-SNAPSHOT

instead of

returned with HTTP Code 400
2020-03-09 19:25:40 +01:00
Sven Merk
6edaaecf15
Support workspace paths containing whitespaces (#1241)
* Support workspace paths containing whitespaces

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy

* Switch to export

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy

* Update sonarExecuteScan.groovy
2020-03-09 15:40:59 +01:00
Florian Geckeler
de2909e64b
Add Maven static code checks
* add static code checks for maven based projects as:
  * pmd plugin
  * spotBugs plugin
* test modules as unit-tests and integration-tests will be ignored by default. Additional modules to ignore are configurable
* for pmd: rulesets and excludes are configurable
* for spotBugs: includeFilter and excludeFilter are configurable
2020-03-09 08:58:59 +01:00
Stephan Aßmus
84f3e10e3b
Implementation of Nexus upload as Go package (#1250)
The nexus package implements uploading artifacts to a Nexus repository manager version 2 or 3 via HTTP. It also generates the MD5 and SHA1 hash files for the uploaded artifacts in the Nexus repository.
2020-03-06 23:10:10 +01:00
Sven Merk
b43f331fad
Avoid NotSerializableException #3 (#1252) 2020-03-06 14:05:14 +01:00
Oliver Nocon
dd5cfcc1aa
Added documentation of stepParameters being a Groovy map, requiring at least the script reference (#1248)
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2020-03-05 17:16:53 +01:00
Sven Merk
d29c249e35
Avoid using Iterators to get around NotSerializableException (#1242)
* Avoid using Iterators to get around NotSerializableException

* Avoid using Iterators to get around NotSerializableException
2020-03-05 15:48:05 +01:00
Oliver Nocon
622d559eae
Add ServiceKey deletion to cloudFoundryDeleteService step (#1177) 2020-03-05 15:35:43 +01:00
Christopher Fenner
0b3b4aae3d
chore: streamline GH actions (#1246)
* chore: streamline GH actions

* force use of local piper

* look for piper in project root

* use local piper

* Update .github/workflows/verify-go.yml

* remove chmod
2020-03-05 13:35:35 +01:00
Sven Merk
507bf3f98d
Update handlePipelineStepErrors.md (#1247) 2020-03-05 10:19:02 +01:00
Oliver Feldmann
5eb8edd3d9
Fix tip in documentation (#1196)
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
2020-03-04 17:01:49 +01:00
Florian Wilhelm
15ef9adaaa
Build piper binary in Consumer Tests (#1240) 2020-03-04 13:27:27 +01:00
Christopher Fenner
2b2b57305e
fix: handle NPE in seleniumExecuteTests (#1239)
* handle NPE

* fix Code Climate issue

* add test case

Co-Authored-By: Maximilian Lenkeit <mlenkeit@users.noreply.github.com>

* correct test case

Co-authored-by: Maximilian Lenkeit <mlenkeit@users.noreply.github.com>
2020-03-03 17:09:09 +01:00
Marcus Holl
d3820cb1f7
Have strategy for environment variable handling only once (#1234)
Have strategy for environment variable handling only once

And provide also a test checking if the environment variables
are present in the forked process.

The strategy applied for setting the environment variables is now
different from what it was before. Before the environment was
fully replaced by the new environment variables. Now we append
our environment variables to the list of environment variables available
by default for the forked process.



Co-authored-by: Florian Geckeler <43751896+fgeckeler@users.noreply.github.com>
2020-03-03 11:15:24 +01:00
Marcus Holl
2918ee52cc
Eliminte envMockRunner (#1233)
ExecMockRunner and ShellMockRunner both needs an environment. "Extending"
here leads to "subclasses" for both cases. That is more long-winded since
it could be.
2020-03-03 10:26:34 +01:00
Marcus Holl
52b0991a36
Get rid of two dimensional env array (#1235)
I don't understand why there should be a two dimensional array.
When dealing with envs we have normally a list containing entries like

[]string{"DEBUG=true", "HOME=/home/me"}

Having two dimensional env arrays would mean to have several alternate
environment in the tests at the same time. Don't think there is a need
for that.
2020-03-03 09:26:32 +01:00
Florian Geckeler
d32e6402b0
Add GetTestModulesExcludes to pkg/maven (#1237) 2020-03-02 17:04:49 +01:00
Florian Geckeler
783d955654
Add mavenExecute to go lib 2020-02-28 13:09:46 +01:00
Marcus Holl
95a1a4d928
xsDeploy: simplifiy assertions in tests (#1211) 2020-02-28 11:20:17 +01:00
Marcus Holl
e10a7f20c7
xs deploy cpe inputs and outputs (#1111)
Use inputs and outputs from commonPipelineEnvironment

* mtaPath is read as input
* operationId is provided as output and read as input
2020-02-28 11:01:09 +01:00
Marcus Holl
161e0b5d3b
xsDeploy: check for operationId in go layer and return error in case it is missing (#1109) 2020-02-28 09:40:22 +01:00
Christoph Szymanski
b4de8f2950
Fix documentation for XSA (#1189)
Co-authored-by: SarahNoack <44202907+SarahNoack@users.noreply.github.com>
Co-authored-by: Marcus Holl <marcus.holl@sap.com>
2020-02-28 09:08:56 +01:00
Florian Geckeler
9dc352029a
Add tag release when building go binary 2020-02-27 15:01:37 +01:00
Florian Wilhelm
1a3275b70d
Use piper exe in CWD for integration tests if available (#1231)
This change allows a development workflow where you don't need to set the `PIPER_INTEGRATION_EXECUTABLE` variable if your executable is available in the CWD. This should make it non-required to set the variable for most cases of local development.
2020-02-27 12:43:38 +01:00
Florian Geckeler
ef330e1eee
Move mock capabilities to pkg/mock/runner and adapt all tests 2020-02-27 12:11:22 +01:00
Daniel Kurzynski
c87c72ca7b
Document new sdk config location (#1228) 2020-02-27 10:36:04 +01:00
Christopher Fenner
3794371be3
fix typo (#1224)
Co-authored-by: Marcus Holl <marcus.holl@sap.com>
2020-02-26 16:21:40 +01:00
Florian Geckeler
bef0dfc3ea
Add revive config for proper linting
* Add revive config for proper linting

* Turn off rule for exported functions and structs need comments
2020-02-26 09:44:18 +01:00
Stephan Aßmus
2014a8b4ae
Utils.evaluateFromMavenPom(): Handle errors (#1192)
Handle error to evaluate by throwing an exception
2020-02-25 21:02:04 +01:00
Marcus Holl
4835fbffab
Support nested folders when performing a http download into a file (#1206) 2020-02-25 16:52:12 +01:00
Marcus Holl
190a4708a2
go: mta build (#1128)
move mtaBuild step from groovy to go.

Co-authored-by: Stephan Aßmus <stephan.assmus@sap.com>
2020-02-25 14:33:34 +01:00
Marcus Holl
d1e5d9c2e7
Settings file handling (prepares mtaBuild step) (#1176)
download settings file via http or copy from the local file system into either $M2_HOME/conf/settings.xml or into ~/.m2/settings.xml

Co-authored-by: Stephan Aßmus <stephan.assmus@sap.com>
2020-02-25 14:17:00 +01:00
Florian Geckeler
cd909d410a
Add exclude patterns to codeclimate 2020-02-25 13:42:47 +01:00
Sven Merk
4c97231ff9
Avoid using Iterators to get around NotSerializableException (#1220) 2020-02-25 12:25:26 +01:00
René Kschamer
d754a669b2
Add Docker deploy support to cloudFoundryDeploy (#977)
Co-authored-by: Oliver Nocon <33484802+OliverNocon@users.noreply.github.com>
Co-authored-by: Daniel Kurzynski <daniel.kurzynski@sap.com>
2020-02-25 10:20:15 +01:00