aboutsummaryrefslogtreecommitdiffstats
path: root/tests/dcaegen2/testcases/resources/DcaeLibrary.py
diff options
context:
space:
mode:
authorBartosz Gardziejewski <bartosz.gardziejewski@nokia.com>2020-07-29 11:13:36 +0200
committerBartosz Gardziejewski <bartosz.gardziejewski@nokia.com>2020-07-29 12:19:21 +0200
commita926d94469780de763da510c9cc01b768df2e444 (patch)
tree1f25b961784672c3f1f7ac71f2829743fcbc8e41 /tests/dcaegen2/testcases/resources/DcaeLibrary.py
parent7a51eafe2231b2719cb842e6407ce3178d617268 (diff)
Add topic validation for dcaegen2 VES tests
Issue-ID: DCAEGEN2-1771 Signed-off-by: Bartosz Gardziejewski <bartosz.gardziejewski@nokia.com> Change-Id: Ifb4f0f01ef3dcda366147d32c98a9be7890b6f56
Diffstat (limited to 'tests/dcaegen2/testcases/resources/DcaeLibrary.py')
-rw-r--r--tests/dcaegen2/testcases/resources/DcaeLibrary.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/dcaegen2/testcases/resources/DcaeLibrary.py b/tests/dcaegen2/testcases/resources/DcaeLibrary.py
index 6b96826c..a9d5def8 100644
--- a/tests/dcaegen2/testcases/resources/DcaeLibrary.py
+++ b/tests/dcaegen2/testcases/resources/DcaeLibrary.py
@@ -88,6 +88,18 @@ class DcaeLibrary(object):
return
@staticmethod
+ def dmaap_message_receive_on_topic(evtobj, topic):
+
+ evt_str = DMaaP.deque_event()
+ while evt_str != None:
+ if evtobj in evt_str and topic in evt_str:
+ logger.info("DMaaP Receive Expected Publish Event:\n" + evt_str)
+ logger.info("On Expected Topic:\n" + topic)
+ return 'true'
+ evt_str = DMaaP.deque_event()
+ return 'false'
+
+ @staticmethod
def dmaap_message_receive(evtobj, action='contain'):
evt_str = DMaaP.deque_event()