X-Git-Url: https://gerrit.fd.io/r/gitweb?p=csit.git;a=blobdiff_plain;f=resources%2Flibraries%2Frobot%2Fhoneycomb%2Ftap.robot;h=37d6a02f52f79bd18de80a78aa3070afef1e94ea;hp=2fffffa06789e8d116a81ce493191497006f1a7c;hb=20cc67d5f23a7f4e05b08012bf3d3a63be4bcf63;hpb=498085ca750fda8e19379d45c05f1bda4df873e1 diff --git a/resources/libraries/robot/honeycomb/tap.robot b/resources/libraries/robot/honeycomb/tap.robot index 2fffffa067..37d6a02f52 100644 --- a/resources/libraries/robot/honeycomb/tap.robot +++ b/resources/libraries/robot/honeycomb/tap.robot @@ -13,9 +13,7 @@ *** Settings *** | Library | resources.libraries.python.InterfaceUtil -| ... | WITH NAME | interfaceCLI | Library | resources.libraries.python.honeycomb.HcAPIKwInterfaces.InterfaceKeywords -| ... | WITH NAME | InterfaceAPI | Documentation | Keywords used to manipulate TAP interfaces. *** Keywords *** @@ -29,11 +27,11 @@ | | ... | | ... | *Example:* | | ... | \| Honeycomb creates TAP interface \ -| | ... | \| ${nodes['DUT1']} \| tap_int1 \| ${{'tap-name':'tap1',\ -| | ... | 'mac':'08:00:27:60:26:ab', 'device-instance':3}} \| +| | ... | \| ${nodes['DUT1']} \| tap_int1 \| ${{'host-interface-name':'tap1',\ +| | ... | 'mac':'08:00:27:60:26:ab', 'id':3}} \| | | ... | | [Arguments] | ${node} | ${interface} | ${settings} -| | interfaceAPI.Create TAP interface | ${node} | ${interface} +| | Create TAP interface | ${node} | ${interface} | | ... | &{settings} | Honeycomb configures TAP interface @@ -46,11 +44,11 @@ | | ... | | ... | *Example:* | | ... | \| Honeycomb configures TAP interface \ -| | ... | \| ${nodes['DUT1']} \| tap_int1 \| ${{'tap-name':'tap1',\ -| | ... | 'mac':'08:00:27:60:26:ab', 'device-instance':3}} \| +| | ... | \| ${nodes['DUT1']} \| tap_int1 \| ${{'host-interface-name':'tap1',\ +| | ... | 'mac':'08:00:27:60:26:ab', 'id':3}} \| | | ... | | [Arguments] | ${node} | ${interface} | ${settings} -| | interfaceAPI.Configure interface TAP | ${node} | ${interface} +| | Configure interface TAP | ${node} | ${interface} | | ... | &{settings} | Honeycomb removes TAP interface @@ -65,9 +63,9 @@ | | ... | \| Honeycomb removes TAP interface \ | | ... | \| ${nodes['DUT1']} \| tap_int1 \| | | [Arguments] | ${node} | ${interface} -| | interfaceAPI.Delete interface | ${node} | ${interface} +| | Delete interface | ${node} | ${interface} -| TAP configuration from Honeycomb should be +| TAP Operational Data From Honeycomb Should Be | | [Documentation] | Retrieves interface TAP configuration through Honeycomb\ | | ... | and compares with settings supplied in argument. | | ... @@ -78,18 +76,18 @@ | | ... | | ... | *Example:* | | ... -| | ... | \| TAP configuration from Honeycomb should be \ -| | ... | \| ${nodes['DUT1']} \| tap_int1 \| ${{'tap-name':'tap1',\ -| | ... | 'mac':'08:00:27:60:26:ab', 'device-instance':3}} \| +| | ... | \| TAP Operational Data From Honeycomb Should Be \ +| | ... | \| ${nodes['DUT1']} \| tap_int1 \| ${{'host-interface-name':'tap1',\ +| | ... | 'mac':'08:00:27:60:26:ab', 'id':3}} \| | | ... | | [Arguments] | ${node} | ${interface} | ${settings} -| | ${api_data}= | interfaceAPI.Get interface oper data | ${node} | ${interface} -| | ${api_tap}= | Set Variable | ${api_data['v3po:tap']} -| | Should be equal | ${api_tap['tap-name']} | ${settings['tap-name']} +| | ${api_data}= | Get interface oper data | ${node} | ${interface} +| | ${api_tap}= | Set Variable | ${api_data['v3po:tap-v2']} +| | Should be equal | ${api_tap['device-name']} | ${settings['device-name']} | | ${api_mac}= | Set Variable | ${api_data['phys-address']} | | Should be equal | ${api_mac} | ${settings['mac']} -| TAP configuration from VAT should be +| TAP Operational Data From VAT Should Be | | [Documentation] | Retrieves interface TAP configuration through VAT and\ | | ... | compares with settings supplied in argument. | | ... @@ -99,16 +97,18 @@ | | ... | | ... | *Example:* | | ... -| | ... | \| TAP configuration from Honeycomb should be \ -| | ... | \| ${nodes['DUT1']} \| ${{'tap-name':'tap1',\ -| | ... | 'mac':'08:00:27:60:26:ab', 'device-instance':3}} \| +| | ... | \| TAP Operational Data From Honeycomb Should Be \ +| | ... | \| ${nodes['DUT1']} \| ${{'host-interface-name':'tap1',\ +| | ... | 'mac':'08:00:27:60:26:ab', 'id':3}} \| | | ... | | [Arguments] | ${node} | ${interface} | ${settings} | | ${vat_data}= | TAP Dump | ${node} | ${interface} -| | Should be equal | ${vat_data['dev_name']} | ${settings['tap-name']} +| | Should be equal | ${vat_data['dev_name']} | ${settings['dev_name']} +| | Should be equal | ${vat_data['rx_ring_sz']} | ${settings['rx_ring_sz']} +| | Should be equal | ${vat_data['tx_ring_sz']} | ${settings['tx_ring_sz']} # other settings not accessible through VAT commands -| TAP configuration from Honeycomb should be empty +| TAP Operational Data From Honeycomb Should Be empty | | [Documentation] | Attempts to retrieve interface TAP configuration\ | | ... | through Honeycomb and expects to recieve an empty dictionary. | | ... @@ -118,15 +118,15 @@ | | ... | | ... | *Example:* | | ... -| | ... | \| TAP configuration from Honeycomb should be empty\ +| | ... | \| TAP Operational Data From Honeycomb Should Be empty\ | | ... | \| ${nodes['DUT1']} \| tap_int1 \| | | ... | | [Arguments] | ${node} | ${interface} -| | ${api_data}= | interfaceAPI.Get interface oper data | ${node} | ${interface} -| | Run keyword and expect error | *KeyError: 'v3po:tap' | Set Variable -| | ... | ${api_data['v3po:tap']} +| | ${api_data}= | Get interface oper data | ${node} | ${interface} +| | Run keyword and expect error | *KeyError: 'v3po:tap-v2' | Set Variable +| | ... | ${api_data['v3po:tap-v2']} -| TAP configuration from VAT should be empty +| TAP Operational Data From VAT Should Be empty | | [Documentation] | Attempts to retrieve interface TAP configuration\ | | ... | through VAT and expects a "no data" error. | | ... @@ -136,9 +136,9 @@ | | ... | | ... | *Example:* | | ... -| | ... | \| TAP configuration from VAT should be empty\ +| | ... | \| TAP Operational Data From VAT Should Be empty\ | | ... | \| ${nodes['DUT1']} \| tap_int1 \| | | ... | | [Arguments] | ${node} | ${interface} -| | Run Keyword And Expect Error | ValueError: No JSON object could be decoded -| | ... | TAP Dump | ${node} | ${interface} +| | ${data}= | TAP Dump | ${node} | ${interface} +| | Should be empty | ${data}