summaryrefslogtreecommitdiffstats
path: root/robot
diff options
context:
space:
mode:
authorpkaras <piotr.karas@nokia.com>2019-04-10 11:56:50 +0200
committerpkaras <piotr.karas@nokia.com>2019-04-18 07:50:55 +0200
commit2771fdaa953bbbd6780ddc1d00ed18845a3fa370 (patch)
tree1cf8034e9fc3c0f73ff790e44b1e5673e65b7ef7 /robot
parente12b626ab2141e59d74314dc24713b295dac9d53 (diff)
tests for bus controller
Change-Id: Ib21382bc74832c223d87bd193c030428b6a8b6e4 Issue-ID: DMAAP-1114 Signed-off-by: piotr.karas <piotr.karas@nokia.com>
Diffstat (limited to 'robot')
-rw-r--r--robot/assets/templates/web/index.html.template2
-rw-r--r--robot/resources/bc_interface.robot29
-rw-r--r--robot/testsuites/health-check.robot5
-rw-r--r--robot/testsuites/update_onap_page.robot1
4 files changed, 37 insertions, 0 deletions
diff --git a/robot/assets/templates/web/index.html.template b/robot/assets/templates/web/index.html.template
index 5bfa4f15..5e156c41 100644
--- a/robot/assets/templates/web/index.html.template
+++ b/robot/assets/templates/web/index.html.template
@@ -41,6 +41,7 @@ ${sdnc} sdnc
${openo} multi-service
${dcae_controller} dcae
${message_router} message-router
+${bus_controller} dmaap-bc
${clamp} clamp
${portal} ${prefix}-portal
@@ -89,6 +90,7 @@ GLOBAL_INJECTED_APPC_IP_ADDR = "${appc}"
GLOBAL_INJECTED_DCAE_IP_ADDR = "${dcae_controller}"
GLOBAL_INJECTED_SO_IP_ADDR = "${mso}"
GLOBAL_INJECTED_MR_IP_ADDR = "${message_router}"
+GLOBAL_INJECTED_BC_IP_ADDR = "${bus_controller}"
GLOBAL_INJECTED_POLICY_IP_ADDR = "${policy}"
GLOBAL_INJECTED_PORTAL_IP_ADDR = "${portal}"
GLOBAL_INJECTED_SDC_IP_ADDR = "${sdc}"
diff --git a/robot/resources/bc_interface.robot b/robot/resources/bc_interface.robot
new file mode 100644
index 00000000..6aa2a3b9
--- /dev/null
+++ b/robot/resources/bc_interface.robot
@@ -0,0 +1,29 @@
+*** Settings ***
+Documentation The main interface for interacting with Bus Controller.
+Library RequestsClientCert
+Library RequestsLibrary
+Library UUID
+
+Resource global_properties.robot
+
+*** Variables ***
+${BC_HEALTH_CHECK_PATH} /webapi/dmaap
+${BC_HTTPS_ENDPOINT} https://${GLOBAL_INJECTED_BC_IP_ADDR}:${GLOBAL_BC_HTTPS_SERVER_PORT}
+
+
+*** Keywords ***
+Run BC Health Check With Basic Auth
+ [Documentation] Runs dmmap details check
+ ${resp}= Return dmaap details with basic auth ${BC_HEALTH_CHECK_PATH}
+ Should Be Equal As Strings ${resp.status_code} 200
+
+
+Return dmaap details with basic auth
+ [Documentation] Runs Bus Controler get details request with basic authentication
+ [Arguments] ${data_path}
+ ${auth}= Create List ${GLOBAL_BC_USERNAME} ${GLOBAL_BC_PASSWORD}
+ ${session}= Create Session bs ${BC_HTTPS_ENDPOINT} auth=${auth}
+ ${resp}= Get Request bs ${data_path}
+ Log Received response from bus controller ${resp.text}
+ [Return] ${resp}
+
diff --git a/robot/testsuites/health-check.robot b/robot/testsuites/health-check.robot
index 07d044c0..7f302294 100644
--- a/robot/testsuites/health-check.robot
+++ b/robot/testsuites/health-check.robot
@@ -13,6 +13,7 @@ Resource ../resources/asdc_interface.robot
Resource ../resources/appc_interface.robot
Resource ../resources/portal_interface.robot
Resource ../resources/mr_interface.robot
+Resource ../resources/bc_interface.robot
Resource ../resources/aaf_interface.robot
Resource ../resources/msb_interface.robot
Resource ../resources/clamp_interface.robot
@@ -72,6 +73,10 @@ Basic DMAAP Message Router PubSub Health Check
[Timeout] 30
Run MR PubSub Health Check
+Basic DMAAP Bus Controller Health Check With Basic Auth
+ [Tags] health core dev-dmaap
+ Run BC Health Check With Basic Auth
+
Basic External API NBI Health Check
[Tags] health externalapi api small
Run NBI Health Check
diff --git a/robot/testsuites/update_onap_page.robot b/robot/testsuites/update_onap_page.robot
index f8019397..2e14eb45 100644
--- a/robot/testsuites/update_onap_page.robot
+++ b/robot/testsuites/update_onap_page.robot
@@ -35,6 +35,7 @@ Update ONAP Page
Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_DCAE_IP_ADDR}=dcae_controller
Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_SO_IP_ADDR}=mso
Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_MR_IP_ADDR}=message_router
+ Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_BC_IP_ADDR}=bus_controller
Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_POLICY_IP_ADDR}=policy
Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_PORTAL_IP_ADDR}=portal
Set To Dictionary ${oam_ip_map} ${GLOBAL_INJECTED_SDC_IP_ADDR}=sdc