From cb06526b10d9ef44b3606c36aec498822884251e Mon Sep 17 00:00:00 2001 From: "Thiago Marcos P. Santos" Date: Fri, 13 Nov 2015 17:47:22 +0200 Subject: [tests] Remove libuv dependency from the tests --- test/sprite/sprite_store.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'test/sprite') diff --git a/test/sprite/sprite_store.cpp b/test/sprite/sprite_store.cpp index 14ea6c957b..fd8f3616f5 100644 --- a/test/sprite/sprite_store.cpp +++ b/test/sprite/sprite_store.cpp @@ -4,6 +4,7 @@ #include +#include #include #include @@ -186,9 +187,9 @@ private: class SpriteTest : public testing::Test { protected: void runTest(const SpriteParams& params, FileSource* fileSource, SpriteTestCallback callback) { - util::RunLoop loop(uv_default_loop()); + util::RunLoop loop; - async_ = std::make_unique(loop.get(), [&] { loop.stop(); }); + async_ = std::make_unique([&] { loop.stop(); }); async_->unref(); const util::ThreadContext context = {"Map", util::ThreadType::Map, util::ThreadPriority::Regular}; @@ -196,7 +197,7 @@ protected: util::Thread tester(context, fileSource, callback); tester.invoke(&SpriteThread::loadSprite, params); - uv_run(loop.get(), UV_RUN_DEFAULT); + loop.run(); tester.invoke(&SpriteThread::unloadSprite); } @@ -206,7 +207,7 @@ protected: } private: - std::unique_ptr async_; + std::unique_ptr async_; }; TEST_F(SpriteTest, LoadingSuccess) { -- cgit v1.2.1