4 COMPILER_FLAGS = /libpath:../class/lib/default/ /imports:System
5 INTERNAL_MBAS = $(TEST_RUNTIME) --debug ../mbas/mbas.exe --stacktrace $(COMPILER_FLAGS)
6 #INTERNAL_MBAS = vbc $(COMPILER_FLAGS)
9 # removed this cause INTERNAL_MBAS now getting set in
10 # rules.make which is conflicting with this instance of
12 #include ../build/rules.make
14 DISTFILES = README.tests $(wildcard *.vb)
16 # We don't want debugging info :-)
19 # include the test cases source file
22 # A test is a 'no pass' if it fails on either windows or linux
26 all-local install-local:
28 # compilation is part of the testing too, so we don't actually
29 # do anything in test-local.
34 run-test-local: test-compiler-jit
37 test-compiler-jit: test-compiler-jit-real test-compiler-jit-ngtive_compile \
38 test-compiler-jit-ngtive_run
41 test-compiler-jit-real:
42 @rm -f *.exe *.out ; \
43 /bin/echo "********** Positive Tests ************" > results.out; \
44 /bin/echo "********** Positive Tests ************" ; \
45 for i in $(TEST_SOURCES) ; do \
46 /bin/echo -n -e "========================\n$$i: " >> results.out; \
47 /bin/echo -n "$$i: "; \
48 if $(INTERNAL_MBAS) $$i.vb 1>output ; then \
49 /bin/echo -n "COMPILED OK : " >> results.out; \
50 /bin/echo -n "COMPILED OK : " ;\
53 /bin/echo -n -e "FAILED COMPILATION\n---\n" >> results.out; \
54 cat output >> results.out; \
55 /bin/echo FAILED COMPILATION ; \
58 if $(TEST_RUNTIME) ./$$i.exe 1>output ; then \
59 /bin/echo "EXECUTED OK" >> results.out; \
60 /bin/echo "EXECUTED OK" ; \
62 /bin/echo -n -e "$$i : FAILED AT RUNTIME\n---\n" >> results.out; \
63 cat output >> results.out; \
64 /bin/echo "FAILED AT RUNTIME"; \
66 rm -f ./$$i.exe output; \
68 /bin/echo "========================" >> results.out
70 test-compiler-jit-ngtive_compile:
72 /bin/echo "********** Negative Compilation Tests ************" >> results.out; \
73 /bin/echo "********** Negative Compilation Tests ************" ; \
74 for i in $(TEST_NGTIVE_COMPILATION_SOURCES) ; do \
75 /bin/echo -n -e "========================\n$$i: " >> results.out; \
76 /bin/echo -n "$$i: "; \
77 if $(INTERNAL_MBAS) $$i.vb > /dev/null ; then \
78 /bin/echo "UNEXPECTED BEHAVIOUR" >> results.out; \
79 /bin/echo UNEXPECTED BEHAVIOUR ; \
81 /bin/echo OK >> results.out; \
85 rm -f ./$$i.exe output; \
88 test-compiler-jit-ngtive_run:
90 /bin/echo "********** Negative Execution Tests ************" >> results.out; \
91 /bin/echo "********** Negative Execution Tests ************" ; \
92 for i in $(TEST_NGTIVE_RUNTIME_SOURCES) ; do \
93 /bin/echo -n "$$i: "; \
94 if $(INTERNAL_MBAS) $$i.vb 1>output ; then \
97 /bin/echo -n -e "\n$$i : FAILED COMPILATION\n " >> results.out; \
98 cat output >> results.out; \
99 /bin/echo -n -e "\n========================" >> results.out; \
100 /bin/echo FAILED COMPILATION ; \
103 if $(TEST_RUNTIME) ./$$i.exe > /dev/null ; then \
104 /bin/echo -n -e "\n$$i : UNEXPECTED BEHAVIOUR\n " >> results.out; \
105 /bin/echo -n -e "\n========================" >> results.out; \
106 /bin/echo UNEXPECTED BEHAVIOUR ; \
108 /bin/echo OK >> results.out; \
111 rm -f ./$$i.exe output; \