diff options
author | Will Estes <westes575@gmail.com> | 2014-06-04 16:25:00 -0400 |
---|---|---|
committer | Will Estes <westes575@gmail.com> | 2014-11-12 05:14:26 -0500 |
commit | cd1838ef1f54613f932dde07a0f44f5a0194f736 (patch) | |
tree | 05be07435a0406ef0f00d6601e0b790e314eb920 /tests | |
parent | ccaa2785062dec7fe2d0ddc7a6a3f58b77e4c338 (diff) |
refactor debug_r test for new test suite layout
Diffstat (limited to 'tests')
-rw-r--r-- | tests/.gitignore | 2 | ||||
-rw-r--r-- | tests/Makefile.am | 7 | ||||
-rw-r--r-- | tests/debug_r.l (renamed from tests/test-debug-r/scanner.l) | 2 | ||||
-rw-r--r-- | tests/debug_r.txt (renamed from tests/test-debug-r/test.input) | 0 | ||||
-rw-r--r-- | tests/test-debug-r/.gitignore | 9 | ||||
-rw-r--r-- | tests/test-debug-r/Makefile.am | 44 |
6 files changed, 8 insertions, 56 deletions
diff --git a/tests/.gitignore b/tests/.gitignore index 9fa9f29..fad80d4 100644 --- a/tests/.gitignore +++ b/tests/.gitignore @@ -24,3 +24,5 @@ ccl ccl.c debug_nr debug_nr.c +debug_r +debug_r.c diff --git a/tests/Makefile.am b/tests/Makefile.am index 053f115..85b3e66 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -36,7 +36,8 @@ check_PROGRAMS = \ bison_yylloc \ bison_yylval \ ccl \ - debug_nr + debug_nr \ + debug_r alloc_extra_SOURCES = alloc_extra.l array_nr_SOURCES = array_nr.l @@ -48,6 +49,7 @@ bison_yylloc_SOURCES = bison_yylloc_scanner.l bison_yylloc_parser.y bison_yylloc bison_yylval_SOURCES = bison_yylval_scanner.l bison_yylval_parser.y bison_yylval_main.c ccl_SOURCES = ccl.l debug_nr_SOURCES = debug_nr.l +debug_r_SOURCES = debug_r.l BUILT_SOURCES = \ bison_nr_scanner.h \ @@ -72,7 +74,8 @@ basic_nr.txt \ bison_yylval_scanner.h \ bison_yylval.txt \ ccl.txt \ - debug_nr.txt + debug_nr.txt \ + debug_r.txt # specify how to process .l files in order to test the flex built by make all diff --git a/tests/test-debug-r/scanner.l b/tests/debug_r.l index 14a335e..c6982bf 100644 --- a/tests/test-debug-r/scanner.l +++ b/tests/debug_r.l @@ -29,7 +29,7 @@ %} -%option 8bit outfile="scanner.c" prefix="test" +%option 8bit prefix="test" %option nounput nomain noyywrap %option warn debug reentrant diff --git a/tests/test-debug-r/test.input b/tests/debug_r.txt index 8d6476c..8d6476c 100644 --- a/tests/test-debug-r/test.input +++ b/tests/debug_r.txt diff --git a/tests/test-debug-r/.gitignore b/tests/test-debug-r/.gitignore deleted file mode 100644 index d2b0c7c..0000000 --- a/tests/test-debug-r/.gitignore +++ /dev/null @@ -1,9 +0,0 @@ -Makefile -Makefile.in -parser.c -parser.h -scanner.c -TEMPLATE -OUTPUT -.deps -test-debug-r diff --git a/tests/test-debug-r/Makefile.am b/tests/test-debug-r/Makefile.am deleted file mode 100644 index 6496892..0000000 --- a/tests/test-debug-r/Makefile.am +++ /dev/null @@ -1,44 +0,0 @@ -# This file is part of flex. - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: - -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. - -# Neither the name of the University nor the names of its contributors -# may be used to endorse or promote products derived from this software -# without specific prior written permission. - -# THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR -# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED -# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -# PURPOSE. - - -FLEX = $(top_builddir)/flex - -EXTRA_DIST = scanner.l test.input -CLEANFILES = scanner.c $(testname)$(EXEEXT) OUTPUT $(OBJS) -OBJS = scanner.o - -AM_CPPFLAGS = -I$(srcdir) -I$(top_srcdir) -I$(top_builddir) -#LDFLAGS = $(top_srcdir)/libfl.a - -testname = test-debug-r - -scanner.c: $(srcdir)/scanner.l - $(FLEX) $(LFLAGS) $< - -$(testname)$(EXEEXT): $(OBJS) - $(CC) $(CFLAGS) -o $@ $(LDFLAGS) $(OBJS) $(LOADLIBES) - -test: $(testname)$(EXEEXT) - ./$(testname)$(EXEEXT) < $(srcdir)/test.input - -.c.o: - $(CC) -c -o $@ $(AM_CPPFLAGS) $(CPPFLAGS) $(CFLAGS) $< |