-| | ...
-| | ... | \| 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
-| | ...
-| | ... | *Arguments:*
-| | ... | - duration - Duration of traffic run [s]. Type: integer
-| | ... | - rate - Rate for sending packets. Type: integer
-| | ... | - framesize - L2 Frame Size [B] or IMIX_v4_1. Type: integer/string
-| | ... | - topology_type - Topology type. Type: string
-| | ...
-| | ... | *Example:*
-| | ...
-| | ... | \| Measure latency \| 10 \| 4.0 \| 64 \| 3-node-IPv4 \|
-| | ...
-| | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
-| | ...
-| | Return From Keyword If | ${rate} <= 10000 | ${-1}
-| | Send traffic on tg | ${duration} | ${rate}pps | ${framesize}
-| | ... | ${topology_type} | warmup_time=0
-| | Run keyword and return | Get latency
-
-| Traffic should pass with no loss
-| | [Documentation]
-| | ... | Send traffic at specified rate. No packet loss is accepted at loss
-| | ... | evaluation.
-| | ...
-| | ... | *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
-| | ... | - fail_on_loss - If True, the keyword fails if loss occurred.
-| | ... | Type: boolean
-| | ...
-| | ... | *Example:*
-| | ...
-| | ... | \| Traffic should pass with no loss \| 10 \| 4.0mpps \| 64 \
-| | ... | \| 3-node-IPv4 \|
-| | ...
-| | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
-| | ... | ${fail_on_loss}=${True}
-| | ...
-| | 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
-| | [Documentation]
-| | ... | Send traffic at specified rate. Partial packet loss is accepted
-| | ... | within loss acceptance value specified as argument.
-| | ...
-| | ... | *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
-| | ... | - loss_acceptance - Accepted loss during search. Type: float
-| | ... | - loss_acceptance_type - Percentage or frames. Type: string
-| | ...
-| | ... | *Example:*
-| | ...
-| | ... | \| Traffic should pass with partial loss \| 10 \| 4.0mpps \| 64 \
-| | ... | \| 3-node-IPv4 \| 0.5 \| percentage \|
-| | ...
-| | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
-| | ... | ${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}
+| |
+| | ... | \| Check NDRPDR interval validity \| \${result.pdr_interval} \
+| | ... | \| \${0.005} \|
+| |
+| | [Arguments] | ${interval} | ${packet_loss_ratio}=${0.0}
+| |
+| | ${lower_bound} = | Set Variable | ${interval.measured_low}
+| | ${lower_bound_lf} = | Set Variable | ${lower_bound.loss_fraction}
+| | Return From Keyword If | ${lower_bound_lf} <= ${packet_loss_ratio}
+| | ${message}= | Catenate | SEPARATOR=${SPACE}
+| | ... | Minimal rate loss fraction ${lower_bound_lf}
+| | ... | does not reach target ${packet_loss_ratio}.
+| | ${message_zero} = | Set Variable | Zero packets forwarded!
+| | ${message_other} = | Set Variable | ${lower_bound.loss_count} packets lost.
+| | ${message} = | Set Variable If | ${lower_bound_lf} >= 1.0
+| | ... | ${message}${\n}${message_zero} | ${message}${\n}${message_other}
+| | Fail | ${message}