[PATCH] udev-test.pl: set non-zero exitcode if tests fail

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This will allow for automated testing e.g. git-bisect run:

git bisect run sudo sh -c "cd test; ./udev-test.pl"

Signed-off-by: Alan Jenkins <alan-jenkins@xxxxxxxxxxxxxx>

diff --git a/test/udev-test.pl b/test/udev-test.pl
index a83b156..27ff2a7 100755
--- a/test/udev-test.pl
+++ b/test/udev-test.pl
@@ -1896,3 +1896,7 @@ system("rm -rf $udev_root");
 unlink($udev_rules);
 unlink($udev_conf);
 
+if ($error > 0) {
+    exit(1);
+}
+exit(0);


--
To unsubscribe from this list: send the line "unsubscribe linux-hotplug" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel]     [Linux DVB]     [Asterisk Internet PBX]     [DCCP]     [Netdev]     [X.org]     [Util Linux NG]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux