tests: Run OVS_WAIT_WHILE, OVS_WAIT_UNTIL in main shell environment.
authorBen Pfaff <blp@ovn.org>
Sun, 5 Jul 2015 17:19:30 +0000 (10:19 -0700)
committerBen Pfaff <blp@ovn.org>
Thu, 26 Nov 2015 21:28:24 +0000 (13:28 -0800)
commit2c920d9d84cfdaa486e3da63cd4b77413221fb64
treef136fb761bd9ce95aca41c664e9afd985d1f3386
parent73e8bc2371975fd7ab690c4b9a5757119f30b2ce
tests: Run OVS_WAIT_WHILE, OVS_WAIT_UNTIL in main shell environment.

AT_CHECK runs its commands in a subshell.  That means that (among other
effects), any variable assignments within its commands will disappear after
the commands' completion.  That doesn't matter for any of the existing
users, which don't do the sorts of things that affect an outer shell
environment anyhow, but an upcoming user wants to make a shell assignment
that persists.  This commit makes that possible, by using AT_CHECK
(actually AT_FAIL_IF but it's moot) only upon failure instead of bracketing
the entire test.

Signed-off-by: Ben Pfaff <blp@ovn.org>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Acked-by: Flavio Leitner <fbl@sysclose.org>
tests/ovs-macros.at