On 3/22/22 14:35, Ilya Maximets wrote:
> OVS_WAIT_UNTIL() macro has only 2 arguments and doesn't check the
> output of the command, but bonding and route tests are trying to use
> it as if it was AT_CHECK macro.  That makes checks in those tests
> mostly useless, since they are not actually checking anything except
> for command returning zero.
> 
> Introducing a new macro OVS_WAIT_UNTIL_EQUAL that will actually
> perform the comparison with the desired output.  Using it for
> the bonding and route tests and fixing all the caught incorrect
> expected outputs along the way.
> 
> Adding an explicit argument check to the OVS_WAIT_UNTIL/WHILE to
> avoid the problem in the future.
> 
> Fixes: b4e50218a0f8 ("bond: Add 'primary' interface concept for active-backup 
> mode.")
> Fixes: 9e11517e6ca6 ("ovs-router: Fix flushing of local routes.")
> Signed-off-by: Ilya Maximets <[email protected]>
> ---
> 
> Version 2:
>   - Fixed the route test.
>   - Added explicit check for the arguments.
>   - Re-named the patch.  v1:
>     
> https://patchwork.ozlabs.org/project/openvswitch/patch/[email protected]/
> 
>  tests/ofproto-dpif.at | 24 ++++++++++++------------
>  tests/ovs-macros.at   | 20 ++++++++++++++++++--
>  tests/system-route.at |  7 +++----
>  3 files changed, 33 insertions(+), 18 deletions(-)

Thanks, David and Aaron for review!

Applied and backported down to 2.15.

Best regards, Ilya Maximets.
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev

Reply via email to