From 186c3581e24db7fac8f6fb5523e4fd2a52f61e6d Mon Sep 17 00:00:00 2001 From: Mor Dabastany Date: Mon, 7 Aug 2017 16:14:19 +0300 Subject: Enhance mso_interface.robot Adding POST request to MSO interface. Issue: TEST-51 Change-Id: Ia70333b8ba61337db9df09ed77665f83ed52fbbc Signed-off-by: Mor Dabastany --- robot/resources/mso_interface.robot | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/robot/resources/mso_interface.robot b/robot/resources/mso_interface.robot index cf6aa643..3e983e8a 100644 --- a/robot/resources/mso_interface.robot +++ b/robot/resources/mso_interface.robot @@ -51,5 +51,13 @@ Poll MSO Get Request Log Received response from mso ${resp.text} [Return] ${resp} - - +Run MSO Post request + [Documentation] Runs an MSO post request + [Arguments] ${data_path} ${data} + ${auth}= Create List ${GLOBAL_MSO_USERNAME} ${GLOBAL_MSO_PASSWORD} + Log Creating session ${MSO_ENDPOINT} + ${session}= Create Session mso ${MSO_ENDPOINT} auth=${auth} + ${uuid}= Generate UUID + ${headers}= Create Dictionary Accept=application/json Content-Type=application/json X-TransactionId=${GLOBAL_APPLICATION_ID}-${uuid} X-FromAppId=${GLOBAL_APPLICATION_ID} + ${resp}= Post Request mso ${data_path} data=${data} headers=${headers} + [Return] ${resp} -- cgit 1.2.3-korg