mirror of
https://github.com/SAP/jenkins-library.git
synced 2025-01-18 05:18:24 +02:00
Merge pull request #22 from marcusholl/pr/fixQuotationInsideNeoDeploy
fix quotation inside neo deploy
This commit is contained in:
commit
1245528cfa
@ -60,7 +60,7 @@ class NeoDeploymentTest extends PiperTestBase {
|
||||
|
||||
withPipeline(defaultPipeline()).execute(archivePath, 'myCredentialsId')
|
||||
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash \/opt\/neo\/tools\/neo\.sh deploy-mta --user anonymous --host test\.deploy\.host\.com --source ".*" --account trialuser123 --password \*\*\*\*\*\*\*\* --synchronous/
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash "\/opt\/neo\/tools\/neo\.sh" deploy-mta --user 'anonymous' --host 'test\.deploy\.host\.com' --source ".*" --account 'trialuser123' --password '\*\*\*\*\*\*\*\*' --synchronous/
|
||||
|
||||
assert messages[1] == "[neoDeploy] Neo executable \"/opt/neo/tools/neo.sh\" retrieved from environment."
|
||||
|
||||
@ -90,7 +90,7 @@ class NeoDeploymentTest extends PiperTestBase {
|
||||
|
||||
withPipeline(noCredentialsIdPipeline()).execute(archivePath)
|
||||
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash \/opt\/neo\/tools\/neo\.sh deploy-mta --user defaultUser --host test\.deploy\.host\.com --source ".*" --account trialuser123 --password \*\*\*\*\*\*\*\* --synchronous/
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash "\/opt\/neo\/tools\/neo\.sh" deploy-mta --user 'defaultUser' --host 'test\.deploy\.host\.com' --source ".*" --account 'trialuser123' --password '\*\*\*\*\*\*\*\*' --synchronous/
|
||||
|
||||
assert messages[1] == "[neoDeploy] Neo executable \"/opt/neo/tools/neo.sh\" retrieved from environment."
|
||||
}
|
||||
@ -103,7 +103,7 @@ class NeoDeploymentTest extends PiperTestBase {
|
||||
|
||||
withPipeline(noCredentialsIdPipeline()).execute(archivePath)
|
||||
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash neo deploy-mta --user defaultUser --host test\.deploy\.host\.com --source ".*" --account trialuser123 --password \*\*\*\*\*\*\*\* --synchronous/
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash "neo" deploy-mta --user 'defaultUser' --host 'test\.deploy\.host\.com' --source ".*" --account 'trialuser123' --password '\*\*\*\*\*\*\*\*' --synchronous/
|
||||
|
||||
assert messages[1] == "Using Neo executable from PATH."
|
||||
}
|
||||
@ -116,7 +116,7 @@ class NeoDeploymentTest extends PiperTestBase {
|
||||
|
||||
withPipeline(neoHomeParameterPipeline()).execute(archivePath, 'myCredentialsId')
|
||||
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash \/etc\/neo\/tools\/neo\.sh deploy-mta --user anonymous --host test\.deploy\.host\.com --source ".*" --account trialuser123 --password \*\*\*\*\*\*\*\* --synchronous/
|
||||
assert shellCalls[0] =~ /#!\/bin\/bash "\/etc\/neo\/tools\/neo\.sh" deploy-mta --user 'anonymous' --host 'test\.deploy\.host\.com' --source ".*" --account 'trialuser123' --password '\*\*\*\*\*\*\*\*' --synchronous.*/
|
||||
|
||||
assert messages[1] == "[neoDeploy] Neo executable \"/etc/neo/tools/neo.sh\" retrieved from parameters."
|
||||
|
||||
|
@ -45,12 +45,12 @@ def call(parameters = [:]) {
|
||||
usernameVariable: 'username'
|
||||
)]) {
|
||||
sh """#!/bin/bash
|
||||
${neoExecutable} deploy-mta \
|
||||
--user ${username} \
|
||||
--host ${deployHost} \
|
||||
"${neoExecutable}" deploy-mta \
|
||||
--user '${username}' \
|
||||
--host '${deployHost}' \
|
||||
--source "${archivePath.getAbsolutePath()}" \
|
||||
--account ${deployAccount} \
|
||||
--password ${password} \
|
||||
--account '${deployAccount}' \
|
||||
--password '${password}' \
|
||||
--synchronous
|
||||
"""
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user