mirror of
https://github.com/SAP/jenkins-library.git
synced 2025-03-31 22:05:11 +02:00
Clarify: transportRequestId can only be provided via signature (#1378)
Clarify: transportRequestId can only be provided via signature
This commit is contained in:
parent
bed3ec1e28
commit
93cac1a2f4
@ -72,7 +72,7 @@ public class TransportRequestCreateTest extends BasePiperTest {
|
|||||||
public void changeIdNotProvidedSOLANTest() {
|
public void changeIdNotProvidedSOLANTest() {
|
||||||
|
|
||||||
thrown.expect(IllegalArgumentException)
|
thrown.expect(IllegalArgumentException)
|
||||||
thrown.expectMessage("Change document id not provided (parameter: 'changeDocumentId' or via commit history).")
|
thrown.expectMessage("Change document id not provided (parameter: 'changeDocumentId' provided to the step call or via commit history).")
|
||||||
ChangeManagement cm = new ChangeManagement(nullScript) {
|
ChangeManagement cm = new ChangeManagement(nullScript) {
|
||||||
String getChangeDocumentId(
|
String getChangeDocumentId(
|
||||||
String from,
|
String from,
|
||||||
|
@ -73,7 +73,7 @@ public class TransportRequestReleaseTest extends BasePiperTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
thrown.expect(IllegalArgumentException)
|
thrown.expect(IllegalArgumentException)
|
||||||
thrown.expectMessage("Change document id not provided (parameter: 'changeDocumentId' or via commit history).")
|
thrown.expectMessage("Change document id not provided (parameter: 'changeDocumentId' provided to the step call or via commit history).")
|
||||||
|
|
||||||
stepRule.step.transportRequestRelease(script: nullScript, transportRequestId: '001', cmUtils: cm)
|
stepRule.step.transportRequestRelease(script: nullScript, transportRequestId: '001', cmUtils: cm)
|
||||||
}
|
}
|
||||||
@ -91,7 +91,7 @@ public class TransportRequestReleaseTest extends BasePiperTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
thrown.expect(IllegalArgumentException)
|
thrown.expect(IllegalArgumentException)
|
||||||
thrown.expectMessage("Transport request id not provided (parameter: 'transportRequestId' or via commit history).")
|
thrown.expectMessage("Transport request id not provided (parameter: 'transportRequestId' provided to the step call or via commit history).")
|
||||||
|
|
||||||
stepRule.step.transportRequestRelease(script: nullScript, changeDocumentId: '001', cmUtils: cm)
|
stepRule.step.transportRequestRelease(script: nullScript, changeDocumentId: '001', cmUtils: cm)
|
||||||
}
|
}
|
||||||
|
@ -75,7 +75,7 @@ public class TransportRequestUploadFileTest extends BasePiperTest {
|
|||||||
// straight forward test case for CTS
|
// straight forward test case for CTS
|
||||||
|
|
||||||
thrown.expect(IllegalArgumentException)
|
thrown.expect(IllegalArgumentException)
|
||||||
thrown.expectMessage("Change document id not provided (parameter: 'changeDocumentId' or via commit history).")
|
thrown.expectMessage("Change document id not provided (parameter: 'changeDocumentId' provided to the step call or via commit history).")
|
||||||
|
|
||||||
ChangeManagement cm = new ChangeManagement(nullScript) {
|
ChangeManagement cm = new ChangeManagement(nullScript) {
|
||||||
String getChangeDocumentId(
|
String getChangeDocumentId(
|
||||||
@ -106,7 +106,7 @@ public class TransportRequestUploadFileTest extends BasePiperTest {
|
|||||||
}
|
}
|
||||||
|
|
||||||
thrown.expect(IllegalArgumentException)
|
thrown.expect(IllegalArgumentException)
|
||||||
thrown.expectMessage("Transport request id not provided (parameter: 'transportRequestId' or via commit history).")
|
thrown.expectMessage("Transport request id not provided (parameter: 'transportRequestId' provided to the step call or via commit history).")
|
||||||
|
|
||||||
stepRule.step.transportRequestUploadFile(script: nullScript, changeDocumentId: '001', applicationId: 'app', filePath: '/path', cmUtils: cm)
|
stepRule.step.transportRequestUploadFile(script: nullScript, changeDocumentId: '001', applicationId: 'app', filePath: '/path', cmUtils: cm)
|
||||||
}
|
}
|
||||||
|
@ -169,7 +169,7 @@ void call(Map parameters = [:]) {
|
|||||||
configHelper.mixin([changeDocumentId: changeDocumentId?.trim() ?: null], ['changeDocumentId'] as Set)
|
configHelper.mixin([changeDocumentId: changeDocumentId?.trim() ?: null], ['changeDocumentId'] as Set)
|
||||||
.withMandatoryProperty('developmentSystemId')
|
.withMandatoryProperty('developmentSystemId')
|
||||||
.withMandatoryProperty('changeDocumentId',
|
.withMandatoryProperty('changeDocumentId',
|
||||||
"Change document id not provided (parameter: \'changeDocumentId\' or via commit history).")
|
"Change document id not provided (parameter: \'changeDocumentId\' provided to the step call or via commit history).")
|
||||||
}
|
}
|
||||||
|
|
||||||
configuration = configHelper.use()
|
configuration = configHelper.use()
|
||||||
|
@ -124,14 +124,14 @@ void call(Map parameters = [:]) {
|
|||||||
|
|
||||||
configHelper.mixin([changeDocumentId: changeDocumentId?.trim() ?: null], ['changeDocumentId'] as Set)
|
configHelper.mixin([changeDocumentId: changeDocumentId?.trim() ?: null], ['changeDocumentId'] as Set)
|
||||||
.withMandatoryProperty('changeDocumentId',
|
.withMandatoryProperty('changeDocumentId',
|
||||||
"Change document id not provided (parameter: \'changeDocumentId\' or via commit history).")
|
"Change document id not provided (parameter: \'changeDocumentId\' provided to the step call or via commit history).")
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
configuration = configHelper
|
configuration = configHelper
|
||||||
.mixin([transportRequestId: transportRequestId?.trim() ?: null], ['transportRequestId'] as Set)
|
.mixin([transportRequestId: transportRequestId?.trim() ?: null], ['transportRequestId'] as Set)
|
||||||
.withMandatoryProperty('transportRequestId',
|
.withMandatoryProperty('transportRequestId',
|
||||||
"Transport request id not provided (parameter: \'transportRequestId\' or via commit history).")
|
"Transport request id not provided (parameter: \'transportRequestId\' provided to the step call or via commit history).")
|
||||||
.use()
|
.use()
|
||||||
|
|
||||||
def closingMessage = ["[INFO] Closing transport request '${configuration.transportRequestId}'"]
|
def closingMessage = ["[INFO] Closing transport request '${configuration.transportRequestId}'"]
|
||||||
|
@ -98,7 +98,9 @@ import static com.sap.piper.cm.StepHelpers.getBackendTypeAndLogInfoIfCMIntegrati
|
|||||||
@Field Set PARAMETER_KEYS = STEP_CONFIG_KEYS.plus([
|
@Field Set PARAMETER_KEYS = STEP_CONFIG_KEYS.plus([
|
||||||
/** @see transportRequestCreate */
|
/** @see transportRequestCreate */
|
||||||
'changeDocumentId',
|
'changeDocumentId',
|
||||||
/** The id of the transport request to upload the file.*/
|
/** The id of the transport request to upload the file. This parameter is only taken into account
|
||||||
|
* when provided via signature to the step.
|
||||||
|
*/
|
||||||
'transportRequestId'])
|
'transportRequestId'])
|
||||||
|
|
||||||
/** Uploads a file to a Transport Request. */
|
/** Uploads a file to a Transport Request. */
|
||||||
@ -175,11 +177,11 @@ void call(Map parameters = [:]) {
|
|||||||
if(backendType == BackendType.SOLMAN) {
|
if(backendType == BackendType.SOLMAN) {
|
||||||
configHelper
|
configHelper
|
||||||
.withMandatoryProperty('changeDocumentId',
|
.withMandatoryProperty('changeDocumentId',
|
||||||
"Change document id not provided (parameter: \'changeDocumentId\' or via commit history).")
|
"Change document id not provided (parameter: \'changeDocumentId\' provided to the step call or via commit history).")
|
||||||
}
|
}
|
||||||
configuration = configHelper
|
configuration = configHelper
|
||||||
.withMandatoryProperty('transportRequestId',
|
.withMandatoryProperty('transportRequestId',
|
||||||
"Transport request id not provided (parameter: \'transportRequestId\' or via commit history).")
|
"Transport request id not provided (parameter: \'transportRequestId\' provided to the step call or via commit history).")
|
||||||
.use()
|
.use()
|
||||||
|
|
||||||
def uploadingMessage = ['[INFO] Uploading file ' +
|
def uploadingMessage = ['[INFO] Uploading file ' +
|
||||||
|
Loading…
x
Reference in New Issue
Block a user