Commit 8feccd84 authored by dbarbera's avatar dbarbera
Browse files

Added test-llvm make rule

parent 738d4c8f
...@@ -6,6 +6,9 @@ test-parse: ...@@ -6,6 +6,9 @@ test-parse:
test-ada: test-ada:
@python tests/test.py test-ada @python tests/test.py test-ada
test-llvm:
@python tests/test.py test-llvm
flake8: flake8:
@echo Generating flake8_report file @echo Generating flake8_report file
flake8 opengeode.py sdlSymbols.py genericSymbols.py ogParser.py AdaGenerator.py Renderer.py Clipboard.py Lander.py ogAST.py undoCommands.py Connectors.py Asn1scc.py Helper.py Statechart.py >flake8_report flake8 opengeode.py sdlSymbols.py genericSymbols.py ogParser.py AdaGenerator.py Renderer.py Clipboard.py Lander.py ogAST.py undoCommands.py Connectors.py Asn1scc.py Helper.py Statechart.py >flake8_report
......
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py og.pr system_structure.pr --check ../../../opengeode.py og.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c og.adb gnatmake -c og.adb
test-llvm:
../../../opengeode.py og.pr system_structure.pr --llvm
llc og.ll
gcc -c og.s
coverage: coverage:
coverage run -p ../../../opengeode.py og.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py og.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py challenge.pr system_structure.pr --check ../../../opengeode.py challenge.pr system_structure.pr --check
...@@ -12,8 +12,14 @@ test-ada: ...@@ -12,8 +12,14 @@ test-ada:
gnatlink -o testcase test.o challenge.ali -lgnat -lm gnatlink -o testcase test.o challenge.ali -lgnat -lm
./testcase | diff expected - ./testcase | diff expected -
test-llvm:
../../../opengeode.py challenge.pr system_structure.pr --llvm
llc challenge.ll
gcc -c challenge.s
coverage: coverage:
coverage run -p ../../../opengeode.py challenge.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py challenge.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr testcase rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py og.pr system_structure.pr --check ../../../opengeode.py og.pr system_structure.pr --check
...@@ -7,13 +7,23 @@ test-ada: ...@@ -7,13 +7,23 @@ test-ada:
../../../opengeode.py --toAda og.pr system_structure.pr ../../../opengeode.py --toAda og.pr system_structure.pr
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c *.adb gnatmake -c *.adb
gcc -c test.c gcc -c test_ada.c
gnatbind -n og.ali gnatbind -n og.ali
gnatlink -o testcase test.o og.ali -lgnat gnatlink -o testcase test_ada.o og.ali -lgnat
./testcase | diff expected - ./testcase | diff expected -
test-llvm:
../../../opengeode.py og.pr system_structure.pr --llvm
llc og.ll
gcc -c og.s
gcc -c test_llvm.c
gcc og.o test_llvm.o -o testcase
./testcase | diff expected -
coverage: coverage:
coverage run -p ../../../opengeode.py og.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py og.pr system_structure.pr --toAda
clean: clean:
rm -rf result *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr testcase rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
#include <math.h>
#include <stdio.h>
extern void adainit(); extern void adainit();
int main() int main() {
{
printf("[C Code] Running test\n");
adainit(); adainit();
return 0; return 0;
} }
extern void og_startup();
int main() {
og_startup();
return 0;
}
\ No newline at end of file
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py trafficlight.pr system_structure.pr --check ../../../opengeode.py trafficlight.pr system_structure.pr --check
...@@ -11,8 +11,14 @@ test-ada: ...@@ -11,8 +11,14 @@ test-ada:
#gnatbind -n trafficlight.ali #gnatbind -n trafficlight.ali
#gnatlink -o testcase test.o trafficlight.ali -lgnat -lm #gnatlink -o testcase test.o trafficlight.ali -lgnat -lm
test-llvm:
../../../opengeode.py trafficlight.pr system_structure.pr --llvm
llc trafficlight.ll
gcc -c trafficlight.s
coverage: coverage:
coverage run -p ../../../opengeode.py trafficlight.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py trafficlight.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr test rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py basic.pr system_structure.pr --check ../../../opengeode.py basic.pr system_structure.pr --check
...@@ -12,5 +12,14 @@ test-ada: ...@@ -12,5 +12,14 @@ test-ada:
gnatlink test_ada.o basic.ali -lgnat -lm -o testcase gnatlink test_ada.o basic.ali -lgnat -lm -o testcase
./testcase | diff expected - ./testcase | diff expected -
test-llvm:
../../../opengeode.py basic.pr system_structure.pr --check --llvm
llc basic.ll
gcc -c basic.s
gcc -c test_llvm.c
gcc basic.o test_llvm.o -o testcase
./testcase | diff expected -
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr testcase rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
...@@ -21,5 +21,5 @@ test-llvm: ...@@ -21,5 +21,5 @@ test-llvm:
./testcase | diff expected - ./testcase | diff expected -
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali \ rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
gnat.cfg examiner bin *.wrn *.gpr testcase sequences.ll sequences.s bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py orchestrator.pr system_structure.pr --check ../../../opengeode.py orchestrator.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c orchestrator.adb gnatmake -c orchestrator.adb
test-llvm:
../../../opengeode.py orchestrator.pr system_structure.pr --llvm
llc orchestrator.ll
gcc -c orchestrator.s
coverage: coverage:
coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py fce.pr system_structure.pr --check ../../../opengeode.py fce.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c fce.adb gnatmake -c fce.adb
test-llvm:
../../../opengeode.py fce.pr system_structure.pr --llvm
llc fce.ll
gcc -c fce.s
coverage: coverage:
coverage run -p ../../../opengeode.py fce.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py fce.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py orchestrator.pr system_structure.pr --check ../../../opengeode.py orchestrator.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c orchestrator.adb gnatmake -c orchestrator.adb
test-llvm:
../../../opengeode.py orchestrator.pr system_structure.pr --llvm
llc orchestrator.ll
gcc -c orchestrator.s
coverage: coverage:
coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py function0.pr system_structure.pr --check ../../../opengeode.py function0.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c function0.adb gnatmake -c function0.adb
test-llvm:
../../../opengeode.py function0.pr system_structure.pr --llvm
llc function0.ll
gcc -c function0.s
coverage: coverage:
coverage run -p ../../../opengeode.py function0.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py function0.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py myfunction.pr system_structure.pr --check ../../../opengeode.py myfunction.pr system_structure.pr --check
...@@ -8,9 +8,14 @@ test-ada: ...@@ -8,9 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c myfunction.adb gnatmake -c myfunction.adb
test-llvm:
../../../opengeode.py myfunction.pr system_structure.pr --llvm
llc myfunction.ll
gcc -c myfunction.s
coverage: coverage:
coverage run -p ../../../opengeode.py myfunction.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py myfunction.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py orchestrator.pr system_structure.pr --check ../../../opengeode.py orchestrator.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c orchestrator.adb gnatmake -c orchestrator.adb
test-llvm:
../../../opengeode.py orchestrator.pr system_structure.pr --llvm
llc orchestrator.ll
gcc -c orchestrator.s
coverage: coverage:
coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py --check orchestrator.pr system_structure.pr ../../../opengeode.py --check orchestrator.pr system_structure.pr
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c orchestrator.adb gnatmake -c orchestrator.adb
test-llvm:
../../../opengeode.py orchestrator.pr system_structure.pr --llvm
llc orchestrator.ll
gcc -c orchestrator.s
coverage: coverage:
coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py orchestrator.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
all: test-ada all: test-ada test-llvm
test-parse: test-parse:
../../../opengeode.py challenge.pr system_structure.pr --check ../../../opengeode.py challenge.pr system_structure.pr --check
...@@ -8,8 +8,14 @@ test-ada: ...@@ -8,8 +8,14 @@ test-ada:
asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal asn1.exe -Ada dataview-uniq.asn -typePrefix asn1Scc -equal
gnatmake -c challenge.adb gnatmake -c challenge.adb
test-llvm:
../../../opengeode.py challenge.pr system_structure.pr --llvm
llc challenge.ll
gcc -c challenge.s
coverage: coverage:
coverage run -p ../../../opengeode.py challenge.pr system_structure.pr --toAda coverage run -p ../../../opengeode.py challenge.pr system_structure.pr --toAda
clean: clean:
rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner bin *.wrn *.gpr rm -rf *.adb *.ads *.pyc runSpark.sh spark.idx *.o *.ali gnat.cfg examiner \
bin *.wrn *.gpr testcase *.ll *.s
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment