]> granicus.if.org Git - flex/commitdiff
use automake parallel test suite option to build test suite
authorWill Estes <westes575@gmail.com>
Tue, 22 Apr 2014 22:40:51 +0000 (18:40 -0400)
committerWill Estes <westes575@gmail.com>
Wed, 12 Nov 2014 10:14:25 +0000 (05:14 -0500)
tests/Makefile.am

index 25d8b0c73ae756d23a83fba819b7f6c95db7284f..27f42276b57a1f37254fad3372bcbdfd6b7e9bfa 100644 (file)
 EXTRA_DIST = \
        README
 
-dist_noinst_SCRIPTS = \
-       create-test
+TESTS = $(check_PROGRAMS)
 
-DIST_SUBDIRS = \
-       test-concatenated-options \
-       test-c++-yywrap \
-       test-extended \
-       test-ccl \
-       test-quotes \
-       test-rescan-r \
-       test-rescan-nr \
-       test-basic-nr \
-       test-basic-r \
-       test-bison-yylloc \
-       test-bison-yylval \
-       test-bison-nr \
-       test-multiple-scanners-nr \
-       test-multiple-scanners-r \
-       test-header-nr \
-       test-header-r \
-       test-reject \
-       test-c++-multiple-scanners \
-       test-c++-basic \
-       test-posixly-correct \
-       test-posix \
-       test-mem-r \
-       test-mem-nr \
-       test-debug-nr \
-       test-debug-r \
-       test-lineno-r \
-       test-lineno-nr \
-       test-lineno-trailing \
-       test-linedir-r \
-       TEMPLATE \
-       test-top \
-       test-array-nr \
-       test-array-r \
-       test-c-cpp-nr \
-       test-c-cpp-r \
-       test-include-by-buffer \
-       test-include-by-push \
-       test-include-by-reentrant \
-       test-prefix-nr \
-       test-prefix-r \
-       test-pthread \
-       test-string-nr \
-       test-string-r \
-       test-yyextra \
-       test-alloc-extra \
-       test-noansi-nr \
-       test-noansi-r \
-       test-table-opts
+LOG_COMPILER = $(srcdir)/testwrapper.sh
 
-SUBDIRS = \
-       test-concatenated-options \
-       test-c++-yywrap \
-       test-extended \
-       test-ccl \
-       test-quotes \
-       test-rescan-r \
-       test-rescan-nr \
-       test-basic-nr \
-       test-basic-r \
-       test-bison-yylloc \
-       test-bison-yylval \
-       test-bison-nr \
-       test-multiple-scanners-nr \
-       test-multiple-scanners-r \
-       test-header-nr \
-       test-header-r \
-       test-reject \
-       test-c++-multiple-scanners \
-       test-c++-basic \
-       test-posixly-correct \
-       test-posix \
-       test-mem-r \
-       test-mem-nr \
-       test-debug-nr \
-       test-debug-r \
-       test-lineno-r \
-       test-lineno-nr \
-       test-lineno-trailing \
-       test-linedir-r \
-       test-array-nr \
-       test-array-r \
-       test-c-cpp-nr \
-       test-c-cpp-r \
-       test-include-by-buffer \
-       test-include-by-push \
-       test-include-by-reentrant \
-       test-prefix-nr \
-       test-prefix-r \
-       test-pthread \
-       test-string-nr \
-       test-string-r \
-       test-yyextra \
-       test-alloc-extra \
-       test-noansi-nr \
-       test-noansi-r \
-       test-top \
-       test-table-opts
+check_PROGRAMS = \
+       basic-nr
 
-# clean up before running the test suite so we dont test old builds of test code
+basic_nr_SOURCES = basic-nr.l
 
-check-local: clean
-       NOK=;\
-       NFAIL=;\
-       for dir in $(SUBDIRS) ; do \
-               echo Executing test "$$dir" ; \
-               ( cd "$$dir" && $(MAKE) test  > OUTPUT 2>&1 ) ; \
-               case $$? in \
-                       0 )  echo Test "$$dir" succeeded.; \
-                               NOK=0$$NOK;\
-                               ;; \
-                       * )  echo Test "$$dir" FAILED. See "$$dir"/OUTPUT for details. ; \
-                               NFAIL=0$$NFAIL; \
-                               ;; \
-               esac; \
-       done ; \
-       echo Results: ; \
-       echo Tests succeeded: `echo @ECHO_N@ "$$NOK@ECHO_C@"|wc -c`; \
-       echo Tests FAILED: `echo @ECHO_N@ "$$NFAIL@ECHO_C@"|wc -c` ; \
-       test "$$NFAIL" = ""
+# specify how to process .l files in order to test the flex built by make all
+
+FLEX = $(top_builddir)/src/flex
+
+.l.c:
+       $(FLEX) -o $@ $<