diff options
author | rajendrajaiswal <rajendra.jaiswal@ericsson.com> | 2019-02-11 12:30:26 +0000 |
---|---|---|
committer | root <rajendra.jaiswal@ericsson.com> | 2019-02-11 16:15:37 +0000 |
commit | 8f0afd8a099200fb7001ded306dceb015a63517b (patch) | |
tree | 598a735f3ca7d99b58f2663dae982676a2aa69b1 /tests | |
parent | 9c67e5814d6b4a5e5677ee3f8eb4393f4f1a326c (diff) |
Updated Test and Setup files for PM Mapper
Change-Id: I8dd4d60a6b54178575363f494d8ca7565306a514
Issue-ID: INT-863
Signed-off-by: Rajendra Jaiswal <rajendra.jaiswal@ericsson.com>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/dcaegen2-pmmapper/pmmapper/pmmapper.robot | 29 |
1 files changed, 24 insertions, 5 deletions
diff --git a/tests/dcaegen2-pmmapper/pmmapper/pmmapper.robot b/tests/dcaegen2-pmmapper/pmmapper/pmmapper.robot index f65ef2b4..ccfa4968 100644 --- a/tests/dcaegen2-pmmapper/pmmapper/pmmapper.robot +++ b/tests/dcaegen2-pmmapper/pmmapper/pmmapper.robot @@ -1,14 +1,19 @@ *** Settings *** Documentation Testing PM Mapper functionality -Library RequestsLibrary -Library OperatingSystem +Resource ../../common.robot Library Collections +Library json +Library OperatingSystem +Library RequestsLibrary +Library HttpLibrary.HTTP +Library String Library Process *** Variables *** -${GLOBAL_APPLICATION_ID} robot-ves -${CLI_EXEC_CLI} curl http://${CBS_IP}:10000/service_component/pmmapper +${BC_URL} http://${DMAAPBC_IP}:8080/webapi +${CLI_EXEC_CLI} curl http://${CBS_IP}:10000/service_component/pmmapper +${FEED1_DATA} { "feedName":"feed1", "feedVersion": "csit", "feedDescription":"generated for CSIT", "owner":"dgl", "asprClassification": "unclassified" } *** Test Cases *** @@ -18,4 +23,18 @@ Verify pmmapper configuration in consul through CBS [Documentation] Verify pmmapper configuraiton in consul through CBS ${cli_cmd_output}= Run Process ${CLI_EXEC_CLI} shell=yes Log ${cli_cmd_output.stdout} - Should Contain ${cli_cmd_output.stdout} pm-mapper-filter
\ No newline at end of file + Should Contain ${cli_cmd_output.stdout} pm-mapper-filter + +Create DR Feed through Bus Controller + [Tags] PM_MAPPER_02 + [Documentation] Create Feed on Data Router through Bus Controller + ${resp}= PostCall ${BC_URL}/feeds ${FEED1_DATA} + Should Be Equal As Integers ${resp.status_code} 200 + +*** Keywords *** + +PostCall + [Arguments] ${url} ${data} + ${headers}= Create Dictionary Accept=application/json Content-Type=application/json + ${resp}= Evaluate requests.post('${url}',data='${data}', headers=${headers},verify=False) requests + [Return] ${resp}
\ No newline at end of file |