Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

Added tests for SDL_HasIntersection; added negative parameter tests; …

…refactored existing test code
  • Loading branch information
ferzkopp committed Sep 5, 2011
1 parent bb03617 commit 342ae99abfe237f81a5a3cb324c9d1d4aaa7e76a
Showing with 257 additions and 76 deletions.
  1. +3 −2 test/test-automation/src/runner/runner.c
  2. +254 −74 test/test-automation/tests/testrect/testrect.c
@@ -607,7 +607,7 @@ LoadTestCaseFunction(void *suite, char *testName)
{
TestCaseFp test = (TestCaseFp) SDL_LoadFunction(suite, testName);
if(test == NULL) {
fprintf(stderr, "Loading test failed, tests == NULL\n");
fprintf(stderr, "Loading test %s failed, test == NULL\n", testName);
fprintf(stderr, "%s\n", SDL_GetError());
}

@@ -702,6 +702,7 @@ LoadCountFailedAssertsFunction(void *suite) {
return countFailedAssert;
}

#define USE_SDL_TIMER_FOR_TIMEOUT

/*!
* Set timeout for test.
@@ -722,7 +723,7 @@ SetTestTimeout(int timeout, void (*callback)(int))

int tm = (timeout > universal_timeout ? timeout : universal_timeout);

#if 1
#ifdef USE_SDL_TIMER_FOR_TIMEOUT
/* Init SDL timer if not initialized before */
if(SDL_WasInit(SDL_INIT_TIMER) == 0) {
if(SDL_InitSubSystem(SDL_INIT_TIMER)) {

0 comments on commit 342ae99

Please sign in to comment.