aboutsummaryrefslogtreecommitdiffstats
path: root/test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py
diff options
context:
space:
mode:
authorFilip Krzywka <filip.krzywka@nokia.com>2018-08-06 10:07:03 +0200
committerFilip Krzywka <filip.krzywka@nokia.com>2018-08-31 07:47:38 +0200
commitd95a67029072015b75161aa180a72f242eda90ea (patch)
tree94a4f279ba5396bd6d08e05552262e471284f8a8 /test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py
parentf15077f640d033c1eb50d5496b27b6d6739d7e76 (diff)
Configure HV-VES suite containers
- populate consul with HV-VES configuration - make DCAE app simulator to consume messages from non-default kafka topic Change-Id: I13773476f271b533236c0888fa5d091a0ee46a23 Issue-ID: DCAEGEN2-687 Signed-off-by: Filip Krzywka <filip.krzywka@nokia.com>
Diffstat (limited to 'test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py')
-rw-r--r--test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py b/test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py
new file mode 100644
index 000000000..0d1d928b5
--- /dev/null
+++ b/test/csit/tests/dcaegen2-collectors-hv-ves/testcases/libraries/HttpRequests.py
@@ -0,0 +1,12 @@
+import requests
+from robot.api import logger
+
+def session_without_env():
+ session = requests.Session()
+ session.trust_env = False
+ return session
+
+def checkStatusCode(status_code, server_name):
+ if status_code != 200:
+ logger.error("Response status code from " + server_name + ": " + str(status_code))
+ raise (Exception(server_name + " returned status code " + status_code)) \ No newline at end of file