From: Jozef Behran Date: Thu, 21 Apr 2016 16:12:57 +0000 (+0200) Subject: Add support for netconf entities X-Git-Tag: release/beryllium-sr3~93 X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;ds=sidebyside;h=fae076649cc215550034c8cd92ed358acd227e7e;p=integration%2Ftest.git Add support for netconf entities Change-Id: I6ec8a9fd629c893ae6c5f63cd4b3089584e167db Signed-off-by: Jozef Behran --- diff --git a/csit/libraries/ClusterKeywords.robot b/csit/libraries/ClusterKeywords.robot index 4f9cab6c58..f332c5c3b3 100644 --- a/csit/libraries/ClusterKeywords.robot +++ b/csit/libraries/ClusterKeywords.robot @@ -73,12 +73,14 @@ Get Device Entity Owner And Candidates Indexes ${candidates_list}= Create List ${data}= Utils.Get Data From URI ${session} /restconf/operational/entity-owners:entity-owners Log ${data} - ${clear_data}= Run Keyword If '${device_type}' == 'openflow' Extract OpenFlow Device Data ${data} - ... ELSE IF '${device_type}' == 'ovsdb' Extract Ovsdb Device Data ${data} + ${device_style}= BuiltIn.Set_Variable_If '${device_type}' == 'netconf' openflow ${device_type} + ${entity_type}= BuiltIn.Set_Variable_If '${device_type}' == 'netconf' netconf-node/${device} ${device_type} + ${clear_data}= Run Keyword If '${device_style}' == 'openflow' Extract OpenFlow Device Data ${data} + ... ELSE IF '${device_style}' == 'ovsdb' Extract Ovsdb Device Data ${data} ... ELSE Fail Not recognized device type: ${device_type} ${json}= RequestsLibrary.To Json ${clear_data} ${entity_type_list}= Get From Dictionary &{json}[entity-owners] entity-type - ${entity_type_index}= Get Index From List Of Dictionaries ${entity_type_list} type ${device_type} + ${entity_type_index}= Get Index From List Of Dictionaries ${entity_type_list} type ${entity_type} Should Not Be Equal ${entity_type_index} -1 No Entity Owner found for ${device_type} ${entity_list}= Get From Dictionary @{entity_type_list}[${entity_type_index}] entity ${entity_index}= Utils.Get Index From List Of Dictionaries ${entity_list} id ${device} diff --git a/csit/libraries/KarafKeywords.robot b/csit/libraries/KarafKeywords.robot index a50dbbfb95..59308aae02 100644 --- a/csit/libraries/KarafKeywords.robot +++ b/csit/libraries/KarafKeywords.robot @@ -135,8 +135,8 @@ Execute Controller Karaf Command On Background BuiltIn.Run Keyword If '${status_write}' != 'PASS' BuiltIn.Fail Failed to send the command: ${command} BuiltIn.Log ${message_wait} BuiltIn.Run Keyword If '${status_wait}' != 'PASS' BuiltIn.Fail Failed to see prompt after sending the command: ${command} - [Teardown] Restore Current SSH Connection From Index ${current_connection_index} [Return] ${message_wait} + [Teardown] Restore Current SSH Connection From Index ${current_connection_index} Execute Controller Karaf Command With Retry On Background [Arguments] ${command}