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 "chrome/browser/chromeos/input_method/input_method_configuration.h" | 5 #include "chrome/browser/chromeos/input_method/input_method_configuration.h" |
6 #include "chrome/browser/chromeos/input_method/mock_input_method_manager.h" | 6 #include "chrome/browser/chromeos/input_method/mock_input_method_manager_impl.h" |
7 #include "testing/gtest/include/gtest/gtest.h" | 7 #include "testing/gtest/include/gtest/gtest.h" |
8 | 8 |
9 namespace chromeos { | 9 namespace chromeos { |
10 namespace input_method { | 10 namespace input_method { |
11 | 11 |
12 TEST(InputMethodConfigurationTest, TestInitialize) { | 12 TEST(InputMethodConfigurationTest, TestInitialize) { |
13 InputMethodManager* manager = InputMethodManager::Get(); | 13 InputMethodManager* manager = InputMethodManager::Get(); |
14 EXPECT_FALSE(manager); | 14 EXPECT_FALSE(manager); |
15 | 15 |
16 Initialize(); | 16 Initialize(); |
17 manager = InputMethodManager::Get(); | 17 manager = InputMethodManager::Get(); |
18 EXPECT_TRUE(manager); | 18 EXPECT_TRUE(manager); |
19 Shutdown(); | 19 Shutdown(); |
20 } | 20 } |
21 | 21 |
22 TEST(InputMethodConfigurationTest, TestInitializeForTesting) { | 22 TEST(InputMethodConfigurationTest, TestInitializeForTesting) { |
23 InputMethodManager* manager = InputMethodManager::Get(); | 23 InputMethodManager* manager = InputMethodManager::Get(); |
24 EXPECT_FALSE(manager); | 24 EXPECT_FALSE(manager); |
25 | 25 |
26 InitializeForTesting(new MockInputMethodManager); | 26 InitializeForTesting(new MockInputMethodManagerImpl); |
27 manager = InputMethodManager::Get(); | 27 manager = InputMethodManager::Get(); |
28 EXPECT_TRUE(manager); | 28 EXPECT_TRUE(manager); |
29 Shutdown(); | 29 Shutdown(); |
30 } | 30 } |
31 | 31 |
32 } // namespace input_method | 32 } // namespace input_method |
33 } // namespace chromeos | 33 } // namespace chromeos |
OLD | NEW |