blob: 01178f0d3fe79ba216ca9d142f74818d0bba4be7 [file] [log] [blame]
Kanagaraj Manickam k00365106bbc13952018-04-16 11:20:21 +05301*** Settings ***
2Documentation The main interface for interacting with CLI.
Kanagaraj Manickam k00365106bbc13952018-04-16 11:20:21 +05303Library RequestsLibrary
4
5Resource global_properties.robot
6
7*** Variables ***
8${CLI_HEALTH_CHECK_PATH} /
9${CLI_ENDPOINT} ${GLOBAL_CLI_SERVER_PROTOCOL}://${GLOBAL_INJECTED_CLI_IP_ADDR}:${GLOBAL_CLI_SERVER_PORT}
10
11*** Keywords ***
12Run CLI Health Check
13 [Documentation] Runs CLI Health check
14 ${resp}= Run CLI Get Request ${CLI_HEALTH_CHECK_PATH}
15 Should Be Equal As Strings ${resp.status_code} 200
16
17Run CLI Get Request
18 [Documentation] Runs CLI Get request
19 [Arguments] ${data_path}
20 ${session}= Create Session cli ${CLI_ENDPOINT}
21 ${resp}= Get Request cli ${data_path}
22 Log Received response from CLI ${resp.text}
23 [Return] ${resp}
24