OSDN Git Service

Make the test_script ignore and skip empty test directories
authorTheodore Ts'o <tytso@mit.edu>
Sun, 8 Apr 2007 03:16:11 +0000 (23:16 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 8 Apr 2007 03:16:11 +0000 (23:16 -0400)
When patching and unpatching quilt files, empty directories get left
behind in the tests/ directory.  Ignore them to avoid false test
failures.

Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
tests/ChangeLog
tests/test_script.in

index 98e1b75..b867512 100644 (file)
@@ -1,3 +1,7 @@
+2007-04-07  Theodore Tso  <tytso@mit.edu>
+
+       * test_script.in: Skip completely empty directories
+
 2007-04-01  Theodore Tso  <tytso@mit.edu>
 
        * f_dir_bad_mode: New test case.
index b8cecb3..9dbbaf8 100644 (file)
@@ -41,6 +41,9 @@ do
                echo "The test '$test_name' does not exist."
                continue;
        fi
+       if [ -z "`ls $test_dir`" ]; then
+               continue
+       fi
        if [ -f $test_dir/name ]; then
                test_description=`cat $test_dir/name`
                printf "%s: %s: " "$test_name" "$test_description"