OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ui/gfx/compositor/test/test_suite.h" | 5 #include "ui/gfx/compositor/test/test_suite.h" |
6 | 6 |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" | 8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" |
9 #include "ui/base/ui_base_paths.h" | 9 #include "ui/base/ui_base_paths.h" |
10 #include "ui/gfx/compositor/compositor_cc.h" | 10 #include "ui/gfx/compositor/compositor.h" |
11 #include "ui/gfx/compositor/test/compositor_test_support.h" | 11 #include "ui/gfx/compositor/test/compositor_test_support.h" |
12 #include "ui/gfx/gfx_paths.h" | 12 #include "ui/gfx/gfx_paths.h" |
13 #include "ui/gfx/gl/gl_implementation.h" | 13 #include "ui/gfx/gl/gl_implementation.h" |
14 | 14 |
15 CompositorTestSuite::CompositorTestSuite(int argc, char** argv) | 15 CompositorTestSuite::CompositorTestSuite(int argc, char** argv) |
16 : TestSuite(argc, argv) {} | 16 : TestSuite(argc, argv) {} |
17 | 17 |
18 CompositorTestSuite::~CompositorTestSuite() {} | 18 CompositorTestSuite::~CompositorTestSuite() {} |
19 | 19 |
20 void CompositorTestSuite::Initialize() { | 20 void CompositorTestSuite::Initialize() { |
21 #if defined(OS_LINUX) | 21 #if defined(OS_LINUX) |
22 gfx::InitializeGLBindings(gfx::kGLImplementationOSMesaGL); | 22 gfx::InitializeGLBindings(gfx::kGLImplementationOSMesaGL); |
23 #endif | 23 #endif |
24 base::TestSuite::Initialize(); | 24 base::TestSuite::Initialize(); |
25 | 25 |
26 gfx::RegisterPathProvider(); | 26 gfx::RegisterPathProvider(); |
27 | 27 |
28 message_loop_.reset(new MessageLoop(MessageLoop::TYPE_UI)); | 28 message_loop_.reset(new MessageLoop(MessageLoop::TYPE_UI)); |
29 ui::CompositorTestSupport::Initialize(); | 29 ui::CompositorTestSupport::Initialize(); |
30 ui::CompositorCC::Initialize(false); | 30 ui::Compositor::Initialize(false); |
31 } | 31 } |
32 | 32 |
33 void CompositorTestSuite::Shutdown() { | 33 void CompositorTestSuite::Shutdown() { |
34 ui::CompositorCC::Terminate(); | 34 ui::Compositor::Terminate(); |
35 ui::CompositorTestSupport::Terminate(); | 35 ui::CompositorTestSupport::Terminate(); |
36 message_loop_.reset(); | 36 message_loop_.reset(); |
37 | 37 |
38 base::TestSuite::Shutdown(); | 38 base::TestSuite::Shutdown(); |
39 } | 39 } |
OLD | NEW |