aboutsummaryrefslogtreecommitdiffstats
path: root/cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest
diff options
context:
space:
mode:
authoremaclee <lee.anjella.macabuhay@est.tech>2022-07-01 16:42:27 +0100
committeremaclee <lee.anjella.macabuhay@est.tech>2022-07-01 16:42:27 +0100
commitea7206c10a8f7e3ad56d4e59e13c7b170841ae0d (patch)
tree31e673dd20239f21142dc560ab105f471bf55bbd /cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest
parent7914c8924723092345e8b4d829f15d2a3a5c72c8 (diff)
Modify Unit test for module definition
Issue-ID: CPS-1064 Signed-off-by: emaclee <lee.anjella.macabuhay@est.tech> Change-Id: I9f17d95ba6fb2c7be5a10b1612bcc8db69f8a64d
Diffstat (limited to 'cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest')
-rw-r--r--cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest/controller/NetworkCmProxyControllerSpec.groovy6
1 files changed, 3 insertions, 3 deletions
diff --git a/cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest/controller/NetworkCmProxyControllerSpec.groovy b/cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest/controller/NetworkCmProxyControllerSpec.groovy
index 729df9ce4..2cb397ded 100644
--- a/cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest/controller/NetworkCmProxyControllerSpec.groovy
+++ b/cps-ncmp-rest/src/test/groovy/org/onap/cps/ncmp/rest/controller/NetworkCmProxyControllerSpec.groovy
@@ -416,9 +416,9 @@ class NetworkCmProxyControllerSpec extends Specification {
then: 'ncmp service method to get module definitions is called'
mockNetworkCmProxyDataService.getModuleDefinitionsByCmHandleId('some-cmhandle')
>> [new ModuleDefinition('sampleModuleName', '2021-10-03',
- String.format('module sampleModuleName{ %n sample module content %n }'))]
- and: 'response contains an array with the module name, revision and content where content contains \\n for newlines'
- response.getContentAsString() == '[{"moduleName":"sampleModuleName","revision":"2021-10-03","content":"module sampleModuleName{ \\n sample module content \\n }"}]'
+ 'module sampleModuleName{ sample module content }')]
+ and: 'response contains an array with the module name, revision and content'
+ response.getContentAsString() == '[{"moduleName":"sampleModuleName","revision":"2021-10-03","content":"module sampleModuleName{ sample module content }"}]'
and: 'response returns an OK http code'
response.status == HttpStatus.OK.value()
}