aboutsummaryrefslogtreecommitdiffstats
path: root/resources/libraries/robot
diff options
context:
space:
mode:
Diffstat (limited to 'resources/libraries/robot')
-rw-r--r--resources/libraries/robot/performance/performance_configuration.robot69
-rw-r--r--resources/libraries/robot/performance/performance_setup.robot7
-rw-r--r--resources/libraries/robot/performance/performance_utils.robot99
3 files changed, 124 insertions, 51 deletions
diff --git a/resources/libraries/robot/performance/performance_configuration.robot b/resources/libraries/robot/performance/performance_configuration.robot
index 641b808173..8c94fc78fb 100644
--- a/resources/libraries/robot/performance/performance_configuration.robot
+++ b/resources/libraries/robot/performance/performance_configuration.robot
@@ -117,16 +117,20 @@
| | ${tg1_if2_mac}= | Get Interface MAC | ${tg} | ${tg_if2}
| | ${dut1_if2_mac}= | Get Interface MAC | ${dut1} | ${dut1_if2}
| | ${dut2_if1_mac}= | Get Interface MAC | ${dut2} | ${dut2_if1}
-| | dut1_v4.set_arp | ${dut1_if1} | 10.10.10.2 | ${tg1_if1_mac}
-| | dut1_v4.set_arp | ${dut1_if2} | 1.1.1.2 | ${dut2_if1_mac}
-| | dut2_v4.set_arp | ${dut2_if1} | 1.1.1.1 | ${dut1_if2_mac}
-| | dut2_v4.set_arp | ${dut2_if2} | 20.20.20.2 | ${tg1_if2_mac}
-| | dut1_v4.set_ip | ${dut1_if1} | 10.10.10.1 | 24
-| | dut1_v4.set_ip | ${dut1_if2} | 1.1.1.1 | 30
-| | dut2_v4.set_ip | ${dut2_if1} | 1.1.1.2 | 30
-| | dut2_v4.set_ip | ${dut2_if2} | 20.20.20.1 | 24
-| | dut1_v4.set_route | 20.20.20.0 | 24 | 1.1.1.2 | ${dut1_if2}
-| | dut2_v4.set_route | 10.10.10.0 | 24 | 1.1.1.1 | ${dut2_if1}
+| | Add arp on dut | ${dut1} | ${dut1_if1} | 10.10.10.2 | ${tg1_if1_mac}
+| | Add arp on dut | ${dut1} | ${dut1_if2} | 1.1.1.2 | ${dut2_if1_mac}
+| | Add arp on dut | ${dut2} | ${dut2_if1} | 1.1.1.1 | ${dut1_if2_mac}
+| | Add arp on dut | ${dut2} | ${dut2_if2} | 20.20.20.2 | ${tg1_if2_mac}
+| | Configure IP addresses on interfaces | ${dut1} | ${dut1_if1}
+| | ... | 10.10.10.1 | 24
+| | Configure IP addresses on interfaces | ${dut1} | ${dut1_if2}
+| | ... | 1.1.1.1 | 30
+| | Configure IP addresses on interfaces | ${dut2} | ${dut2_if1}
+| | ... | 1.1.1.2 | 30
+| | Configure IP addresses on interfaces | ${dut2} | ${dut2_if2}
+| | ... | 20.20.20.1 | 24
+| | Vpp Route Add | ${dut1} | 20.20.20.0 | 24 | 1.1.1.2 | ${dut1_if2}
+| | Vpp Route Add | ${dut2} | 10.10.10.0 | 24 | 1.1.1.1 | ${dut2_if1}
| | All Vpp Interfaces Ready Wait | ${nodes}
| Initialize IPv4 forwarding in 2-node circular topology
@@ -141,10 +145,12 @@
| | Set Interface State | ${dut1} | ${dut1_if2} | up
| | ${tg1_if1_mac}= | Get Interface MAC | ${tg} | ${tg_if1}
| | ${tg1_if2_mac}= | Get Interface MAC | ${tg} | ${tg_if2}
-| | dut1_v4.set_arp | ${dut1_if1} | 10.10.10.3 | ${tg1_if1_mac}
-| | dut1_v4.set_arp | ${dut1_if2} | 20.20.20.3 | ${tg1_if2_mac}
-| | dut1_v4.set_ip | ${dut1_if1} | 10.10.10.2 | 24
-| | dut1_v4.set_ip | ${dut1_if2} | 20.20.20.2 | 24
+| | Add arp on dut | ${dut1} | ${dut1_if1} | 10.10.10.3 | ${tg1_if1_mac}
+| | Add arp on dut | ${dut1} | ${dut1_if2} | 20.20.20.3 | ${tg1_if2_mac}
+| | Configure IP addresses on interfaces | ${dut1} | ${dut1_if1}
+| | ... | 10.10.10.2 | 24
+| | Configure IP addresses on interfaces | ${dut1} | ${dut1_if2}
+| | ... | 20.20.20.2 | 24
| | All Vpp Interfaces Ready Wait | ${nodes}
| Initialize IPv4 forwarding with scaling in 3-node circular topology
@@ -238,29 +244,29 @@
| | Set Interface State | ${dut2} | ${dut2_vif1} | up
| | Set Interface State | ${dut2} | ${dut2_vif2} | up
| | Add Fib Table | ${dut1} | ${fib_table_1}
-| | And Vpp Route Add | ${dut1} | 20.20.20.0 | 24 | vrf=${fib_table_1}
-| | ... | gateway=4.4.4.2 | interface=${dut1_vif1} | multipath=${TRUE}
+| | And Vpp Route Add | ${dut1} | 20.20.20.0 | 24 | vrf=${fib_table_1}
+| | ... | gateway=4.4.4.2 | interface=${dut1_vif1} | multipath=${TRUE}
| | Add Fib Table | ${dut1} | ${fib_table_1}
| | And Vpp Route Add | ${dut1} | 10.10.10.0 | 24 | vrf=${fib_table_1}
-| | ... | gateway=1.1.1.2 | interface=${dut1_if1} | multipath=${TRUE}
+| | ... | gateway=1.1.1.2 | interface=${dut1_if1} | multipath=${TRUE}
| | Add Fib Table | ${dut1} | ${fib_table_2}
| | And Vpp Route Add | ${dut1} | 20.20.20.0 | 24 | vrf=${fib_table_2}
-| | ... | gateway=2.2.2.2 | interface=${dut1_if2} | multipath=${TRUE}
+| | ... | gateway=2.2.2.2 | interface=${dut1_if2} | multipath=${TRUE}
| | Add Fib Table | ${dut1} | ${fib_table_2}
| | And Vpp Route Add | ${dut1} | 10.10.10.0 | 24 | vrf=${fib_table_2}
-| | ... | gateway=5.5.5.2 | interface=${dut1_vif2} | multipath=${TRUE}
+| | ... | gateway=5.5.5.2 | interface=${dut1_vif2} | multipath=${TRUE}
| | Add Fib Table | ${dut2} | ${fib_table_1}
| | And Vpp Route Add | ${dut2} | 10.10.10.0 | 24 | vrf=${fib_table_1}
-| | ... | gateway=2.2.2.1 | interface=${dut2_if1} | multipath=${TRUE}
+| | ... | gateway=2.2.2.1 | interface=${dut2_if1} | multipath=${TRUE}
| | Add Fib Table | ${dut2} | ${fib_table_1}
| | And Vpp Route Add | ${dut2} | 20.20.20.0 | 24 | vrf=${fib_table_1}
-| | ... | gateway=4.4.4.1 | interface=${dut2_vif1} | multipath=${TRUE}
+| | ... | gateway=4.4.4.1 | interface=${dut2_vif1} | multipath=${TRUE}
| | Add Fib Table | ${dut2} | ${fib_table_2}
| | And Vpp Route Add | ${dut2} | 10.10.10.0 | 24 | vrf=${fib_table_2}
-| | ... | gateway=5.5.5.2 | interface=${dut2_vif2} | multipath=${TRUE}
+| | ... | gateway=5.5.5.2 | interface=${dut2_vif2} | multipath=${TRUE}
| | Add Fib Table | ${dut2} | ${fib_table_2}
| | And Vpp Route Add | ${dut2} | 20.20.20.0 | 24 | vrf=${fib_table_2}
-| | ... | gateway=3.3.3.2 | interface=${dut2_if2} | multipath=${TRUE}
+| | ... | gateway=3.3.3.2 | interface=${dut2_if2} | multipath=${TRUE}
| | Assign Interface To Fib Table | ${dut1} | ${dut1_if1} | ${fib_table_1}
| | Assign Interface To Fib Table | ${dut1} | ${dut1_vif1} | ${fib_table_1}
| | Assign Interface To Fib Table | ${dut1} | ${dut1_if2} | ${fib_table_2}
@@ -354,16 +360,16 @@
| | ${fib_table_2}= | Evaluate | ${fib_table_1}+${nr}
| | Add Fib Table | ${dut1} | ${fib_table_1}
| | And Vpp Route Add | ${dut1} | 10.10.10.0 | 24 | vrf=${fib_table_1}
-| | ... | gateway=1.1.1.2 | interface=${dut1_if1} | multipath=${TRUE}
+| | ... | gateway=1.1.1.2 | interface=${dut1_if1} | multipath=${TRUE}
| | Add Fib Table | ${dut1} | ${fib_table_2}
| | And Vpp Route Add | ${dut1} | 20.20.20.0 | 24 | vrf=${fib_table_2}
-| | ... | gateway=2.2.2.2 | interface=${dut1_if2} | multipath=${TRUE}
+| | ... | gateway=2.2.2.2 | interface=${dut1_if2} | multipath=${TRUE}
| | Add Fib Table | ${dut2} | ${fib_table_1}
| | And Vpp Route Add | ${dut2} | 10.10.10.0 | 24 | vrf=${fib_table_1}
-| | ... | gateway=2.2.2.1 | interface=${dut2_if1} | multipath=${TRUE}
+| | ... | gateway=2.2.2.1 | interface=${dut2_if1} | multipath=${TRUE}
| | Add Fib Table | ${dut2} | ${fib_table_2}
| | And Vpp Route Add | ${dut2} | 20.20.20.0 | 24 | vrf=${fib_table_2}
-| | ... | gateway=3.3.3.2 | interface=${dut2_if2} | multipath=${TRUE}
+| | ... | gateway=3.3.3.2 | interface=${dut2_if2} | multipath=${TRUE}
| | Assign Interface To Fib Table | ${dut1} | ${dut1_if1} | ${fib_table_1}
| | Assign Interface To Fib Table | ${dut1} | ${dut1_if2} | ${fib_table_2}
| | Assign Interface To Fib Table | ${dut2} | ${dut2_if1} | ${fib_table_1}
@@ -412,19 +418,19 @@
| | | Set Interface State | ${dut2} | ${dut2-vhost-${number}-if2} | up
| | | Add Fib Table | ${dut1} | ${fib_table_1}
| | | And Vpp Route Add | ${dut1} | 20.20.20.0 | 24 | vrf=${fib_table_1}
-| | | ... | gateway=${ip_net_vif1}.1 | interface=${dut1-vhost-${number}-if1}
+| | | ... | gateway=${ip_net_vif1}.1 | interface=${dut1-vhost-${number}-if1}
| | | ... | multipath=${TRUE}
| | | Add Fib Table | ${dut1} | ${fib_table_2}
| | | And Vpp Route Add | ${dut1} | 10.10.10.0 | 24 | vrf=${fib_table_2}
-| | | ... | gateway=${ip_net_vif2}.2 | interface=${dut1-vhost-${number}-if2}
+| | | ... | gateway=${ip_net_vif2}.2 | interface=${dut1-vhost-${number}-if2}
| | | ... | multipath=${TRUE}
| | | Add Fib Table | ${dut2} | ${fib_table_1}
| | | And Vpp Route Add | ${dut2} | 20.20.20.0 | 24 | vrf=${fib_table_1}
-| | | ... | gateway=${ip_net_vif1}.1 | interface=${dut2-vhost-${number}-if1}
+| | | ... | gateway=${ip_net_vif1}.1 | interface=${dut2-vhost-${number}-if1}
| | | ... | multipath=${TRUE}
| | | Add Fib Table | ${dut2} | ${fib_table_2}
| | | And Vpp Route Add | ${dut2} | 10.10.10.0 | 24 | vrf=${fib_table_2}
-| | | ... | gateway=${ip_net_vif2}.2 | interface=${dut2-vhost-${number}-if2}
+| | | ... | gateway=${ip_net_vif2}.2 | interface=${dut2-vhost-${number}-if2}
| | | ... | multipath=${TRUE}
| | | Assign Interface To Fib Table | ${dut1} | ${dut1-vhost-${number}-if1}
| | | ... | ${fib_table_1}
@@ -2166,3 +2172,4 @@
| | | ... | ${dut2-memif-${number}-if1} | ${number}
| | | Add interface to bridge domain | ${dut2}
| | | ... | ${dut2-memif-${number}-if2} | ${bd_id2}
+
diff --git a/resources/libraries/robot/performance/performance_setup.robot b/resources/libraries/robot/performance/performance_setup.robot
index 0cc6388391..51e117ba9e 100644
--- a/resources/libraries/robot/performance/performance_setup.robot
+++ b/resources/libraries/robot/performance/performance_setup.robot
@@ -550,6 +550,13 @@
| | Show VAT History On All DUTs | ${nodes}
| | Show statistics on all DUTs | ${nodes}
+| Tear down performance mrr test
+| | [Documentation] | Common test teardown for max-received-rate performance
+| | ... | tests.
+| | ...
+| | Remove All Added Ports On All DUTs From Topology | ${nodes}
+| | Show VAT History On All DUTs | ${nodes}
+
| Tear down performance test with wrk
| | [Documentation] | Common test teardown for ndrdisc and pdrdisc performance \
| | ... | tests.
diff --git a/resources/libraries/robot/performance/performance_utils.robot b/resources/libraries/robot/performance/performance_utils.robot
index 88826a7c9b..fa3174983e 100644
--- a/resources/libraries/robot/performance/performance_utils.robot
+++ b/resources/libraries/robot/performance/performance_utils.robot
@@ -370,7 +370,7 @@
| | ... | Througput is calculated as:
| | ... | Measured rate per stream * Total number of streams
| | ... | Bandwidth is calculated as:
-| | ... | (Througput * (L2 Frame Size + IPG) * 8) / Max bitrate of NIC
+| | ... | (Throughput * (L2 Frame Size + IPG) * 8) / Max bitrate of NIC
| | ...
| | ... | *Arguments:*
| | ... | - rate_per_stream - Measured rate per stream [pps]. Type: string
@@ -403,7 +403,7 @@
| | ... | Througput is calculated as:
| | ... | Measured rate per stream * Total number of streams
| | ... | Bandwidth is calculated as:
-| | ... | (Througput * (L2 Frame Size + IPG) * 8) / Max bitrate of NIC
+| | ... | (Throughput * (L2 Frame Size + IPG) * 8) / Max bitrate of NIC
| | ...
| | ... | *Arguments:*
| | ... | - rate_per_stream - Measured rate per stream [pps]. Type: string
@@ -435,6 +435,30 @@
| | ... | ${\n}LOSS_ACCEPTANCE: ${loss_acceptance} ${loss_acceptance_type}
| | ... | append=yes
+| Display raw results
+| | [Documentation]
+| | ... | Display raw results from TG in total received/send packets over trial
+| | ... | duration in seconds.
+| | ...
+| | ... | *Arguments:*
+| | ... | - framesize - L2 Frame Size [B]. Type: integer
+| | ... | - results - Measured results. Type: string
+| | ...
+| | ... | *Example:*
+| | ...
+| | ... | \| Display raw results \| 64 \| results \|
+| | ...
+| | [Arguments] | ${framesize} | ${results}
+| | ...
+| | ${framesize}= | Get Frame Size | ${framesize}
+| | @{tokens}= | Split String | ${results} | ,
+| | @{received}= | Split String | @{tokens}[1] | =
+| | @{sent}= | Split String | @{tokens}[2] | =
+| | ${total_received} = | Set Variable | @{received}[1]
+| | ${total_sent} = | Set Variable | @{sent}[1]
+| | Set Test Message | MaxReceivedRate_Results [pkts/${perf_trial_duration}sec]:
+| | Set Test Message | tx ${total_sent}, rx ${total_received} | append=yes
+
| Measure latency pps
| | [Documentation]
| | ... | Send traffic at specified rate. Measure min/avg/max latency
@@ -442,7 +466,7 @@
| | ... | *Arguments:*
| | ... | - duration - Duration of traffic run [s]. Type: integer
| | ... | - rate - Rate for sending packets. Type: integer
-| | ... | - framesize - L2 Frame Size [B]. Type: integer
+| | ... | - framesize - L2 Frame Size [B] or IMIX_v4_1. Type: integer/string
| | ... | - topology_type - Topology type. Type: string
| | ...
| | ... | *Example:*
@@ -467,7 +491,7 @@
| | ... | *Arguments:*
| | ... | - duration - Duration of traffic run [s]. Type: integer
| | ... | - rate - Rate for sending packets. Type: string
-| | ... | - framesize - L2 Frame Size [B]. Type: integer
+| | ... | - framesize - L2 Frame Size [B] or IMIX_v4_1. Type: integer/string
| | ... | - topology_type - Topology type. Type: string
| | ... | - fail_on_loss - If True, the keyword fails if loss occurred.
| | ... | Type: boolean
@@ -480,17 +504,8 @@
| | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
| | ... | ${fail_on_loss}=${True}
| | ...
-| | Clear and show runtime counters with running traffic | ${duration}
-| | ... | ${rate} | ${framesize} | ${topology_type}
-| | ${ret}= | Is DPDK performance test
-| | Run Keyword If | ${ret}==${False} | Clear all counters on all DUTs
-| | Run Keyword If | ${ret}==${False} and ${pkt_trace}==${True}
-| | ... | VPP Enable Traces On All DUTs | ${nodes}
-| | Send traffic on tg | ${duration} | ${rate} | ${framesize}
-| | ... | ${topology_type} | warmup_time=0
-| | Run Keyword If | ${ret}==${False} | Show statistics on all DUTs | ${nodes}
-| | Run Keyword If | ${ret}==${False} and ${pkt_trace}==${True}
-| | ... | Show Packet Trace On All Duts | ${nodes}
+| | Send traffic at specified rate | ${duration} | ${rate} | ${framesize}
+| | ... | ${topology_type}
| | Run Keyword If | ${fail_on_loss} | No traffic loss occurred
| Traffic should pass with partial loss
@@ -501,7 +516,7 @@
| | ... | *Arguments:*
| | ... | - duration - Duration of traffic run [s]. Type: integer
| | ... | - rate - Rate for sending packets. Type: string
-| | ... | - framesize - L2 Frame Size [B]. Type: integer
+| | ... | - framesize - L2 Frame Size [B] or IMIX_v4_1. Type: integer/string
| | ... | - topology_type - Topology type. Type: string
| | ... | - loss_acceptance - Accepted loss during search. Type: float
| | ... | - loss_acceptance_type - Percentage or frames. Type: string
@@ -515,19 +530,63 @@
| | ... | ${loss_acceptance} | ${loss_acceptance_type}
| | ... | ${fail_on_loss}=${True}
| | ...
+| | Send traffic at specified rate | ${duration} | ${rate} | ${framesize}
+| | ... | ${topology_type}
+| | Run Keyword If | ${fail_on_loss} | Partial traffic loss accepted
+| | ... | ${loss_acceptance} | ${loss_acceptance_type}
+
+| Traffic should pass with maximum rate
+| | [Documentation]
+| | ... | Send traffic at maximum rate.
+| | ...
+| | ... | *Arguments:*
+| | ... | - duration - Duration of traffic run [s]. Type: integer
+| | ... | - rate - Rate for sending packets. Type: string
+| | ... | - framesize - L2 Frame Size [B] or IMIX_v4_1. Type: integer/string
+| | ... | - topology_type - Topology type. Type: string
+| | ... | Type: boolean
+| | ...
+| | ... | *Example:*
+| | ...
+| | ... | \| Traffic should pass with no loss \| 10 \| 4.0mpps \| 64 \
+| | ... | \| 3-node-IPv4 \|
+| | ...
+| | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
+| | ...
+| | ${results}= | Send traffic at specified rate | ${duration} | ${rate}
+| | ... | ${framesize} | ${topology_type}
+| | Display raw results | ${framesize} | ${results}
+
+| Send traffic at specified rate
+| | [Documentation]
+| | ... | Send traffic at specified rate.
+| | ...
+| | ... | *Arguments:*
+| | ... | - duration - Duration of traffic run [s]. Type: integer
+| | ... | - rate - Rate for sending packets. Type: string
+| | ... | - framesize - L2 Frame Size [B]. Type: integer/string
+| | ... | - topology_type - Topology type. Type: string
+| | ... | Type: boolean
+| | ...
+| | ... | *Example:*
+| | ...
+| | ... | \| Send traffic at specific rate \| 10 \| 4.0mpps \| 64 \
+| | ... | \| 3-node-IPv4 \|
+| | ...
+| | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
+| | ...
| | Clear and show runtime counters with running traffic | ${duration}
| | ... | ${rate} | ${framesize} | ${topology_type}
| | ${ret}= | Is DPDK performance test
| | Run Keyword If | ${ret}==${False} | Clear all counters on all DUTs
| | Run Keyword If | ${ret}==${False} and ${pkt_trace}==${True}
| | ... | VPP Enable Traces On All DUTs | ${nodes}
-| | Send traffic on tg | ${duration} | ${rate} | ${framesize}
+| | ${results} = | Send traffic on tg | ${duration} | ${rate} | ${framesize}
| | ... | ${topology_type} | warmup_time=0
| | Run Keyword If | ${ret}==${False} | Show statistics on all DUTs | ${nodes}
| | Run Keyword If | ${ret}==${False} and ${pkt_trace}==${True}
| | ... | Show Packet Trace On All Duts | ${nodes}
-| | Run Keyword If | ${fail_on_loss} | Partial traffic loss accepted
-| | ... | ${loss_acceptance} | ${loss_acceptance_type}
+| | Return From Keyword | ${results}
| Clear and show runtime counters with running traffic
| | [Documentation]
@@ -538,7 +597,7 @@
| | ... | *Arguments:*
| | ... | - duration - Duration of traffic run [s]. Type: integer
| | ... | - rate - Rate for sending packets. Type: string
-| | ... | - framesize - L2 Frame Size [B]. Type: integer
+| | ... | - framesize - L2 Frame Size [B] or IMIX_v4_1. Type: integer/string
| | ... | - topology_type - Topology type. Type: string
| | ...
| | ... | *Example:*