On Fri, Feb 4, 2022 at 11:03 AM Xavier Simonart <[email protected]> wrote:
>
> Tests were waiting for ports to be reported up before sending packets.
> However, waiting for both ports to be up is not enough to guarantee
> that all flows are installed for both ports.
> We now wait for flows outputting to patch port to be installed
>
> Following tests were are fixed:
> - VLAN transparency, passthru=true, multiple hosts
> - VLAN transparency, passthru=true, multiple hosts, custom ethtype
> - VLAN transparency, passthru=true, multiple hosts, flat/untagged
>
> Signed-off-by: Xavier Simonart <[email protected]>

Thanks.  I applied this patch to the main branch.

Numan

> ---
>  tests/ovn.at | 37 ++++++++++++++++++++++++++++++++++++-
>  1 file changed, 36 insertions(+), 1 deletion(-)
>
> diff --git a/tests/ovn.at b/tests/ovn.at
> index 957eb7850..e65a01ff6 100644
> --- a/tests/ovn.at
> +++ b/tests/ovn.at
> @@ -3497,6 +3497,18 @@ for i in 1 2; do
>                                    options:rxq_pcap=vif$i-rx.pcap \
>                                    ofport-request=$i
>      OVS_WAIT_UNTIL([test x`ovn-nbctl lsp-get-up lsp$i` = xup])
> +
> +    # Patch port might be created after ports are reported up
> +    OVS_WAIT_UNTIL([
> +        test 1 = `ovs-vsctl show | \
> +        grep "Port patch-br-int-to-ln-100" | wc -l`
> +    ])
> +
> +    # Wait for a flow outputing to patch port
> +    hv_patch_ofport=$(ovs-vsctl --bare --columns ofport find Interface 
> name=patch-br-int-to-ln-100)
> +    OVS_WAIT_UNTIL([
> +        test 1 = $(ovs-ofctl dump-flows br-int | grep -c 
> "output:$hv_patch_ofport")
> +    ])
>  done
>
>  test_packet() {
> @@ -3562,8 +3574,19 @@ for i in 1 2; do
>                                    options:rxq_pcap=vif$i-rx.pcap \
>                                    ofport-request=$i
>      wait_for_ports_up lsp$i
> -done
>
> +    # Patch port might be created after ports are reported up
> +    OVS_WAIT_UNTIL([
> +        test 1 = `ovs-vsctl show | \
> +        grep "Port patch-br-int-to-ln-100" | wc -l`
> +    ])
> +
> +    # Wait for a flow outputing to patch port
> +    hv_patch_ofport=$(ovs-vsctl --bare --columns ofport find Interface 
> name=patch-br-int-to-ln-100)
> +    OVS_WAIT_UNTIL([
> +        test 1 = $(ovs-ofctl dump-flows br-int | grep -c 
> "output:$hv_patch_ofport")
> +    ])
> +done
>  # create taps on fabric to check vlan encapsulation there
>  for i in 1 2; do
>      as hv-$i
> @@ -3645,6 +3668,18 @@ for i in 1 2; do
>                                    options:rxq_pcap=vif$i-rx.pcap \
>                                    ofport-request=$i
>      OVS_WAIT_UNTIL([test x`ovn-nbctl lsp-get-up lsp$i` = xup])
> +
> +    # Patch port might be created after ports are reported up
> +    OVS_WAIT_UNTIL([
> +        test 1 = `ovs-vsctl show | \
> +        grep "Port patch-br-int-to-ln" | wc -l`
> +    ])
> +
> +    # Wait for a flow outputing to patch port
> +    hv_patch_ofport=$(ovs-vsctl --bare --columns ofport find Interface 
> name=patch-br-int-to-ln)
> +    OVS_WAIT_UNTIL([
> +        test 1 = $(ovs-ofctl dump-flows br-int | grep -c 
> "output:$hv_patch_ofport")
> +    ])
>  done
>
>  for i in 1 2; do
> --
> 2.31.1
>
> _______________________________________________
> dev mailing list
> [email protected]
> https://mail.openvswitch.org/mailman/listinfo/ovs-dev
>
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to