diff --git a/tests/Makefile.boilerplate b/tests/Makefile.boilerplate index 73358bee5..8d2f41d0d 100644 --- a/tests/Makefile.boilerplate +++ b/tests/Makefile.boilerplate @@ -12,7 +12,7 @@ include ../Makefile.messages # You can override which c-xref to run, but each test need to define ARGUMENTS # and can use $(COMMAND) -CXREF = ../../src/c-xref +CXREF = ../../src/c-xref -xrefrc .c-xrefrc -p $(CURDIR) COMMAND = $(CXREF) $(ARGUMENTS) # Define the test name as the directory name diff --git a/tests/test_add_parameter/Makefile b/tests/test_add_parameter/Makefile index 13c7a2024..43a8673f5 100644 --- a/tests/test_add_parameter/Makefile +++ b/tests/test_add_parameter/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-add-param -olcxparnum=2 -rfct-param1=int\ arg -rfct-param2=42 -olcursor=17 $(CURDIR)/source.c +ARGUMENTS = -xrefactory-II -refactory -rfct-add-param -olcxparnum=2 -rfct-param1=int\ arg -rfct-param2=42 -olcursor=17 $(CURDIR)/source.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_add_parameter_after_void/Makefile b/tests/test_add_parameter_after_void/Makefile index ba52764a9..a6bc4ff04 100644 --- a/tests/test_add_parameter_after_void/Makefile +++ b/tests/test_add_parameter_after_void/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-add-param -olcxparnum=2 -rfct-param1="int arg" -rfct-param2=42 -olcursor=16 $(CURDIR)/hello.c +ARGUMENTS = -xrefactory-II -refactory -rfct-add-param -olcxparnum=2 -rfct-param1="int arg" -rfct-param2=42 -olcursor=16 $(CURDIR)/hello.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_add_parameter_outside_range/Makefile b/tests/test_add_parameter_outside_range/Makefile index 737131980..c22d65000 100644 --- a/tests/test_add_parameter_outside_range/Makefile +++ b/tests/test_add_parameter_outside_range/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -refactory -rfct-add-param -olcxparnum=14 -rfct-param1="int arg" -rfct-param2=42 -olcursor=70 $(CURDIR)/source.c +ARGUMENTS = -xrefactory-II -refactory -rfct-add-param -olcxparnum=14 -rfct-param1="int arg" -rfct-param2=42 -olcursor=70 $(CURDIR)/source.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_add_parameter_to_empty/Makefile b/tests/test_add_parameter_to_empty/Makefile index a476701d0..21fee6a44 100644 --- a/tests/test_add_parameter_to_empty/Makefile +++ b/tests/test_add_parameter_to_empty/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-add-param -olcxparnum=1 -rfct-param1="int arg" -rfct-param2=42 -olcursor=16 $(CURDIR)/hello.c +ARGUMENTS = -xrefactory-II -refactory -rfct-add-param -olcxparnum=1 -rfct-param1="int arg" -rfct-param2=42 -olcursor=16 $(CURDIR)/hello.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_add_parameter_to_void/Makefile b/tests/test_add_parameter_to_void/Makefile index a476701d0..21fee6a44 100644 --- a/tests/test_add_parameter_to_void/Makefile +++ b/tests/test_add_parameter_to_void/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-add-param -olcxparnum=1 -rfct-param1="int arg" -rfct-param2=42 -olcursor=16 $(CURDIR)/hello.c +ARGUMENTS = -xrefactory-II -refactory -rfct-add-param -olcxparnum=1 -rfct-param1="int arg" -rfct-param2=42 -olcursor=16 $(CURDIR)/hello.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_bracketed_include/Makefile b/tests/test_bracketed_include/Makefile index 6252edbaa..27d43ac48 100644 --- a/tests/test_bracketed_include/Makefile +++ b/tests/test_bracketed_include/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -create -xrefrc .c-xrefrc -p $(CURDIR) -log=log source.c +ARGUMENTS = -create -log=log source.c $(TEST): .c-xrefrc $(COMMAND) > output.tmp diff --git a/tests/test_c_parsing/Makefile b/tests/test_c_parsing/Makefile index 0da83a871..d5ac22948 100644 --- a/tests/test_c_parsing/Makefile +++ b/tests/test_c_parsing/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc .c-xrefrc test_source/hello.c +ARGUMENTS = test_source/hello.c # This test will always succeed unless c-xref fails $(TEST): clean diff --git a/tests/test_cexercise_browsing/Makefile b/tests/test_cexercise_browsing/Makefile index cb4875b43..5fb52b0e0 100644 --- a/tests/test_cexercise_browsing/Makefile +++ b/tests/test_cexercise_browsing/Makefile @@ -10,7 +10,7 @@ $(TEST): CXrefs trace: EXTRA = \'-trace\' trace: $(TEST) -ARGUMENTS = -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -create +ARGUMENTS = -create CXrefs: .c-xrefrc @# Sources are not here but in subdir diff --git a/tests/test_cexercise_rename_2_function/Makefile b/tests/test_cexercise_rename_2_function/Makefile index 8f6a49cef..a0f556ee1 100644 --- a/tests/test_cexercise_rename_2_function/Makefile +++ b/tests/test_cexercise_rename_2_function/Makefile @@ -1,5 +1,6 @@ include ../Makefile.boilerplate + $(TEST): .c-xrefrc @-$(EDIT_SERVER_DRIVER) commands.input $(EXTRA) > output.tmp @$(NORMALIZE) output.tmp > output diff --git a/tests/test_cgram_coverage/Makefile b/tests/test_cgram_coverage/Makefile index 50b183d63..405d9fbc2 100644 --- a/tests/test_cgram_coverage/Makefile +++ b/tests/test_cgram_coverage/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc .c-xrefrc cgram_coverage.c -o $(TEST).log +ARGUMENTS = cgram_coverage.c -o $(TEST).log $(TEST): rm -rf output $@.log CXrefs diff --git a/tests/test_compound_literal/Makefile b/tests/test_compound_literal/Makefile index 84be2ab6c..0372855ee 100644 --- a/tests/test_compound_literal/Makefile +++ b/tests/test_compound_literal/Makefile @@ -1,6 +1,6 @@ include ../Makefile.boilerplate -ARGUMENTS = -p $(CURDIR) -xrefrc .c-xrefrc test_sources/source.c -o output +ARGUMENTS = test_sources/source.c -o output $(TEST): @$(COMMAND) diff --git a/tests/test_create_references_in_subdir/Makefile b/tests/test_create_references_in_subdir/Makefile index 1cc512a01..ab7618ec1 100644 --- a/tests/test_create_references_in_subdir/Makefile +++ b/tests/test_create_references_in_subdir/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -o output +ARGUMENTS = -xrefactory-II -create -errors -o output $(TEST): .c-xrefrc @sed -e 's:/CXrefs$$:/CXrefs/subdir:' .c-xrefrc > .c-xrefrc.tmp diff --git a/tests/test_delete_no_parameter/Makefile b/tests/test_delete_no_parameter/Makefile index 54ac79de0..a7aa3e9df 100644 --- a/tests/test_delete_no_parameter/Makefile +++ b/tests/test_delete_no_parameter/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-del-param -olcxparnum=1 -olcursor=36 $(CURDIR)/hello.c +ARGUMENTS = -xrefactory-II -refactory -rfct-del-param -olcxparnum=1 -olcursor=36 $(CURDIR)/hello.c $(TEST): .c-xrefrc $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_delete_void_parameter/Makefile b/tests/test_delete_void_parameter/Makefile index ab532e049..6c7aaee1d 100644 --- a/tests/test_delete_void_parameter/Makefile +++ b/tests/test_delete_void_parameter/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-del-param -olcxparnum=1 -olcursor=17 $(CURDIR)/hello.c +ARGUMENTS = -xrefactory-II -refactory -rfct-del-param -olcxparnum=1 -olcursor=17 $(CURDIR)/hello.c $(TEST): .c-xrefrc $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_edit_server_test_example/Makefile b/tests/test_edit_server_test_example/Makefile index 13b1a3094..03c8bab8f 100644 --- a/tests/test_edit_server_test_example/Makefile +++ b/tests/test_edit_server_test_example/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -$(TEST): CXrefs +$(TEST): .c-xrefrc @$(EDIT_SERVER_DRIVER) commands.input $(EXTRA) > output.tmp @$(NORMALIZE) output.tmp > output $(VERIFY) @@ -9,9 +9,6 @@ $(TEST): CXrefs trace: EXTRA = \'-trace\' trace: $(TEST) -CXrefs: - @$(CXREF) -xrefrc=.c-xrefrc test_source -o $@.log - clean: rm -rf .c-xrefrc CXrefs output.log output.tmp diff --git a/tests/test_extract_out_argument/Makefile b/tests/test_extract_out_argument/Makefile index 4d9b003cb..acda2baa3 100644 --- a/tests/test_extract_out_argument/Makefile +++ b/tests/test_extract_out_argument/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -refactory -rfct-extract-function -olmark=50 -olcursor=80 $(CURDIR)/source.c +ARGUMENTS = -xrefactory-II -refactory -rfct-extract-function -olmark=50 -olcursor=80 $(CURDIR)/source.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_full_update/Makefile b/tests/test_full_update/Makefile index 167469d70..128a2dfdf 100644 --- a/tests/test_full_update/Makefile +++ b/tests/test_full_update/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc $(CURDIR)/.c-xrefrc -fullupdate -p $(CURDIR) +ARGUMENTS = -fullupdate $(TEST): CXrefs $(COMMAND) > output.tmp diff --git a/tests/test_generate_cxrefs/Makefile b/tests/test_generate_cxrefs/Makefile index 983962d34..7d7a96afe 100644 --- a/tests/test_generate_cxrefs/Makefile +++ b/tests/test_generate_cxrefs/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc .c-xrefrc -p $(CURDIR) -o output.tmp src +ARGUMENTS = -xrefactory-II -create -errors -o output.tmp src $(TEST): c_xrefrc_for_single_cxref_file -rm CXrefs diff --git a/tests/test_get_environment_value/Makefile b/tests/test_get_environment_value/Makefile index 2cde67aa7..28d5346cb 100644 --- a/tests/test_get_environment_value/Makefile +++ b/tests/test_get_environment_value/Makefile @@ -10,7 +10,7 @@ trace: EXTRA = \'-trace\' trace: $(TEST) CXrefs: - @$(CXREF) -xrefrc=.c-xrefrc test_source -o cxrefs.log + @$(CXREF) test_source -o cxrefs.log clean: rm -rf .c-xrefrc CXrefs output* diff --git a/tests/test_globalunused/Makefile b/tests/test_globalunused/Makefile index 4d4458f7f..e01918a5c 100644 --- a/tests/test_globalunused/Makefile +++ b/tests/test_globalunused/Makefile @@ -9,7 +9,7 @@ $(TEST): CXrefs trace: EXTRA = \'-trace\' trace: $(TEST) -ARGUMENTS = -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -create +ARGUMENTS = -create CXrefs: .c-xrefrc @$(COMMAND) -o $(TEST).log diff --git a/tests/test_include_brackets/Makefile b/tests/test_include_brackets/Makefile index 5a02b15c2..c19ab3580 100644 --- a/tests/test_include_brackets/Makefile +++ b/tests/test_include_brackets/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc .c-xrefrc -p $(CURDIR) $(TRACE) source.c -log=log -o output.tmp +ARGUMENTS = -xrefactory-II -create -errors $(TRACE) source.c -log=log -o output.tmp $(TEST): .c-xrefrc $(COMMAND) > out diff --git a/tests/test_include_macro/Makefile b/tests/test_include_macro/Makefile index 09cc83146..e9f4abc96 100644 --- a/tests/test_include_macro/Makefile +++ b/tests/test_include_macro/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc .c-xrefrc -p $(CURDIR) $(TRACE) source.c -log=log -o output.tmp $(EXTRAS) +ARGUMENTS = -xrefactory-II -create -errors $(TRACE) source.c -log=log -o output.tmp $(EXTRAS) $(TEST): .c-xrefrc $(COMMAND) > out diff --git a/tests/test_include_next/Makefile b/tests/test_include_next/Makefile index 7096cb17d..cf997e396 100644 --- a/tests/test_include_next/Makefile +++ b/tests/test_include_next/Makefile @@ -20,7 +20,7 @@ include ../Makefile.boilerplate # So here we add the subdirectory "next" where there also is a "include.h". In the one in the top # directory we want to include that one using "#include_next stdint.h". -ARGUMENTS = -create -xrefrc .c-xrefrc -p $(CURDIR) -I path1 -I path2 source.c -xrefactory-II -errors -o output.tmp +ARGUMENTS = -create -I path1 -I path2 source.c -xrefactory-II -errors -o output.tmp $(TEST): .c-xrefrc $(COMMAND) > out diff --git a/tests/test_initializer_parsing/Makefile b/tests/test_initializer_parsing/Makefile index 02076df50..24117de9b 100644 --- a/tests/test_initializer_parsing/Makefile +++ b/tests/test_initializer_parsing/Makefile @@ -1,8 +1,8 @@ include ../Makefile.boilerplate -ARGUMENTS = initializer_parsing.c -xrefrc .c-xrefrc -refs $(CURDIR)/CXrefs -o output +ARGUMENTS = initializer_parsing.c -o output -$(TEST): +$(TEST): .c-xrefrc @$(COMMAND) @# Check in the xrefs for 'E0' - which means? @grep "E0" CXrefs/* | grep 'f2l2cr22u16l7cr18l5cr13cr23l3cr7cr13cr24l3cr25l7cr' > /dev/null ; \ diff --git a/tests/test_java_not_supported/Makefile b/tests/test_java_not_supported/Makefile index 68da1236c..de09e8432 100644 --- a/tests/test_java_not_supported/Makefile +++ b/tests/test_java_not_supported/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-add-param -olcxparnum=2 -rfct-param1=int\ arg -rfct-param2=42 -olcursor=17 $(CURDIR)/file.java +ARGUMENTS = -xrefactory-II -refactory -rfct-add-param -olcxparnum=2 -rfct-param1=int\ arg -rfct-param2=42 -olcursor=17 $(CURDIR)/file.java $(TEST): clean -$(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_lex_operators/Makefile b/tests/test_lex_operators/Makefile index 80d046926..47fefa366 100644 --- a/tests/test_lex_operators/Makefile +++ b/tests/test_lex_operators/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc .c-xrefrc -create operators.c -o log +ARGUMENTS = -create operators.c -o log $(TEST): @rm -rf output $@.log CXrefs Xrefs diff --git a/tests/test_move_parameter_with_void_pointer/Makefile b/tests/test_move_parameter_with_void_pointer/Makefile index b05783424..ced7341c2 100644 --- a/tests/test_move_parameter_with_void_pointer/Makefile +++ b/tests/test_move_parameter_with_void_pointer/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -refactory -xrefrc $(CURDIR)/.c-xrefrc -p $(CURDIR) -rfct-move-param -olcxparnum=1 -olcxparnum2=2 -olcursor=17 $(CURDIR)/source.c +ARGUMENTS = -xrefactory-II -refactory -rfct-move-param -olcxparnum=1 -olcxparnum2=2 -olcursor=17 $(CURDIR)/source.c $(TEST): clean $(COMMAND) -log=log $(EXTRA) > output.tmp diff --git a/tests/test_multiline_string_lexing/Makefile b/tests/test_multiline_string_lexing/Makefile index e8661e5bd..ffa6eedbc 100644 --- a/tests/test_multiline_string_lexing/Makefile +++ b/tests/test_multiline_string_lexing/Makefile @@ -1,6 +1,6 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc .c-xrefrc source.c +ARGUMENTS = source.c # This test will always succeed unless c-xref fails, it used to hang on unterminated macro $(TEST): clean diff --git a/tests/test_no_errors_on_communication_channel/Makefile b/tests/test_no_errors_on_communication_channel/Makefile index c17cc13b6..ca2afd30c 100644 --- a/tests/test_no_errors_on_communication_channel/Makefile +++ b/tests/test_no_errors_on_communication_channel/Makefile @@ -18,7 +18,7 @@ trace: EXTRA = \'-trace\' trace: $(TEST) CXrefs: - @$(CXREF) -xrefrc=.c-xrefrc test_source -o cxrefs.log + @$(CXREF) test_source -o cxrefs.log clean: rm -rf .c-xrefrc CXrefs output* *.log diff --git a/tests/test_old_style_func/Makefile b/tests/test_old_style_func/Makefile index 5a02b15c2..fda7d28d3 100644 --- a/tests/test_old_style_func/Makefile +++ b/tests/test_old_style_func/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc .c-xrefrc -p $(CURDIR) $(TRACE) source.c -log=log -o output.tmp +ARGUMENTS = -xrefactory-II -create -errors $(TRACE) source.c -log=log -o output.tmp $(TEST): .c-xrefrc $(COMMAND) > out @@ -18,3 +18,4 @@ trace: $(TEST) clean: rm -rf .c-xrefrc CXrefs output.log output.tmp + diff --git a/tests/test_pragma_once/Makefile b/tests/test_pragma_once/Makefile index 8538bb95b..72b477477 100644 --- a/tests/test_pragma_once/Makefile +++ b/tests/test_pragma_once/Makefile @@ -1,11 +1,8 @@ -# Automated tests for pragma once -# Verification is just that it can parse "pragma once" and generate CXrefs - include ../Makefile.boilerplate -$(TEST): +$(TEST): .c-xrefrc @rm -rf $(TEST).log CXrefs /tmp/c-xref*.log - @../../src/c-xref include1.h include2.h -xrefrc .c-xrefrc -refs "$(CURDIR)/CXrefs" -o $(TEST).log + @$(CXREF) include1.h include2.h -o $(TEST).log @grep include1.h CXrefs/XFiles > /dev/null ; \ if [ $$? -ne 0 ] ; then \ $(FAIL) ; \ diff --git a/tests/test_process_yacc/Makefile b/tests/test_process_yacc/Makefile index 6da8cbeee..60eee2625 100644 --- a/tests/test_process_yacc/Makefile +++ b/tests/test_process_yacc/Makefile @@ -4,20 +4,10 @@ include ../Makefile.boilerplate YACC = ../../byacc-1.9/yacc -# Note to self: -# The CXrefs file contains all references in a format that I have yet -# to completely decipher, but here are some details: -# -# A line for a file starts with an identification: '1541f' -# A line for a symbol starts with a field that includes the symbol name: '5/func' -# such a line also includes all references including file reference, line and char: -# '1541f9l17cr' means file 1541, line 9, character 17 -# - -$(TEST): $(YACC) +$(TEST): $(YACC) .c-xrefrc @rm -rf $(TEST).log CXrefs @$(YACC) file.y - @../../src/c-xref *.[cy] -xrefrc .c-xrefrc -refs "$(CURDIR)/CXrefs" -o $(TEST).log + @$(CXREF) *.[cy] -o $(TEST).log @# Get the "symbol" for the yacc-file from the CXrefs and use it @# to find the reference to func from the .y file @f=`grep process_yacc/file.y CXrefs/* | awk '{print $$1}'` ; \ diff --git a/tests/test_prune_option/Makefile b/tests/test_prune_option/Makefile index 6ea13fd2a..e75a3ee26 100644 --- a/tests/test_prune_option/Makefile +++ b/tests/test_prune_option/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc .c-xrefrc -p $(CURDIR) $(TRACE) -log=log -o output.tmp -prune pruned +ARGUMENTS = -xrefactory-II -create -errors $(TRACE) -log=log -o output.tmp -prune pruned $(TEST): .c-xrefrc $(COMMAND) > out diff --git a/tests/test_rename_macro/Makefile b/tests/test_rename_macro/Makefile index bb37ee1db..77db8a10c 100644 --- a/tests/test_rename_macro/Makefile +++ b/tests/test_rename_macro/Makefile @@ -1,11 +1,8 @@ include ../Makefile.boilerplate -ARGS = -xrefrc .c-xrefrc -xrefactory-II -p $(CURDIR) -refactory -rfct-rename -renameto=VVV -olcursor=6790 main.c +ARGUMENTS = -xrefactory-II -refactory -rfct-rename -renameto=VVV -olcursor=6790 main.c $(TEST): - ../../src/c-xref $(ARGS) -o output.tmp > log + $(COMMAND) -o output.tmp > log $(NORMALIZE) output.tmp > output $(VERIFY) - -debug: - gdb --args ../../src/c-xref $(ARGS) diff --git a/tests/test_simple_block/Makefile b/tests/test_simple_block/Makefile index 5a02b15c2..c19ab3580 100644 --- a/tests/test_simple_block/Makefile +++ b/tests/test_simple_block/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefactory-II -create -errors -xrefrc .c-xrefrc -p $(CURDIR) $(TRACE) source.c -log=log -o output.tmp +ARGUMENTS = -xrefactory-II -create -errors $(TRACE) source.c -log=log -o output.tmp $(TEST): .c-xrefrc $(COMMAND) > out diff --git a/tests/test_simple_push/Makefile b/tests/test_simple_push/Makefile index ef2a884d8..ef363aa94 100644 --- a/tests/test_simple_push/Makefile +++ b/tests/test_simple_push/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -$(TEST): CXrefs +$(TEST): .c-xrefrc $(EDIT_SERVER_DRIVER) commands.input $(EXTRA) > output.tmp $(NORMALIZE) output.tmp > output $(VERIFY) @@ -9,9 +9,6 @@ $(TEST): CXrefs trace: EXTRA = \'-trace\' trace: $(TEST) -CXrefs: - @$(CXREF) -xrefrc=.c-xrefrc test_source -o cxrefs.log - clean: rm -rf .c-xrefrc CXrefs output* diff --git a/tests/test_simple_xrefs/Makefile b/tests/test_simple_xrefs/Makefile index 94ba70933..9e720d195 100644 --- a/tests/test_simple_xrefs/Makefile +++ b/tests/test_simple_xrefs/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc .c-xrefrc single_int*.c -o log +ARGUMENTS = single_int*.c -o log $(TEST): @rm -rf output $@.log CXrefs Xrefs diff --git a/tests/test_single_reference_file/Makefile b/tests/test_single_reference_file/Makefile index cc0bba9ba..88cf933a7 100644 --- a/tests/test_single_reference_file/Makefile +++ b/tests/test_single_reference_file/Makefile @@ -1,7 +1,7 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc -refnum=1 .c-xrefrc single_int*.c -o log +ARGUMENTS = -refnum=1 single_int*.c -o log $(TEST): @rm -rf output $@.log CXrefs Xrefs diff --git a/tests/test_standard_includes/Makefile b/tests/test_standard_includes/Makefile index 6e8223839..7506cdbad 100644 --- a/tests/test_standard_includes/Makefile +++ b/tests/test_standard_includes/Makefile @@ -5,7 +5,7 @@ include ../Makefile.boilerplate $(TEST): @rm -rf C-Xrefs $(TEST).log - @../../src/c-xref -xrefrc .c-xrefrc -refs $(CURDIR)/C-Xrefs standard_includes.c -o standard_includes.log + @$(COMMAND) standard_includes.c -o standard_includes.log @# We are using the fact that it *can* find stdbool.h proof that it looks in standard dirs @grep "can't open file stdbool.h" standard_includes.log > /dev/null ; \ if [ $$? -ne 1 ] ; then \ diff --git a/tests/test_uint32_t/Makefile b/tests/test_uint32_t/Makefile index 888b39396..7f21df817 100644 --- a/tests/test_uint32_t/Makefile +++ b/tests/test_uint32_t/Makefile @@ -18,7 +18,7 @@ include ../Makefile.boilerplate # gcc -E source.c -ARGUMENTS = -create -xrefrc .c-xrefrc -p $(CURDIR) $(TRACE) uint32.c -errors -log=log +ARGUMENTS = -create $(TRACE) uint32.c -errors -log=log $(TEST): .c-xrefrc $(COMMAND) 2> output.tmp > out diff --git a/tests/test_update/Makefile b/tests/test_update/Makefile index e2e427fd3..0c066306f 100644 --- a/tests/test_update/Makefile +++ b/tests/test_update/Makefile @@ -1,11 +1,11 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc $(CURDIR)/.c-xrefrc -update -p $(CURDIR)/cexercise -trace -log=log +ARGUMENTS = -trace -log=log $(TEST): CXrefs touch cexercise/* - $(COMMAND) > output.tmp + $(COMMAND) -update > output.tmp $(NORMALIZE) output.tmp > output $(VERIFY) diff --git a/tests/test_yacc_parsing/Makefile b/tests/test_yacc_parsing/Makefile index 72c1f8001..505535cd4 100644 --- a/tests/test_yacc_parsing/Makefile +++ b/tests/test_yacc_parsing/Makefile @@ -1,9 +1,9 @@ include ../Makefile.boilerplate -ARGUMENTS = -xrefrc .c-xrefrc simple_grammar.y -o $(TEST).log +ARGUMENTS = simple_grammar.y -o $(TEST).log -$(TEST): +$(TEST): .c-xrefrc @rm -rf output $@.log CXrefs @$(COMMAND) @echo "Tests in '$(TEST)': $(shell tput setaf 3)No tests, just executing$(shell tput sgr0)"