Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(295)

Unified Diff: content/test/content_test_suite.cc

Issue 1208603002: content: implement unittests backend for Ozone GBM Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: force single process Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/test/content_test_suite.cc
diff --git a/content/test/content_test_suite.cc b/content/test/content_test_suite.cc
index f7099dc369199518353f46ef4b43e2a3a93b6795..4b1fe425f6f7ec532e748a46b782b8249647dc5a 100644
--- a/content/test/content_test_suite.cc
+++ b/content/test/content_test_suite.cc
@@ -84,6 +84,16 @@ void ContentTestSuite::Initialize() {
#if defined(OS_WIN)
gfx::InitDeviceScaleFactor(1.0f);
#endif
+#if !defined(OS_IOS)
+ bool is_child_process = base::CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kTestChildProcess);
+#endif
+#if defined(USE_OZONE)
+ if (!is_child_process) {
+ ozone_ = ui::OzoneInitializerForTest::Create();
+ DCHECK(ozone_);
+ }
+#endif
ContentTestSuiteBase::Initialize();
{
@@ -95,8 +105,6 @@ void ContentTestSuite::Initialize() {
media::InitializeMediaLibrary();
// When running in a child process for Mac sandbox tests, the sandbox exists
// to initialize GL, so don't do it here.
- bool is_child_process = base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kTestChildProcess);
if (!is_child_process) {
gfx::GLSurfaceTestSupport::InitializeOneOff();
gpu::ApplyGpuDriverBugWorkarounds(base::CommandLine::ForCurrentProcess());

Powered by Google App Engine
This is Rietveld 408576698