| 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 <base/test/test_suite.h> | 5 #include "base/message_loop.h" |
| 6 #include "base/test/test_suite.h" |
| 7 #include "cc/test/test_webkit_platform.h" |
| 8 #include "third_party/WebKit/Source/Platform/chromium/public/Platform.h" |
| 6 #include <gmock/gmock.h> | 9 #include <gmock/gmock.h> |
| 7 | 10 |
| 8 #if defined(USE_LIBCC_FOR_COMPOSITOR) | |
| 9 #include <webkit/support/webkit_support.h> | |
| 10 #endif | |
| 11 | |
| 12 int main(int argc, char** argv) { | 11 int main(int argc, char** argv) { |
| 13 ::testing::InitGoogleMock(&argc, argv); | 12 ::testing::InitGoogleMock(&argc, argv); |
| 14 TestSuite testSuite(argc, argv); | 13 TestSuite testSuite(argc, argv); |
| 15 #if defined(USE_LIBCC_FOR_COMPOSITOR) | 14 cc::TestWebKitPlatform platform; |
| 16 webkit_support::SetUpTestEnvironmentForUnitTests(); | 15 MessageLoop message_loop; |
| 17 #endif | 16 WebKit::Platform::initialize(&platform); |
| 18 int result = testSuite.Run(); | 17 int result = testSuite.Run(); |
| 19 #if defined(USE_LIBCC_FOR_COMPOSITOR) | |
| 20 webkit_support::TearDownTestEnvironment(); | |
| 21 #endif | |
| 22 | 18 |
| 23 return result; | 19 return result; |
| 24 } | 20 } |
| 25 | 21 |
| OLD | NEW |