History

tests2: Build executables as well

The individual tests in tests2 are checked only with -run. Build (and check) executables as well, to test also building executables.

Michael Matz committed 12 years ago

Commit 3d18c9a1 parent 0688afd1 file · +6 −1Browse files

Unified · Split

tests/tests2/Makefile+6−1
@@ -94,13 +94,18 @@ endif · 93 unmodified lines
9494 @if [ "x`echo $* | grep args`" != "x" ]; \
9595 then $(TCC) $< -norunsrc -run $(notdir $<) - arg1 arg2 arg3 arg4 >$*.output 2>&1; \
9696 else $(TCC) -run $< >$*.output 2>&1; \
97+ ($(TCC) -o $*.exe $< -lm && ./$*.exe) >$*.output2 2>&1; \
9798 fi || true
9899 @if diff -bu $(<:.c=.expect) $*.output ; \
99100 then rm -f $*.output; \
100101 else exit 1; \
101102 fi
103+ @if test -f $*.output2; then if diff -bu $(<:.c=.expect) $*.output2 ; \
104+ then rm -f $*.output2; \
105+ else exit 1; \
106+ fi; fi
102107
103108 all test: $(TESTS)
104109
105110 clean:
106− rm -vf fred.txt *.output
111+ rm -vf fred.txt *.output* *.exe

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t