Index: content/test/content_test_suite.cc |
diff --git a/content/test/content_test_suite.cc b/content/test/content_test_suite.cc |
index 2cb9731ea48e08a9dce3440f52387cf5f78b34b5..39774fe81c43be8454929b05613fe6a422fa0339 100644 |
--- a/content/test/content_test_suite.cc |
+++ b/content/test/content_test_suite.cc |
@@ -8,6 +8,7 @@ |
#include "base/base_switches.h" |
#include "base/logging.h" |
#include "base/macros.h" |
+#include "base/message_loop/message_loop.h" |
#include "build/build_config.h" |
#include "content/public/common/content_client.h" |
#include "content/public/common/content_paths.h" |
@@ -85,6 +86,14 @@ void ContentTestSuite::Initialize() { |
#if defined(OS_WIN) |
gfx::SetDefaultDeviceScaleFactor(1.0f); |
#endif |
+#if defined(USE_OZONE) |
+ // Ozone backend needs MessageLoopForUI. |
+ scoped_ptr<base::MessageLoop> message_loop; |
+ if (!base::MessageLoop::current()) |
reveman
2016/01/11 19:13:51
is this conditional needed?
dshwang
2016/01/11 20:17:45
content_gl_tests calls it after creating MessageLo
|
+ message_loop.reset(new base::MessageLoopForUI); |
+ ozone_ = ui::OzoneInitializerForTest::Create(); |
+ DCHECK(ozone_); |
+#endif |
ContentTestSuiteBase::Initialize(); |
{ |