summaryrefslogtreecommitdiffstats
path: root/cps-ncmp-service/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'cps-ncmp-service/src/test')
-rw-r--r--cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/notifications/avc/AvcEventProducerIntegrationSpec.groovy6
-rw-r--r--cps-ncmp-service/src/test/resources/application.yml1
2 files changed, 5 insertions, 2 deletions
diff --git a/cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/notifications/avc/AvcEventProducerIntegrationSpec.groovy b/cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/notifications/avc/AvcEventProducerIntegrationSpec.groovy
index 744737080b..a251ecbf0b 100644
--- a/cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/notifications/avc/AvcEventProducerIntegrationSpec.groovy
+++ b/cps-ncmp-service/src/test/groovy/org/onap/cps/ncmp/api/impl/notifications/avc/AvcEventProducerIntegrationSpec.groovy
@@ -56,8 +56,10 @@ class AvcEventProducerIntegrationSpec extends MessagingBaseSpec {
def kafkaConsumer = new KafkaConsumer<>(consumerConfigProperties('ncmp-group'))
def 'Consume and forward valid message'() {
- given: 'consumer has a subscription'
- kafkaConsumer.subscribe(['cm-events'] as List<String>)
+ given: 'consumer has a subscription on a topic'
+ def cmEventsTopic = 'cm-events'
+ avcEventProducer.cmEventsTopic = cmEventsTopic
+ kafkaConsumer.subscribe([cmEventsTopic] as List<String>)
and: 'an event is sent'
def jsonData = TestUtils.getResourceFileContent('sampleAvcInputEvent.json')
def testEventSent = jsonObjectMapper.convertJsonString(jsonData, AvcEvent.class)
diff --git a/cps-ncmp-service/src/test/resources/application.yml b/cps-ncmp-service/src/test/resources/application.yml
index b7dfe86c10..e66f23d23f 100644
--- a/cps-ncmp-service/src/test/resources/application.yml
+++ b/cps-ncmp-service/src/test/resources/application.yml
@@ -20,6 +20,7 @@ app:
ncmp:
avc:
subscription-topic: cm-avc-subscription
+ cm-events-topic: cm-events
ncmp:
dmi: