Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

Commit

Permalink
Initial revision of SDL_Surface testsuite.
Browse files Browse the repository at this point in the history
  • Loading branch information
bobbens committed Jul 1, 2009
1 parent d12a029 commit dd4b278
Show file tree
Hide file tree
Showing 4 changed files with 673 additions and 6 deletions.
16 changes: 12 additions & 4 deletions test/automated/Makefile
@@ -1,12 +1,16 @@


CFLAGS := -I. `sdl-config --cflags`
LDFLAGS := `sdl-config --libs`
#CFLAGS := -I. `sdl-config --cflags`
#LDFLAGS := `sdl-config --libs`

COMMON_SRC := SDL_at.c
# If it doesn't pick up defaults
CFLAGS := -I. -D_GNU_SOURCE=1 -D_REENTRANT -I/usr/local/include/SDL
LDFLAGS := -lm -ldl -lesd -lpthread

COMMON_SRC := SDL_at.c /usr/local/lib/libSDL.a
COMMON_INCLUDE := SDL_at.h

TESTS_ALL := rwops/rwops
TESTS_ALL := rwops/rwops surface/surface


.PHONY: all clean test
Expand All @@ -16,9 +20,13 @@ all: $(TESTS_ALL)

test: all
@./rwops/rwops
@./surface/surface

rwops/rwops: rwops/rwops.c $(COMMON_INCLUDE)
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ rwops/rwops.c $(COMMON_SRC)

surface/surface: surface/surface.c $(COMMON_INCLUDE)
$(CC) $(CFLAGS) $(LDFLAGS) -o $@ surface/surface.c $(COMMON_SRC)

clean:
$(RM) $(TESTS_ALL)
4 changes: 2 additions & 2 deletions test/automated/SDL_at.h
Expand Up @@ -21,11 +21,11 @@
*
* SDL_ATbegin( "My first testcase" );
* if (!SDL_ATassert( "Trying '1+1=2'.", (1+1)==2))
* SDL_ATend();
* return;
*
* SDL_ATbegin( "My second testcase" );
* if (!SDL_ATassert( "Trying '4/2=2'.", (4/2)==2))
* SDL_ATend();
* return;
*
* f = SDL_ATend();
* @endcode
Expand Down

0 comments on commit dd4b278

Please sign in to comment.