mirror of
https://github.com/SAP/jenkins-library.git
synced 2024-12-14 11:03:09 +02:00
Add step test: transportRequestRelease for CTS fails
This commit is contained in:
parent
6f96f3d87b
commit
d8b0de3735
@ -89,7 +89,7 @@ public class TransportRequestReleaseTest extends BasePiperTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void releaseTransportRequestFailureTest() {
|
||||
public void releaseTransportRequestFailsSOLMANTest() {
|
||||
|
||||
thrown.expect(AbortException)
|
||||
thrown.expectMessage("Something went wrong")
|
||||
@ -110,6 +110,37 @@ public class TransportRequestReleaseTest extends BasePiperTest {
|
||||
stepRule.step.transportRequestRelease(script: nullScript, changeDocumentId: '001', transportRequestId: '001', cmUtils: cm)
|
||||
}
|
||||
|
||||
@Test
|
||||
public void releaseTransportRequestFailsCTSTest() {
|
||||
|
||||
thrown.expect(AbortException)
|
||||
thrown.expectMessage("Something went wrong")
|
||||
|
||||
nullScript
|
||||
.commonPipelineEnvironment
|
||||
.configuration
|
||||
.general
|
||||
.changeManagement
|
||||
.type = 'CTS'
|
||||
|
||||
ChangeManagement cm = new ChangeManagement(nullScript) {
|
||||
|
||||
void releaseTransportRequestCTS(
|
||||
String transportRequestId,
|
||||
String endpoint,
|
||||
String credentialsId,
|
||||
String clientOpts) {
|
||||
|
||||
throw new ChangeManagementException('Something went wrong')
|
||||
}
|
||||
}
|
||||
|
||||
stepRule.step.transportRequestRelease(
|
||||
script: nullScript,
|
||||
transportRequestId: '001',
|
||||
cmUtils: cm)
|
||||
}
|
||||
|
||||
@Test
|
||||
public void releaseTransportRequestSuccessRFCTest() {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user