Code Review
/
cps.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Replace event-id with correlation-id for data read operation cloud event
[cps.git]
/
cps-ncmp-service
/
src
/
test
/
groovy
/
org
/
onap
/
cps
/
ncmp
/
api
/
impl
/
async
/
SerializationIntegrationSpec.groovy
diff --git
a/cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/async/SerializationIntegrationSpec.groovy
b/cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/async/SerializationIntegrationSpec.groovy
index
14ecd92
..
f24ff62
100644
(file)
--- a/
cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/async/SerializationIntegrationSpec.groovy
+++ b/
cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/async/SerializationIntegrationSpec.groovy
@@
-68,7
+68,7
@@
class SerializationIntegrationSpec extends ConsumerBaseSpec {
and: 'wait a little for async processing of message'
TimeUnit.MILLISECONDS.sleep(300)
then: 'the event has been forwarded'
and: 'wait a little for async processing of message'
TimeUnit.MILLISECONDS.sleep(300)
then: 'the event has been forwarded'
- 1 * mockEventsPublisher.publishCloudEvent('some client topic', '
my-event
-id', _) >> { args -> { capturedForwardedEvent = args[2] } }
+ 1 * mockEventsPublisher.publishCloudEvent('some client topic', '
some-correlation
-id', _) >> { args -> { capturedForwardedEvent = args[2] } }
and: 'the forwarded event is identical to the event that was sent'
assert capturedForwardedEvent == cloudEvent
}
and: 'the forwarded event is identical to the event that was sent'
assert capturedForwardedEvent == cloudEvent
}
@@
-94,6
+94,7
@@
class SerializationIntegrationSpec extends ConsumerBaseSpec {
.withType('DataOperationEvent')
.withSource(URI.create('some-source'))
.withExtension('destination','some client topic')
.withType('DataOperationEvent')
.withSource(URI.create('some-source'))
.withExtension('destination','some client topic')
+ .withExtension('correlationid','some-correlation-id')
.withData(objectMapper.writeValueAsBytes(dataOperationEvent))
.build()
}
.withData(objectMapper.writeValueAsBytes(dataOperationEvent))
.build()
}