generated from freudenreichan/info2Praktikum-DobleSpiel
Testname geaendert
This commit is contained in:
parent
d42a9e09e1
commit
e884522b31
65
makefile
65
makefile
@ -1,10 +1,17 @@
|
|||||||
CC = gcc
|
CC = gcc
|
||||||
FLAGS = -g -Wall -lm
|
|
||||||
|
|
||||||
|
raylibfolder = ./raylib
|
||||||
|
unityfolder = ./unity
|
||||||
|
|
||||||
|
|
||||||
|
FLAGS = -g -Wall -I$(unityfolder)
|
||||||
|
|
||||||
|
|
||||||
ifeq ($(OS),Windows_NT)
|
ifeq ($(OS),Windows_NT)
|
||||||
include makefile_windows.variables
|
include makefile_windows.variables
|
||||||
else
|
else
|
||||||
UNAME = $(shell uname)
|
UNAME := $(shell uname)
|
||||||
ifeq ($(UNAME),Linux)
|
ifeq ($(UNAME),Linux)
|
||||||
include makefile_linux.variables
|
include makefile_linux.variables
|
||||||
else
|
else
|
||||||
@ -12,60 +19,48 @@ else
|
|||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
raylibfolder = ./raylib
|
# --------------------------
|
||||||
unityfolder = ./unity
|
# Objektdateien
|
||||||
|
# --------------------------
|
||||||
|
program_obj_files := stack.o bintree.o numbers.o timer.o highscore.o
|
||||||
|
|
||||||
# --------------------------
|
|
||||||
# Initiales Programm bauen (zum ausprobieren)
|
|
||||||
# --------------------------
|
|
||||||
doble_initial:
|
|
||||||
$(CC) -o doble_initial $(BINARIES)/libdoble_complete.a
|
|
||||||
|
|
||||||
# --------------------------
|
%.o: %.c
|
||||||
# Selbst implementiertes Programm bauen
|
$(CC) $(FLAGS) -c $< -o $@
|
||||||
# --------------------------
|
|
||||||
program_obj_files = stack.o bintree.o numbers.o timer.o highscore.o
|
|
||||||
|
|
||||||
doble: main.o $(program_obj_files)
|
doble: main.o $(program_obj_files)
|
||||||
$(CC) $(FLAGS) $^ -o doble
|
$(CC) $(FLAGS) $^ -o doble
|
||||||
|
|
||||||
$(program_obj_filesobj_files): %.o: %.c
|
|
||||||
$(CC) -c $(FLAGS) $^ -o $@
|
doble_initial:
|
||||||
|
$(CC) -o doble_initial $(BINARIES)/libdoble_complete.a
|
||||||
|
|
||||||
# --------------------------
|
# --------------------------
|
||||||
# Unit Tests
|
# Unit Tests
|
||||||
# --------------------------
|
# --------------------------
|
||||||
|
|
||||||
unitTests:
|
unitTests:
|
||||||
echo "needs to be implemented"
|
@echo "needs to be implemented"
|
||||||
|
|
||||||
bintree: bintree.c
|
|
||||||
$(CC) $(FLAGS) -c bintree bintree.c
|
|
||||||
|
|
||||||
bintreeTests: stack.o bintree.o bintreeTests.c $(unityfolder)/unity.c
|
binTreeTest: stack.o bintree.o binTreeTest.c $(unityfolder)/unity.c
|
||||||
$(CC) $(FLAGS) -o runbintreeTests bintreeTests.c bintree.o stack.o $(unityfolder)/unity.c
|
$(CC) $(FLAGS) -o runbinTreeTest binTreeTest.c bintree.o stack.o $(unityfolder)/unity.c
|
||||||
|
|
||||||
highscore: highscore.c
|
|
||||||
$(CC) $(FLAGS) -c highscore highscore.c
|
|
||||||
|
|
||||||
numbers: numbers.c
|
test_numbers: numbers_no_tree.o bintree.o stack.o test_numbers.c $(unityfolder)/unity.c
|
||||||
$(CC) $(FLAGS) -c numbers numbers.c
|
$(CC) $(FLAGS) -o run_numbersTests test_numbers.c numbers_no_tree.o bintree.o stack.o $(unityfolder)/unity.c
|
||||||
|
|
||||||
test_numbers: numbers.o bintree.o stack.o test_numbers.c $(unityfolder)/unity.c
|
|
||||||
$(CC) $(FLAGS) -o run_numbersTests test_numbers.c numbers.o bintree.o stack.o $(unityfolder)/unity.c
|
|
||||||
|
|
||||||
stack: stack.c
|
|
||||||
$(CC) $(FLAGS) -c stack stack.c
|
|
||||||
|
|
||||||
test_stack: stack.o test_stack.c $(unityfolder)/unity.c
|
test_stack: stack.o test_stack.c $(unityfolder)/unity.c
|
||||||
$(CC) $(FLAGS) -o runstackTests test_stack.c stack.o $(unityfolder)/unity.c
|
$(CC) $(FLAGS) -o runtest_stack test_stack.c stack.o $(unityfolder)/unity.c
|
||||||
|
|
||||||
timer: timer.c
|
|
||||||
$(CC) $(FLAGS) -c timer timer.c
|
|
||||||
# --------------------------
|
# --------------------------
|
||||||
# Clean
|
# Cleaning
|
||||||
# --------------------------
|
# --------------------------
|
||||||
clean:
|
clean:
|
||||||
ifeq ($(OS),Windows_NT)
|
ifeq ($(OS),Windows_NT)
|
||||||
del /f *.o doble
|
del /f *.o doble runstackTests run_numbersTests runbintreeTests
|
||||||
else
|
else
|
||||||
rm -f *.o doble
|
rm -f *.o doble runstackTests run_numbersTests runbintreeTests
|
||||||
endif
|
endif
|
||||||
BIN
runtest_stack.exe
Normal file
BIN
runtest_stack.exe
Normal file
Binary file not shown.
@ -4,6 +4,14 @@
|
|||||||
|
|
||||||
//Testfunkionen zu push, pull, top & clearStack schreiben
|
//Testfunkionen zu push, pull, top & clearStack schreiben
|
||||||
|
|
||||||
|
void setUp()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void tearDown()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
void test(char *name, int condition) {
|
void test(char *name, int condition) {
|
||||||
if (condition) {
|
if (condition) {
|
||||||
printf("[OK] %s\n", name);
|
printf("[OK] %s\n", name);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user