Resource ../variables/Variables.robot
*** Variables ***
-${ENTITY_OWNER_URI} restconf/operational/entity-owners:entity-owners
${RESTCONF_URI} rests
${GC_LOG_PATH} ${KARAF_HOME}/data/log
${JAVA_HOME} ${EMPTY} # releng/builder scripts should provide correct value
${ip} = Resolve_IP_Address_For_Member member_index=${index}
${entity_type} = BuiltIn.Set_Variable_If '${device_type}' == 'netconf' netconf-node/${device_name} ${device_type}
${url} = BuiltIn.Catenate SEPARATOR= http:// ${ip} :8181/ ${RESTCONF_URI}
- ${entity_result} = ClusterEntities.get entity ${url} ${entity_type} ${device_name}
+ ${entity_result} = ClusterEntities.Get_Entity ${url} ${entity_type} ${device_name}
${entity_candidates} = Collections.Get_From_Dictionary ${entity_result} candidates
${entity_owner} = Collections.Get_From_Dictionary ${entity_result} owner
BuiltIn.Should_Not_Be_Empty ${entity_owner} No owner found for ${device_name}
Wait Until Keyword Succeeds 5s 1s Check_Json_Member_List_Or_All uri=${uri} expected_data=${data} member_index_list=${member_index_list}
[Return] ${response_text}
+Put_As_Json_And_Check_Member_List_Or_All_RFC8040
+ # FIXME: merge this keyword with Bierman02 version above when OVSDB test is migrated to RFC8040
+ [Arguments] ${uri} ${data} ${member_index} ${member_index_list}=${EMPTY}
+ [Documentation] Send a PUT with the supplied uri ${uri} and body ${data} to member ${member_index}.
+ ... Then check data is replicated in all or some members defined in ${member_index_list}.
+ ${response_text} = Put_As_Json_To_Member uri=${uri} data=${data} member_index=${member_index}
+ Wait Until Keyword Succeeds 5s 1s Check_Json_Member_List_Or_All uri=${uri}?content=config expected_data=${data} member_index_list=${member_index_list}
+ [Return] ${response_text}
+
Put_As_Json_To_Member
[Arguments] ${uri} ${data} ${member_index}
[Documentation] Send a PUT with the supplied uri and data to member ${member_index}.