]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
ctdb-tests: Add missing quotes in test output
authorMartin Schwenke <mschwenke@ddn.com>
Wed, 4 Sep 2024 10:10:43 +0000 (20:10 +1000)
committerMartin Schwenke <martins@samba.org>
Sun, 6 Oct 2024 09:52:35 +0000 (09:52 +0000)
These should have caused test failure since commit
ef921bdbdbacecf39ee2a1851f16dbba62175fcc.  However, the test failure
occurred in a sub-shell, which covered the failure.  So, add an error
exit if the sub-shell fails.

While here, add an error exit for another potential uncaught
sub-shell-related failure in a related test.

Signed-off-by: Martin Schwenke <mschwenke@ddn.com>
Reviewed-by: Anoop C S <anoopcs@samba.org>
ctdb/tests/UNIT/eventscripts/13.per_ip_routing.015.sh
ctdb/tests/UNIT/eventscripts/13.per_ip_routing.024.sh

index 742cfd436d7a585547dc256e6ac50ab6d3fc5e37..e1d0c3050a4d3d4418f79667b1885c71c67435e4 100755 (executable)
@@ -17,12 +17,12 @@ ctdb_get_1_public_address |
     ok <<EOF
 WARNING: Failed to delete policy routing rule
   Command "ip rule del from $ip pref $CTDB_PER_IP_ROUTING_RULE_PREF table ctdb.$ip" failed:
-  Error: argument ctdb.$ip is wrong: invalid table ID
-  Error: argument ctdb.$ip is wrong: table id value is invalid
+  Error: argument "ctdb.$ip" is wrong: invalid table ID
+  Error: argument "ctdb.$ip" is wrong: table id value is invalid
 EOF
 
     simple_test_event "releaseip" $dev $ip $bits
-}
+} || exit $?
 
 
 # there should be no routes
index 7b1af3705aa623ae8b44fdd6c3101a4720055038..45b6df1d00bb0b2fa3a93a4816010f0c970dd79d 100755 (executable)
@@ -22,7 +22,7 @@ ctdb_get_1_public_address | {
 Removing ip rule for public address ${ip} for routing table ctdb.${ip}
 EOF
        simple_test_event "shutdown"
-}
+} || exit $?
 
 ok_null
 simple_test_command diff -u "$_rt_orig" "$_rt_tables"