diff options
author | Andreas Schiffler <aschiffler@ferzkopp.net> | 2013-01-31 08:45:30 -0800 |
---|---|---|
committer | Andreas Schiffler <aschiffler@ferzkopp.net> | 2013-01-31 08:45:30 -0800 |
commit | 5a66919e3443292517a772094929ab0214960e6a (patch) | |
tree | 827922749723632d2e367bb8e91cbc1fe3a20237 /test/testautomation.c | |
parent | dee82c9e576a9c58462ba9ffdd103ad14ae5e593 (diff) | |
download | sdl-5a66919e3443292517a772094929ab0214960e6a.tar.gz |
Add tests to audio suite; update harness filter logic
Diffstat (limited to 'test/testautomation.c')
-rw-r--r-- | test/testautomation.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/test/testautomation.c b/test/testautomation.c index 25165edb0..a32853c53 100644 --- a/test/testautomation.c +++ b/test/testautomation.c @@ -37,7 +37,8 @@ main(int argc, char *argv[]) Uint64 userExecKey = 0; char *userRunSeed = NULL; char *filter = NULL; - int i; + int i, done; + SDL_Event event; /* Initialize test framework */ state = SDLTest_CommonCreateState(argv, SDL_INIT_VIDEO); @@ -103,6 +104,15 @@ main(int argc, char *argv[]) /* Call Harness */ result = SDLTest_RunSuites(testSuites, (const char *)userRunSeed, userExecKey, (const char *)filter, testIterations); + /* Empty event queue */ + done = 0; + for (i=0; i<100; i++) { + while (SDL_PollEvent(&event)) { + SDLTest_CommonEvent(state, &event, &done); + } + SDL_Delay(10); + } + /* Clean up */ if (userRunSeed != NULL) { SDL_free(userRunSeed); |