aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorConor Ward <conor.ward@ericsson.com>2018-10-01 11:03:25 +0000
committerConor Ward <conor.ward@ericsson.com>2018-10-01 11:03:25 +0000
commitfdcd89c0e9f5b967530b88ebd163c4e779f37347 (patch)
treefc4f1be2bcbdf235dcf5220a8a8700a8fdb95665 /tests
parent9085d59afb28c185183afe4058954c69f9e15bd2 (diff)
Publish to Prov in CSIT
Change-Id: I18b4ab6fa2a86eddad1c88c39392482f0f1f40fc Signed-off-by: Conor Ward <conor.ward@ericsson.com> Issue-ID: DMAAP-575
Diffstat (limited to 'tests')
-rwxr-xr-xtests/dmaap-datarouter/dr-suite/dr-suite.robot18
1 files changed, 10 insertions, 8 deletions
diff --git a/tests/dmaap-datarouter/dr-suite/dr-suite.robot b/tests/dmaap-datarouter/dr-suite/dr-suite.robot
index fcac2026..d00bddc7 100755
--- a/tests/dmaap-datarouter/dr-suite/dr-suite.robot
+++ b/tests/dmaap-datarouter/dr-suite/dr-suite.robot
@@ -10,7 +10,8 @@ ${TARGET_URL} https://${DR_PROV_IP}:8443
${TARGET_URL_FEED} https://${DR_PROV_IP}:8443/feed/1
${TARGET_URL_SUBSCRIBE} https://${DR_PROV_IP}:8443/subscribe/1
${TARGET_URL_SUBSCRIPTION} https://${DR_PROV_IP}:8443/subs/1
-${TARGET_URL_PUBLISH} https://${DR_NODE_IP}:8443/publish/1/csit_test
+${TARGET_URL_PUBLISH_PROV} https://${DR_PROV_IP}:8443/publish/1/csit_test
+${TARGET_URL_PUBLISH_NODE} https://${DR_NODE_IP}:8443/publish/1/csit_test
${CREATE_FEED_DATA} {"name": "CSIT_Test", "version": "m1.0", "description": "CSIT_Test", "business_description": "CSIT_Test", "suspend": false, "deleted": false, "changeowner": true, "authorization": {"classification": "unclassified", "endpoint_addrs": [], "endpoint_ids": [{"password": "rs873m", "id": "rs873m"}]}}
${UPDATE_FEED_DATA} {"name": "CSIT_Test", "version": "m1.0", "description": "UPDATED-CSIT_Test", "business_description": "CSIT_Test", "suspend": true, "deleted": false, "changeowner": true, "authorization": {"classification": "unclassified", "endpoint_addrs": [], "endpoint_ids": [{"password": "rs873m", "id": "rs873m"}]}}
${SUBSCRIBE_DATA} {"delivery":{ "url":"https://${DR_PROV_IP}:8080/", "user":"rs873m", "password":"rs873m", "use100":true}, "metadataOnly":false, "suspend":false, "groupid":29, "subscriber":"sg481n"}
@@ -42,9 +43,10 @@ Run Publish Feed
[Documentation] Publish to Feed
[Timeout] 1 minute
Sleep 10s Behaviour was noticed where feed was not created in time for publish to be sent
- ${resp}= PutCall ${TARGET_URL_PUBLISH} ${CREATE_FEED_DATA} ${PUBLISH_FEED_CONTENT_TYPE} rs873m
- log ${TARGET_URL_PUBLISH}
- log ${resp.text}
+ ${resp}= PutCall ${TARGET_URL_PUBLISH_PROV} ${CREATE_FEED_DATA} ${PUBLISH_FEED_CONTENT_TYPE} rs873m
+ log ${TARGET_URL_PUBLISH_PROV}
+ Should Contain ${resp.headers['Location']} https://dmaap-dr-node:8443/publish/1/csit_test
+ ${resp}= PutCall ${TARGET_URL_PUBLISH_NODE} ${CREATE_FEED_DATA} ${PUBLISH_FEED_CONTENT_TYPE} rs873m
Should Be Equal As Strings ${resp.status_code} 204
log 'JSON Response Code:'${resp}
@@ -94,23 +96,23 @@ Run Delete Feed
PostCall
[Arguments] ${url} ${data} ${content_type} ${user}
${headers}= Create Dictionary X-ATT-DR-ON-BEHALF-OF=${user} Content-Type=${content_type}
- ${resp}= Evaluate requests.post('${url}',data='${data}', headers=${headers},verify=False) requests
+ ${resp}= Evaluate requests.post('${url}', data='${data}', headers=${headers}, verify=False) requests
[Return] ${resp}
PutCall
[Arguments] ${url} ${data} ${content_type} ${user}
${headers}= Create Dictionary X-ATT-DR-ON-BEHALF-OF=${user} Content-Type=${content_type} Authorization=Basic cnM4NzNtOnJzODczbQ==
- ${resp}= Evaluate requests.put('${url}',data='${data}', headers=${headers},verify=False) requests
+ ${resp}= Evaluate requests.put('${url}', data='${data}', headers=${headers}, verify=False, allow_redirects=False) requests
[Return] ${resp}
GetCall
[Arguments] ${url} ${content_type} ${user}
${headers}= Create Dictionary X-ATT-DR-ON-BEHALF-OF=${user} Content-Type=${content_type}
- ${resp}= Evaluate requests.get('${url}', headers=${headers},verify=False) requests
+ ${resp}= Evaluate requests.get('${url}', headers=${headers}, verify=False) requests
[Return] ${resp}
DeleteCall
[Arguments] ${url} ${user}
${headers}= Create Dictionary X-ATT-DR-ON-BEHALF-OF=${user}
- ${resp}= Evaluate requests.delete('${url}', headers=${headers},verify=False) requests
+ ${resp}= Evaluate requests.delete('${url}', headers=${headers}, verify=False) requests
[Return] ${resp}