aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plans/dcaegen2/prh-testsuites/setup.sh18
-rw-r--r--plans/dcaegen2/prh-testsuites/teardown.sh3
-rw-r--r--tests/dcaegen2/prh-testcases/prh_config_tests.robot15
-rw-r--r--tests/dcaegen2/prh-testcases/prh_tests.robot2
-rw-r--r--tests/dcaegen2/prh-testcases/prh_tests_with_no_auth.robot2
-rw-r--r--tests/dcaegen2/prh-testcases/resources/consul.d/cbs.json10
-rw-r--r--tests/dcaegen2/prh-testcases/resources/docker-compose.yml47
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_config_library.robot44
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_configs/dcae-ves-collector-config.json54
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.json59
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.yaml48
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.json59
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.yaml48
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_library.robot8
-rw-r--r--tests/dcaegen2/prh-testcases/resources/prh_sessions.robot3
15 files changed, 136 insertions, 284 deletions
diff --git a/plans/dcaegen2/prh-testsuites/setup.sh b/plans/dcaegen2/prh-testsuites/setup.sh
index 9dc8de9a..bb8a8e95 100644
--- a/plans/dcaegen2/prh-testsuites/setup.sh
+++ b/plans/dcaegen2/prh-testsuites/setup.sh
@@ -5,12 +5,13 @@ source ${SCRIPTS}/common_functions.sh
export PRH_SERVICE="prh"
export DMAAP_SIMULATOR="dmaap_simulator"
export AAI_SIMULATOR="aai_simulator"
-export CONSUL="consul"
-export CONSUL_CONFIG="consul-cfg"
-export CBS="consul-cfg"
cd ${WORKSPACE}/tests/dcaegen2/prh-testcases/resources/
+#Prepare PRH config volume
+mkdir prh_configs/prh_config_volume
+cp prh_configs/prh-config.yaml prh_configs/prh_config_volume/application_config.yaml
+
pip uninstall -y docker-py
pip uninstall -y docker
pip install -U docker
@@ -24,26 +25,17 @@ docker-compose up -d --build
PRH_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${PRH_SERVICE})
DMAAP_SIMULATOR_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${DMAAP_SIMULATOR})
AAI_SIMULATOR_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${AAI_SIMULATOR})
-CONSUL_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${CONSUL})
-CONSUL_CONFIG_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${CONSUL_CONFIG})
-CBS_IP=$(docker inspect --format='{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' ${CBS})
bypass_ip_adress ${PRH_IP}
bypass_ip_adress ${DMAAP_SIMULATOR_IP}
bypass_ip_adress ${AAI_SIMULATOR_IP}
-bypass_ip_adress ${CONSUL_IP}
-bypass_ip_adress ${CONSUL_CONFIG_IP}
-bypass_ip_adress ${CBS_IP}
echo PRH_IP=${PRH_IP}
echo DMAAP_SIMULATOR_IP=${DMAAP_SIMULATOR_IP}
echo AAI_SIMULATOR_IP=${AAI_SIMULATOR_IP}
-echo CONSUL_IP=${CONSUL_IP}
-echo CONSUL_CONFIG_IP=${CONSUL_CONFIG_IP}
-echo CBS_IP=${CBS_IP}
# Wait for initialization of PRH services
wait_for_service_init localhost:8100/heartbeat
# #Pass any variables required by Robot test suites in ROBOT_VARIABLES
-ROBOT_VARIABLES="-v DMAAP_SIMULATOR_SETUP:${DMAAP_SIMULATOR_IP}:2224 -v AAI_SIMULATOR_SETUP:${AAI_SIMULATOR_IP}:3335 -v CONSUL_SETUP:${CONSUL_IP}:8500 -v PRH_SETUP:${PRH_IP}:8100" \ No newline at end of file
+ROBOT_VARIABLES="-v DMAAP_SIMULATOR_SETUP:${DMAAP_SIMULATOR_IP}:2224 -v AAI_SIMULATOR_SETUP:${AAI_SIMULATOR_IP}:3335 -v PRH_SETUP:${PRH_IP}:8100" \ No newline at end of file
diff --git a/plans/dcaegen2/prh-testsuites/teardown.sh b/plans/dcaegen2/prh-testsuites/teardown.sh
index 382b22eb..faad03a6 100644
--- a/plans/dcaegen2/prh-testsuites/teardown.sh
+++ b/plans/dcaegen2/prh-testsuites/teardown.sh
@@ -21,3 +21,6 @@ kill-instance.sh aai_simulator
kill-instance.sh consul
kill-instance.sh consul-cfg
kill-instance.sh cbs
+
+#Cleanup PRH config volume
+rm -rf ${WORKSPACE}/tests/dcaegen2/prh-testcases/resources/prh_configs/prh_config_volume \ No newline at end of file
diff --git a/tests/dcaegen2/prh-testcases/prh_config_tests.robot b/tests/dcaegen2/prh-testcases/prh_config_tests.robot
index 2a6b8154..e19f91ca 100644
--- a/tests/dcaegen2/prh-testcases/prh_config_tests.robot
+++ b/tests/dcaegen2/prh-testcases/prh_config_tests.robot
@@ -1,7 +1,6 @@
*** Settings ***
Documentation Tests related to updating PRH app config based on CBS config
-Suite Setup Create sessions
-Suite Teardown Set default PRH CBS config
+Suite Setup Run keywords Create sessions AND Set default PRH config
Resource resources/prh_sessions.robot
Resource resources/prh_config_library.robot
Resource resources/prh_library.robot
@@ -12,23 +11,23 @@ CBS configuration forced refresh
[Documentation] It should be possible to force refresh PRH configuration from CBS
[Tags] PRH coniguration
${some_random_value}= Generate random value
- Put key-value to consul foo_${some_random_value} bar_${some_random_value}
+ Put key-value to config foo_${some_random_value} bar_${some_random_value}
Force PRH config refresh
Check key-value in PRH app environment foo_${some_random_value} bar_${some_random_value}
CBS configuration scheduled refresh
[Documentation] PRH should pull for CBS configuration updates according to schedule
[Tags] PRH coniguration
- Set scheduled CBS updates interval 1s
+ Set scheduled config updates interval 1s
${some_random_value}= Generate random value
- Put key-value to consul spam_${some_random_value} ham_${some_random_value}
+ Put key-value to config spam_${some_random_value} ham_${some_random_value}
wait until keyword succeeds 20x 500ms
... Check key-value in PRH app environment spam_${some_random_value} ham_${some_random_value}
- [Teardown] Set scheduled CBS updates interval 0
+ [Teardown] Set scheduled config updates interval 0
PRH log level change based on CBS config
[Documentation] It should be possible to change logging levels in PRH based on entries in CBS
[Tags] PRH coniguration logging
- Set logging level in CBS org.onap.dcaegen2.services.prh.foo WARN
+ Set logging level in config org.onap.dcaegen2.services.prh.foo WARN
Force PRH config refresh
- Verify logging level org.onap.dcaegen2.services.prh.foo WARN \ No newline at end of file
+ Verify logging level org.onap.dcaegen2.services.prh.foo WARN
diff --git a/tests/dcaegen2/prh-testcases/prh_tests.robot b/tests/dcaegen2/prh-testcases/prh_tests.robot
index 17db590f..8b7561aa 100644
--- a/tests/dcaegen2/prh-testcases/prh_tests.robot
+++ b/tests/dcaegen2/prh-testcases/prh_tests.robot
@@ -1,7 +1,7 @@
*** Settings ***
Documentation Integration tests for PRH.
... PRH receive events from DMaaP and produce or not PNF_READY notification depends on required fields in received event.
-Suite Setup Run keywords Create Headers AND Create sessions AND Set default PRH CBS config
+Suite Setup Run keywords Create Headers AND Create sessions AND Set default PRH config
Test Teardown Reset Simulators
Test Timeout 2 minutes
diff --git a/tests/dcaegen2/prh-testcases/prh_tests_with_no_auth.robot b/tests/dcaegen2/prh-testcases/prh_tests_with_no_auth.robot
index afcd0f8a..6eddee9a 100644
--- a/tests/dcaegen2/prh-testcases/prh_tests_with_no_auth.robot
+++ b/tests/dcaegen2/prh-testcases/prh_tests_with_no_auth.robot
@@ -1,7 +1,7 @@
*** Settings ***
Documentation Integration tests for PRH when cert auth for dmaap and aai is disabled.
Suite Setup Run keywords Create Headers AND Create sessions AND
-... Set PRH CBS config from file ${CONFIGS_DIR}/prh-no-auth-config.json
+... Set PRH config from file ${CONFIGS_DIR}/prh-no-auth-config.yaml
Test Teardown Reset Simulators
Test Timeout 2 minutes
diff --git a/tests/dcaegen2/prh-testcases/resources/consul.d/cbs.json b/tests/dcaegen2/prh-testcases/resources/consul.d/cbs.json
deleted file mode 100644
index 9d1b34f9..00000000
--- a/tests/dcaegen2/prh-testcases/resources/consul.d/cbs.json
+++ /dev/null
@@ -1,10 +0,0 @@
-{
- "service": {
- "name": "cbs",
- "tags": [
- "cbs"
- ],
- "port": 10000,
- "address": "cbs"
- }
-}
diff --git a/tests/dcaegen2/prh-testcases/resources/docker-compose.yml b/tests/dcaegen2/prh-testcases/resources/docker-compose.yml
index 00a2af1d..bf50c7ab 100644
--- a/tests/dcaegen2/prh-testcases/resources/docker-compose.yml
+++ b/tests/dcaegen2/prh-testcases/resources/docker-compose.yml
@@ -7,6 +7,7 @@ services:
- "8433:8433"
volumes:
- ./simulator/certs:/tmp/certs
+ - ./prh_configs/prh_config_volume:/app-config
environment:
- HOSTNAME=dcae-prh
- CONSUL_HOST # not in use, but still required by SDK - should be removed later on
@@ -14,8 +15,6 @@ services:
- CONFIG_BINDING_SERVICE_SERVICE_PORT
container_name: prh
depends_on:
- cbs:
- condition: service_healthy
dmaap-mr:
condition: service_started
aai:
@@ -40,47 +39,3 @@ services:
- "3334:3334"
- "3335:3335"
container_name: aai_simulator
-
- consul:
- image: consul:1.0.6
- ports:
- - "8500:8500"
- command: ["agent", "-bootstrap", "-client=0.0.0.0", "-server", "-ui", "-config-dir=/consul/consul.d"]
- volumes:
- - ./consul.d/:/consul/consul.d
- container_name: consul
-
- consul-cfg:
- image: consul:1.0.6
- restart: on-failure
- command: ["kv", "put", "-http-addr=http://consul:8500", "dcae-prh", "@/prh_configs/prh-config.json"]
- container_name: consul-cfg
- volumes:
- - ./prh_configs/:/prh_configs:Z
- depends_on:
- - consul
-
- consul-cfg-dcae-ves-collector:
- image: consul:1.0.6
- restart: on-failure
- command: ["kv", "put", "-http-addr=http://consul:8500", "dcae-ves-collector", "@/prh_configs/dcae-ves-collector-config.json"]
- container_name: consul-cfg-dcae-ves-collector
- volumes:
- - ./prh_configs/:/prh_configs:Z
- depends_on:
- - consul
-
- cbs:
- image: nexus3.onap.org:10001/onap/org.onap.dcaegen2.platform.configbinding.app-app:2.2.4
- ports:
- - "10000:10000"
- environment:
- - CONSUL_HOST
- depends_on:
- - consul-cfg
- healthcheck:
- test: ["CMD", "curl", "-f", "http://localhost:10000/service_component_all/dcae-prh"]
- interval: 3s
- timeout: 2s
- retries: 20
- container_name: cbs
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_config_library.robot b/tests/dcaegen2/prh-testcases/resources/prh_config_library.robot
index 78b47824..1e7c69a9 100644
--- a/tests/dcaegen2/prh-testcases/resources/prh_config_library.robot
+++ b/tests/dcaegen2/prh-testcases/resources/prh_config_library.robot
@@ -3,38 +3,38 @@ Documentation Keywords related to checking and updating PRH app config based
Library RequestsLibrary
Library OperatingSystem
Library Collections
+Library yaml
*** Variables ***
${CONFIGS_DIR} %{WORKSPACE}/tests/dcaegen2/prh-testcases/resources/prh_configs/
-
+${PRH_CONFIG_FILE} ${CONFIGS_DIR}/prh_config_volume/application_config.yaml
*** Keywords ***
-Put key-value to consul
+Put key-value to config
[Arguments] ${key} ${value}
- ${prh_config}= Get PRH config from consul
+ ${prh_config}= Get PRH config
set to dictionary ${prh_config} ${key} ${value}
- Set PRH config in consul ${prh_config}
+ Set PRH config ${prh_config}
-Get PRH config from consul
- [Arguments] ${logMessage}=prh config in consul
- ${phr_config_response}= get request consul_session /v1/kv/dcae-prh?raw
- log ${logMessage}: ${phr_config_response.content}
- [Return] ${phr_config_response.json()}
+Get PRH config
+ [Arguments] ${logMessage}=prh config
+ ${prh_config_file_content}= Get File ${PRH_CONFIG_FILE}
+ ${prh_config}= yaml.Safe Load ${prh_config_file_content}
+ log ${logMessage}: ${prh_config}
+ [Return] ${prh_config}
-Set PRH config in consul
+Set PRH config
[Arguments] ${prh_config}
- put request consul_session /v1/kv/dcae-prh json=${prh_config}
- Get PRH config from consul prh config in consul after update
+ ${prh_config_output}= yaml.Safe Dump ${prh_config}
+ Create File ${PRH_CONFIG_FILE} ${prh_config_output}
-Set PRH CBS config from file
+Set PRH config from file
[Arguments] ${config_file_name}
- ${config_file_content}= get file ${config_file_name}
- ${config_json}= to json ${config_file_content}
- Set PRH config in consul ${config_json}
+ Copy File ${config_file_name} ${PRH_CONFIG_FILE}
Force PRH config refresh
-Set default PRH CBS config
- Set PRH CBS config from file ${CONFIGS_DIR}/prh-config.json
+Set default PRH config
+ Set PRH config from file ${CONFIGS_DIR}/prh-config.yaml
Force PRH config refresh
${refresh_response}= post request prh_session /actuator/refresh
@@ -47,14 +47,14 @@ Check key-value in PRH app environment
log ${env_response.content}
should be equal ${env_response.json()["property"]["value"]} ${expected_value}
-Set scheduled CBS updates interval
+Set scheduled config updates interval
[Arguments] ${cbs_updates_interval}
- Put key-value to consul cbs.updates-interval ${cbs_updates_interval}
+ Put key-value to config cbs.updates-interval ${cbs_updates_interval}
Force PRH config refresh
-Set logging level in CBS
+Set logging level in config
[Arguments] ${logger} ${level}
- Put key-value to consul logging.level.${logger} ${level}
+ Put key-value to config logging.level.${logger} ${level}
Generate random value
${some_random_value} evaluate random.randint(sys.maxint/10, sys.maxint) modules=random,sys
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_configs/dcae-ves-collector-config.json b/tests/dcaegen2/prh-testcases/resources/prh_configs/dcae-ves-collector-config.json
deleted file mode 100644
index d3be7acd..00000000
--- a/tests/dcaegen2/prh-testcases/resources/prh_configs/dcae-ves-collector-config.json
+++ /dev/null
@@ -1,54 +0,0 @@
-{
- "collector.dynamic.config.update.frequency": "5",
- "event.transform.flag": "0",
- "collector.schema.checkflag": "1",
- "collector.dmaap.streamid": "fault=ves-fault|syslog=ves-syslog|heartbeat=ves-heartbeat|measurementsForVfScaling=ves-measurement|mobileFlow=ves-mobileflow|other=ves-other|stateChange=ves-statechange|thresholdCrossingAlert=ves-thresholdCrossingAlert|voiceQuality=ves-voicequality|sipSignaling=ves-sipsignaling|notification=ves-notification|pnfRegistration=ves-pnfRegistration",
- "collector.service.port": "8080",
- "collector.schema.file": "{ \"v1\":\"./etc/CommonEventFormat_27.2.json\", \"v2\":\"./etc/CommonEventFormat_27.2.json\", \"v3\":\"./etc/CommonEventFormat_27.2.json\", \"v4\":\"./etc/CommonEventFormat_27.2.json\", \"v5\":\"./etc/CommonEventFormat_28.4.1.json\", \"v7\":\"./etc/CommonEventFormat_30.0.1.json\" }",
- "collector.keystore.passwordfile": "/opt/app/VESCollector/etc/passwordfile",
- "collector.inputQueue.maxPending": "8096",
- "streams_publishes": {
- "ves-measurement": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_MEASUREMENT_OUTPUT/"
- }
- },
- "ves-fault": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.SEC_FAULT_OUTPUT/"
- }
- },
- "ves-pnfRegistration": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_PNFREG_OUTPUT/"
- }
- },
- "ves-other": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.SEC_OTHER_OUTPUT/"
- }
- },
- "ves-heartbeat": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.SEC_HEARTBEAT_OUTPUT/"
- }
- },
- "ves-notification": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_NOTIFICATION_OUTPUT/"
- }
- }
- },
- "collector.service.secure.port": "8443",
- "header.authflag": "0",
- "collector.keystore.file.location": "/opt/app/VESCollector/etc/keystore",
- "collector.keystore.alias": "dynamically generated",
- "services_calls": [],
- "header.authlist": "sample1,c2FtcGxlMQ=="
-} \ No newline at end of file
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.json b/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.json
deleted file mode 100644
index 6a48e943..00000000
--- a/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.json
+++ /dev/null
@@ -1,59 +0,0 @@
-{
- "cbs.updates-interval": 0,
- "logging.level.org.onap.dcaegen2.services.prh": "debug",
- "logging.level.org.onap.dcaegen2.services.sdk": "debug",
- "logging.level.org.onap.dcaegen2.services.prh.controllers.AppInfoController": "off",
- "dmaap.dmaapConsumerConfiguration.dmaapUserName": "admin",
- "dmaap.dmaapConsumerConfiguration.dmaapUserPassword": "admin",
- "dmaap.dmaapConsumerConfiguration.dmaapContentType": "application/json",
- "dmaap.dmaapConsumerConfiguration.consumerId": "c12",
- "dmaap.dmaapConsumerConfiguration.consumerGroup": "OpenDCAE-c12",
- "dmaap.dmaapConsumerConfiguration.timeoutMs": -1,
- "dmaap.dmaapProducerConfiguration.dmaapUserName": "admin",
- "dmaap.dmaapProducerConfiguration.dmaapUserPassword": "admin",
- "dmaap.dmaapProducerConfiguration.dmaapContentType": "application/json",
- "dmaap.dmaapUpdateProducerConfiguration.dmaapUserName": "admin",
- "dmaap.dmaapUpdateProducerConfiguration.dmaapUserPassword": "admin",
- "dmaap.dmaapUpdateProducerConfiguration.dmaapContentType": "application/json",
- "aai.aaiClientConfiguration.pnfUrl": "https://aai:3334/aai/v23/network/pnfs/pnf",
- "aai.aaiClientConfiguration.baseUrl": "https://aai:3334/aai/v23",
- "aai.aaiClientConfiguration.aaiUserName": "DCAE",
- "aai.aaiClientConfiguration.aaiUserPassword": "DCAE",
- "aai.aaiClientConfiguration.aaiIgnoreSslCertificateErrors": true,
- "aai.aaiClientConfiguration.aaiServiceInstancePath": "/business/customers/customer/{{customer}}/service-subscriptions/service-subscription/{{serviceType}}/service-instances/service-instance/{{serviceInstanceId}}",
- "aai.aaiClientConfiguration.aaiHeaders": {
- "X-FromAppId": "prh",
- "X-TransactionId": "9999",
- "Accept": "application/json",
- "Real-Time": "true",
- "Authorization": "Basic QUFJOkFBSQ=="
- },
- "security.trustStorePath": "/tmp/certs/truststore.jks",
- "security.trustStorePasswordPath": "/tmp/certs/truststore.password",
- "security.keyStorePath": "/tmp/certs/keystore.p12",
- "security.keyStorePasswordPath": "/tmp/certs/keystore.password",
- "security.enableAaiCertAuth": true,
- "security.enableDmaapCertAuth": true,
- "streams_publishes": {
- "pnf-update": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "https://dmaap-mr:2223/events/unauthenticated.PNF_UPDATE"
- }
- },
- "pnf-ready": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "https://dmaap-mr:2223/events/unauthenticated.PNF_READY"
- }
- }
- },
- "streams_subscribes": {
- "ves-reg-output": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "https://dmaap-mr:2223/events/unauthenticated.VES_PNFREG_OUTPUT"
- }
- }
- }
-}
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.yaml b/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.yaml
new file mode 100644
index 00000000..43020542
--- /dev/null
+++ b/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-config.yaml
@@ -0,0 +1,48 @@
+cbs.updates-interval: 0
+logging.level.org.onap.dcaegen2.services.prh: "debug"
+logging.level.org.onap.dcaegen2.services.sdk: "debug"
+logging.level.org.onap.dcaegen2.services.prh.controllers.AppInfoController: "off"
+dmaap.dmaapConsumerConfiguration.dmaapUserName: "admin"
+dmaap.dmaapConsumerConfiguration.dmaapUserPassword: "admin"
+dmaap.dmaapConsumerConfiguration.dmaapContentType: "application/json"
+dmaap.dmaapConsumerConfiguration.consumerId: "c12"
+dmaap.dmaapConsumerConfiguration.consumerGroup: "OpenDCAE-c12"
+dmaap.dmaapConsumerConfiguration.timeoutMs: -1
+dmaap.dmaapProducerConfiguration.dmaapUserName: "admin"
+dmaap.dmaapProducerConfiguration.dmaapUserPassword: "admin"
+dmaap.dmaapProducerConfiguration.dmaapContentType: "application/json"
+dmaap.dmaapUpdateProducerConfiguration.dmaapUserName: "admin"
+dmaap.dmaapUpdateProducerConfiguration.dmaapUserPassword: "admin"
+dmaap.dmaapUpdateProducerConfiguration.dmaapContentType: "application/json"
+aai.aaiClientConfiguration.pnfUrl: "https://aai:3334/aai/v23/network/pnfs/pnf"
+aai.aaiClientConfiguration.baseUrl: "https://aai:3334/aai/v23"
+aai.aaiClientConfiguration.aaiUserName: "DCAE"
+aai.aaiClientConfiguration.aaiUserPassword: "DCAE"
+aai.aaiClientConfiguration.aaiIgnoreSslCertificateErrors: true
+aai.aaiClientConfiguration.aaiServiceInstancePath: "/business/customers/customer/{{customer}}/service-subscriptions/service-subscription/{{serviceType}}/service-instances/service-instance/{{serviceInstanceId}}"
+aai.aaiClientConfiguration.aaiHeaders:
+ X-FromAppId: "prh"
+ X-TransactionId: "9999"
+ Accept: "application/json"
+ Real-Time: "true"
+ Authorization: "Basic QUFJOkFBSQ=="
+security.trustStorePath: "/tmp/certs/truststore.jks"
+security.trustStorePasswordPath: "/tmp/certs/truststore.password"
+security.keyStorePath: "/tmp/certs/keystore.p12"
+security.keyStorePasswordPath: "/tmp/certs/keystore.password"
+security.enableAaiCertAuth: true
+security.enableDmaapCertAuth: true
+streams_publishes:
+ pnf-update:
+ type: "message_router"
+ dmaap_info:
+ topic_url: "https://dmaap-mr:2223/events/unauthenticated.PNF_UPDATE"
+ pnf-ready:
+ type: "message_router"
+ dmaap_info:
+ topic_url: "https://dmaap-mr:2223/events/unauthenticated.PNF_READY"
+streams_subscribes:
+ ves-reg-output:
+ type: "message_router"
+ dmaap_info:
+ topic_url: "https://dmaap-mr:2223/events/unauthenticated.VES_PNFREG_OUTPUT"
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.json b/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.json
deleted file mode 100644
index e4b88796..00000000
--- a/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.json
+++ /dev/null
@@ -1,59 +0,0 @@
-{
- "cbs.updates-interval": 0,
- "logging.level.org.onap.dcaegen2.services.prh": "debug",
- "logging.level.org.onap.dcaegen2.services.sdk": "debug",
- "logging.level.org.onap.dcaegen2.services.prh.controllers.AppInfoController": "off",
- "dmaap.dmaapConsumerConfiguration.dmaapUserName": "admin",
- "dmaap.dmaapConsumerConfiguration.dmaapUserPassword": "admin",
- "dmaap.dmaapConsumerConfiguration.dmaapContentType": "application/json",
- "dmaap.dmaapConsumerConfiguration.consumerId": "c12",
- "dmaap.dmaapConsumerConfiguration.consumerGroup": "OpenDCAE-c12",
- "dmaap.dmaapConsumerConfiguration.timeoutMs": -1,
- "dmaap.dmaapProducerConfiguration.dmaapUserName": "admin",
- "dmaap.dmaapProducerConfiguration.dmaapUserPassword": "admin",
- "dmaap.dmaapProducerConfiguration.dmaapContentType": "application/json",
- "dmaap.dmaapUpdateProducerConfiguration.dmaapUserName": "admin",
- "dmaap.dmaapUpdateProducerConfiguration.dmaapUserPassword": "admin",
- "dmaap.dmaapUpdateProducerConfiguration.dmaapContentType": "application/json",
- "aai.aaiClientConfiguration.pnfUrl": "http://aai:3333/aai/v23/network/pnfs/pnf",
- "aai.aaiClientConfiguration.baseUrl": "https://aai:3334/aai/v23",
- "aai.aaiClientConfiguration.aaiUserName": "DCAE",
- "aai.aaiClientConfiguration.aaiUserPassword": "DCAE",
- "aai.aaiClientConfiguration.aaiIgnoreSslCertificateErrors": true,
- "aai.aaiClientConfiguration.aaiServiceInstancePath": "/business/customers/customer/{{customer}}/service-subscriptions/service-subscription/{{serviceType}}/service-instances/service-instance/{{serviceInstanceId}}",
- "aai.aaiClientConfiguration.aaiHeaders": {
- "X-FromAppId": "prh",
- "X-TransactionId": "9999",
- "Accept": "application/json",
- "Real-Time": "true",
- "Authorization": "Basic QUFJOkFBSQ=="
- },
- "security.trustStorePath": "",
- "security.trustStorePasswordPath": "",
- "security.keyStorePath": "",
- "security.keyStorePasswordPath": "",
- "security.enableAaiCertAuth": false,
- "security.enableDmaapCertAuth": false,
- "streams_publishes": {
- "pnf-update": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.PNF_UPDATE"
- }
- },
- "pnf-ready": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.PNF_READY"
- }
- }
- },
- "streams_subscribes": {
- "ves-reg-output": {
- "type": "message_router",
- "dmaap_info": {
- "topic_url": "http://dmaap-mr:2222/events/unauthenticated.VES_PNFREG_OUTPUT"
- }
- }
- }
-}
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.yaml b/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.yaml
new file mode 100644
index 00000000..4ccdd9c5
--- /dev/null
+++ b/tests/dcaegen2/prh-testcases/resources/prh_configs/prh-no-auth-config.yaml
@@ -0,0 +1,48 @@
+cbs.updates-interval: 0
+logging.level.org.onap.dcaegen2.services.prh: "debug"
+logging.level.org.onap.dcaegen2.services.sdk: "debug"
+logging.level.org.onap.dcaegen2.services.prh.controllers.AppInfoController: "off"
+dmaap.dmaapConsumerConfiguration.dmaapUserName: "admin"
+dmaap.dmaapConsumerConfiguration.dmaapUserPassword: "admin"
+dmaap.dmaapConsumerConfiguration.dmaapContentType: "application/json"
+dmaap.dmaapConsumerConfiguration.consumerId: "c12"
+dmaap.dmaapConsumerConfiguration.consumerGroup: "OpenDCAE-c12"
+dmaap.dmaapConsumerConfiguration.timeoutMs: -1
+dmaap.dmaapProducerConfiguration.dmaapUserName: "admin"
+dmaap.dmaapProducerConfiguration.dmaapUserPassword: "admin"
+dmaap.dmaapProducerConfiguration.dmaapContentType: "application/json"
+dmaap.dmaapUpdateProducerConfiguration.dmaapUserName: "admin"
+dmaap.dmaapUpdateProducerConfiguration.dmaapUserPassword: "admin"
+dmaap.dmaapUpdateProducerConfiguration.dmaapContentType: "application/json"
+aai.aaiClientConfiguration.pnfUrl: "http://aai:3333/aai/v23/network/pnfs/pnf"
+aai.aaiClientConfiguration.baseUrl: "https://aai:3334/aai/v23"
+aai.aaiClientConfiguration.aaiUserName: "DCAE"
+aai.aaiClientConfiguration.aaiUserPassword: "DCAE"
+aai.aaiClientConfiguration.aaiIgnoreSslCertificateErrors: true
+aai.aaiClientConfiguration.aaiServiceInstancePath: "/business/customers/customer/{{customer}}/service-subscriptions/service-subscription/{{serviceType}}/service-instances/service-instance/{{serviceInstanceId}}"
+aai.aaiClientConfiguration.aaiHeaders:
+ X-FromAppId: "prh"
+ X-TransactionId: "9999"
+ Accept: "application/json"
+ Real-Time: "true"
+ Authorization: "Basic QUFJOkFBSQ=="
+security.trustStorePath: ""
+security.trustStorePasswordPath: ""
+security.keyStorePath: ""
+security.keyStorePasswordPath: ""
+security.enableAaiCertAuth: false
+security.enableDmaapCertAuth: false
+streams_publishes:
+ pnf-update:
+ type: "message_router"
+ dmaap_info:
+ topic_url: "http://dmaap-mr:2222/events/unauthenticated.PNF_UPDATE"
+ pnf-ready:
+ type: "message_router"
+ dmaap_info:
+ topic_url: "http://dmaap-mr:2222/events/unauthenticated.PNF_READY"
+streams_subscribes:
+ ves-reg-output:
+ type: "message_router"
+ dmaap_info:
+ topic_url: "http://dmaap-mr:2222/events/unauthenticated.VES_PNFREG_OUTPUT"
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_library.robot b/tests/dcaegen2/prh-testcases/resources/prh_library.robot
index e3a5c2e4..ff02d7f8 100644
--- a/tests/dcaegen2/prh-testcases/resources/prh_library.robot
+++ b/tests/dcaegen2/prh-testcases/resources/prh_library.robot
@@ -12,7 +12,6 @@ Verify PNF ready sent
${expected_pnf_ready_event}= Get Data From File ${test_case_directory}/expected-pnf-ready-event.json
Add PNF entry in AAI ${pnf_entry}
Set VES event in DMaaP ${ves_event}
- Wait Until Keyword Succeeds 10x 3000ms Check CBS ready
Wait Until Keyword Succeeds 10x 3000ms Check created PNF_READY notification ${expected_pnf_ready_event}
Verify PNF ready sent and old logical link replaced in AAI
@@ -87,7 +86,6 @@ Verify PNF ready sent when service instance non active
Add service instance entry in AAI ${service_instance}
Set VES event in DMaaP ${ves_event}
- Wait Until Keyword Succeeds 10x 3000ms Check CBS ready
Wait Until Keyword Succeeds 10x 3000ms Check created PNF_READY notification ${expected_pnf_ready_event}
Check logical link not modified
@@ -96,12 +94,6 @@ Check logical link not modified
${existing_logical_link}= Get Request ${aai_session} /verify/logical-link headers=${suite_headers}
Should Be Equal As JSON ${expected_logical_link} ${existing_logical_link.content}
-Check CBS ready
- ${resp}= Get Request ${consul_session} /v1/catalog/services
- Should Be Equal As Strings ${resp.status_code} 200
- Log Service Catalog response: ${resp.content}
- Dictionary Should Contain Key ${resp.json()} cbs |Consul service catalog should contain CBS entry
-
Check created PNF_READY notification
[Arguments] ${expected_event_pnf_ready_in_dmaap}
${resp}= Get Request ${dmaap_session} /verify/pnf_ready headers=${suite_headers}
diff --git a/tests/dcaegen2/prh-testcases/resources/prh_sessions.robot b/tests/dcaegen2/prh-testcases/resources/prh_sessions.robot
index 2fadbbae..2616ec16 100644
--- a/tests/dcaegen2/prh-testcases/resources/prh_sessions.robot
+++ b/tests/dcaegen2/prh-testcases/resources/prh_sessions.robot
@@ -5,7 +5,6 @@ Library Collections
*** Variables ***
${DMAAP_SIMULATOR_SETUP_URL} http://${DMAAP_SIMULATOR_SETUP}
${AAI_SIMULATOR_SETUP_URL} http://${AAI_SIMULATOR_SETUP}
-${CONSUL_SETUP_URL} http://${CONSUL_SETUP}
${PRH_SETUP_URL} http://${PRH_SETUP}
*** Keywords ***
@@ -14,8 +13,6 @@ Create sessions
Set Suite Variable ${dmaap_session} dmaap_session
Create Session aai_session ${AAI_SIMULATOR_SETUP_URL}
Set Suite Variable ${aai_session} aai_session
- Create Session consul_session ${CONSUL_SETUP_URL}
- Set Suite Variable ${consul_session} consul_session
Create Session prh_session ${PRH_SETUP_URL}
Set Suite Variable ${prh_session} prh_session