mirror of
https://github.com/MadeOfJelly/MushMachine.git
synced 2025-06-18 18:56:36 +02:00
make tests auto terminate
This commit is contained in:
@ -5,6 +5,8 @@
|
||||
#include <mm/services/sdl_service.hpp>
|
||||
#include <mm/services/simple_sdl_renderer.hpp>
|
||||
|
||||
#include <mm/services/count_down.hpp>
|
||||
|
||||
TEST(simple_sdl_renderer, basic) {
|
||||
srand(1);
|
||||
MM::Engine engine;
|
||||
@ -33,6 +35,11 @@ TEST(simple_sdl_renderer, basic) {
|
||||
}
|
||||
);
|
||||
|
||||
#ifdef MM_AUTOTEST
|
||||
engine.addService<MM::Services::CountDown>(50); // 50 frames
|
||||
ASSERT_TRUE(engine.enableService<MM::Services::CountDown>());
|
||||
#endif
|
||||
|
||||
engine.run();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user