]> git.ipfire.org Git - thirdparty/e2fsprogs.git/commitdiff
tests: skip running long test with "make check" and add "make fullcheck"
authorTheodore Ts'o <tytso@mit.edu>
Wed, 26 Apr 2017 14:07:18 +0000 (10:07 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Wed, 26 Apr 2017 14:07:18 +0000 (10:07 -0400)
Don't run tests which take longer than 20 seconds to run (especially
f_large_dir, whose run time is well over ten minutes) for "make
check".  The new "make fullcheck" will run all of the regression tests
for e2fsprogs.

Signed-off-by: Theodore Ts'o <tytso@mit.edu>
22 files changed:
MCONFIG.in
Makefile.in
debugfs/Makefile.in
e2fsck/Makefile.in
intl/Makefile.in
lib/blkid/Makefile.in
lib/e2p/Makefile.in
lib/et/Makefile.in
lib/ext2fs/Makefile.in
lib/ss/Makefile.in
lib/support/Makefile.in
lib/uuid/Makefile.in
misc/Makefile.in
po/Makefile.in.in
resize/Makefile.in
tests/Makefile.in
tests/f_large_dir/is_slow_test [new file with mode: 0644]
tests/f_mmp/is_slow_test [new file with mode: 0644]
tests/f_mmp_garbage/is_slow_test [new file with mode: 0644]
tests/r_64bit_big_expand/is_slow_test [new file with mode: 0644]
tests/r_ext4_big_expand/is_slow_test [new file with mode: 0644]
tests/test_one.in

index e82963d238319f67c9d515259cc3294e0159c8d5..22b74eba44152f37a864f16e36dc390656c7a554 100644 (file)
@@ -4,6 +4,8 @@ all::
 
 check::
 
+fullcheck::
+
 SHELL = /bin/sh
 
 COMPRESS_EXT = gz bz2 bz Z
index 7da9ad7df16f709e59a9214b919155934c7407ea..37b60692f68f9ef3935cfdfea07d335082ab6698 100644 (file)
@@ -78,8 +78,9 @@ coverage.txt: coverage.txt-recursive
 
 check-recursive: all
 
-TAGS clean-recursive distclean-recursive depend-recursive check-recursive \
-  mostlyclean-recursive realclean-recursive coverage.txt-recursive:
+TAGS clean-recursive distclean-recursive depend-recursive fullcheck-recursive \
+  check-recursive mostlyclean-recursive realclean-recursive \
+  coverage.txt-recursive:
        @for subdir in $(SUBDIRS); do \
          if test -d $$subdir ; then \
            target=`echo $@|$(SED) 's/-recursive//'`; \
@@ -151,3 +152,4 @@ realclean-local: distclean-local
 
 check::        all check-recursive
 
+fullcheck:: all fullcheck-recursive
index 3ac80d9b9b018db7f83abd1e2c4c85d1ac082dc7..408a3236694d18201e56492cb4eb0d8b35a5538a 100644 (file)
@@ -164,7 +164,7 @@ tst_set_fields: set_fields.c util.c
        $(Q) $(CC) $(ALL_CFLAGS) $(ALL_LDFLAGS) $(SYSLIBS) -DUNITTEST \
                -o tst_set_fields $(srcdir)/set_fields.c $(srcdir)/util.c $(LIBS)
 
-check:: tst_set_fields
+fullcheck check:: tst_set_fields
        $(TESTENV) ./tst_set_fields
 
 # +++ Dependency line eater +++
index cee6a42b5360f2a151de8a488b39c48b2447fa64..e43d34049147633e9d87c33da019f88d979dfb1a 100644 (file)
@@ -150,7 +150,7 @@ tst_region: region.c $(DEPLIBCOM_ERR)
                $(ALL_CFLAGS) $(ALL_LDFLAGS) -DTEST_PROGRAM \
                $(LIBCOM_ERR) $(SYSLIBS)
 
-check:: tst_refcount tst_region tst_problem
+fullcheck check:: tst_refcount tst_region tst_problem
        $(TESTENV) ./tst_refcount
        $(TESTENV) ./tst_region
        $(TESTENV) ./tst_problem
index db6d7d71876677a30538cb2dc69ecf0aff5c35b1..66d7512113375808ee80eddc717e6f1825575120 100644 (file)
@@ -293,7 +293,7 @@ charset.alias: $(srcdir)/config.charset
        $(Q) $(SHELL) $(srcdir)/config.charset '@host@' > t-$@
        $(Q) mv t-$@ $@
 
-check: all
+fullcheck check: all
 
 # We must not install the libintl.h/libintl.a files if we are on a
 # system which has the GNU gettext() function in its C library or in a
index 7f384527ec1e89fd5e44132c82628dd67222fb31..0be2da5cd76494e9447d55c6d09b80bfa802bb9a 100644 (file)
@@ -135,8 +135,9 @@ test_probe: test_probe.in Makefile
        $(Q) cat $(srcdir)/test_probe.in >> test_probe
        $(Q) chmod +x test_probe
 
-check:: all tst_cache tst_dev tst_devname tst_devno tst_getsize tst_probe \
- tst_read tst_resolve tst_save tst_tag test_probe tst_types
+fullcheck check:: all tst_cache tst_dev tst_devname tst_devno \
+ tst_getsize tst_probe tst_read tst_resolve tst_save tst_tag \
+ test_probe tst_types
        ./test_probe
        ./tst_types
 
index 6fd2ceca6bb467169bedc49d667cdabe92ad1148..d266d68ae9f62504e7b74d0f07cfba0c5a0ef187 100644 (file)
@@ -75,7 +75,7 @@ tst_feature: $(srcdir)/feature.c
        $(Q) $(CC) -DTEST_PROGRAM -I$(top_srcdir)/lib -o tst_feature \
                $(srcdir)/feature.c $(ALL_CFLAGS) $(ALL_LDFLAGS)
 
-check::        tst_ostype tst_feature
+fullcheck check::      tst_ostype tst_feature
        ./tst_ostype
        ./tst_feature
 
index 476f1894267340c3396bb1f9775895d746bf3deb..0344679e8e8d97243a5833e4cd7fb265c26afaee 100644 (file)
@@ -137,7 +137,7 @@ uninstall::
                $(DESTDIR)$(pkgconfigdir)/com_err.pc
        $(RM) -rf $(DESTDIR)$(includedir)/et $(DESTDIR)$(datadir)/et
 
-check:: compile_et
+fullcheck check:: compile_et
        for i in $(srcdir)/test_cases/*.et ; do \
                t=`basename $$i | sed -e 's/.et//'`; \
                _ET_DIR_OVERRIDE=$(srcdir) ./compile_et $$i ; \
index 425b85614a6670254eaf2417080cbbdb0ebf401e..b23bf8823679e07e65411d9a8fdcf01a6cc62612 100644 (file)
@@ -521,7 +521,7 @@ mkjournal: mkjournal.c $(STATIC_LIBEXT2FS) $(DEPLIBCOM_ERR)
        $(Q) $(CC) -o mkjournal $(srcdir)/mkjournal.c -DDEBUG \
                $(STATIC_LIBEXT2FS) $(LIBCOM_ERR) $(ALL_CFLAGS) $(SYSLIBS)
 
-check:: tst_bitops tst_badblocks tst_iscan tst_types tst_icount \
+fullcheck check:: tst_bitops tst_badblocks tst_iscan tst_types tst_icount \
     tst_super_size tst_types tst_inode_size tst_csum tst_crc32c tst_bitmaps \
     tst_inline tst_inline_data tst_libext2fs tst_sha256 tst_sha512 \
     tst_digest_encode tst_getsize tst_getsectsize
index f4953f070ba3d93babd717fc37df1bbd442453e8..ee18dc889335d9ee7dde3b4dd26835dd8e720da4 100644 (file)
@@ -163,7 +163,7 @@ test_ss: test_ss.o test_cmd.o $(DEPLIBSS) $(DEPLIBCOM_ERR)
        $(Q) $(CC) -o $@ test_ss.o test_cmd.o $(ALL_CFLAGS) $(ALL_LDFLAGS) \
                $(LIBSS) $(LIBCOM_ERR) $(SYSLIBS)
 
-check:: all test_ss
+fullcheck check:: all test_ss
        $(E) "  RUN TEST test_ss"
        -@($(TESTENV) ./test_ss -f $(srcdir)/test_script > test_out 2>&1; exit 0)
        $(Q) if diff test_out $(srcdir)/test_script_expected > test.diff; then \
index d5a6f26deb74a48b3cec4d2119da642e2b9eebc2..40206b748b7c7816e38cb1a93afbc9847b3e8c09 100644 (file)
@@ -79,7 +79,7 @@ clean::
                ../libsupport.a ../libsupport_p.a $(SMANPAGES) \
                prof_err.c prof_err.h test_profile test_cstring
 
-#check:: tst_uuid
+#fullcheck check:: tst_uuid
 #      LD_LIBRARY_PATH=$(LIB) DYLD_LIBRARY_PATH=$(LIB) ./tst_uuid
 
 mostlyclean:: clean
index a29814496f9a5cfea96387fc0bbe4fd5aff8ab27..4b44418299d739f7f087bdf7ee2b08e2da495939 100644 (file)
@@ -171,7 +171,7 @@ clean::
                ../libuuid.a ../libuuid_p.a tst_uuid uuid_time \
                uuid.pc uuid_types.h $(SMANPAGES)
 
-check:: tst_uuid
+fullcheck check:: tst_uuid
        LD_LIBRARY_PATH=$(LIB) DYLD_LIBRARY_PATH=$(LIB) ./tst_uuid
 
 mostlyclean:: clean
index 467c15d36266e410f9ca6a96da8d8fe5e274a2c1..d08859d9d971d50e62864634d8ca3250815e7326 100644 (file)
@@ -252,7 +252,7 @@ base_device: base_device.c
        $(Q) $(CC) $(ALL_CFLAGS) $(ALL_LDFLAGS) $(srcdir)/base_device.c \
                -DDEBUG -o base_device $(SYSLIBS)
 
-check:: base_device
+fullcheck check:: base_device
        ./base_device < $(srcdir)/base_device.tst > base_device.out
        cmp $(srcdir)/base_device.tst base_device.out
 
index 2ae2f2a214d9efe2d5bba6a13be00194b2338895..eff37d33737d200424611ed29be6ace30f793adf 100644 (file)
@@ -270,7 +270,7 @@ uninstall-data-yes:
          done; \
        done
 
-check: all
+fullcheck check: all
 
 info dvi ps pdf html tags TAGS ctags CTAGS ID:
 
index 6014bdd0cedd2b6fabf044fdbe1259b07f569ed4..cb9f5530f6ae0b5beb7c9ddcf6706e47dcebf9f8 100644 (file)
@@ -94,7 +94,7 @@ uninstall:
 test_extent.out: test_extent $(srcdir)/test_extent.in
        $(TESTENV) ./test_extent < $(srcdir)/test_extent.in > test_extent.out
 
-check:: test_extent.out
+fullcheck check:: test_extent.out
        $(Q) if cmp -s test_extent.out $(srcdir)/test_extent.in ; then \
                echo "Test succeeded." ; \
        else \
index c130f4abe93cab7ae16dd28880c8b2c200659529..57117ac86633729610f0b2d7738cadbb2d4ea792 100644 (file)
@@ -41,8 +41,10 @@ always_run:
 @ifGNUmake@TESTS=$(wildcard $(srcdir)/[a-z]_*)
 @ifNotGNUmake@TESTS != echo $(srcdir)/[a-z]_*
 
+SKIP_SLOW_TESTS=--skip-slow-tests
+
 $(TESTS):: test_one always_run
-       @./test_one $@
+       @./test_one $(SKIP_SLOW_TESTS) $@
 
 foo:
        echo $(TESTS)
@@ -57,6 +59,9 @@ test_post: test_pre $(TESTS)
 
 check:: test_pre test_post test_script
 
+fullcheck::
+       $(MAKE) SKIP_SLOW_TESTS= check
+
 check-failed: $(basename $(wildcard *.failed))
        @$(srcdir)/test_post
 
diff --git a/tests/f_large_dir/is_slow_test b/tests/f_large_dir/is_slow_test
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/tests/f_mmp/is_slow_test b/tests/f_mmp/is_slow_test
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/tests/f_mmp_garbage/is_slow_test b/tests/f_mmp_garbage/is_slow_test
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/tests/r_64bit_big_expand/is_slow_test b/tests/r_64bit_big_expand/is_slow_test
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/tests/r_ext4_big_expand/is_slow_test b/tests/r_ext4_big_expand/is_slow_test
new file mode 100644 (file)
index 0000000..e69de29
index fb30e57826d48298e0744eda34f96da9b1fa3b39..35465b6a73758dbd0ffa88df7738369cb41dc74c 100644 (file)
@@ -13,6 +13,10 @@ case "$1" in
        export USE_VALGRIND="valgrind --sim-hints=lax-ioctls --leak-check=full --show-reachable=yes --log-file=/tmp/valgrind-%p.log"
        shift;
        ;;
+    --skip-slow-tests)
+       SKIP_SLOW_TESTS=yes
+       shift;
+       ;;
 esac
 
 case "$1" in
@@ -49,6 +53,11 @@ else
        test_description=
 fi
 
+if [ -n "$SKIP_SLOW_TESTS" -a -f $test_dir/is_slow_test ]; then
+    echo "$test_name: $test_description: skipped (slow test)"
+    exit 0
+fi
+
 rm -f $test_name.ok $test_name.failed
 #echo -e -n "$test_name: $test_description:\r"