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.h" |
7 #include "content/public/browser/browser_thread.h" | 7 #include "content/public/browser/browser_thread.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 8 #include "testing/gtest/include/gtest/gtest.h" |
9 #include "ui/base/ime/text_input_test_support.h" | 9 #include "ui/base/ime/text_input_test_support.h" |
10 | 10 |
11 namespace chromeos { | 11 namespace chromeos { |
12 namespace input_method { | 12 namespace input_method { |
13 | 13 |
14 class InputMethodConfigurationTest : public testing::Test { | 14 class InputMethodConfigurationTest : public testing::Test { |
15 public: | 15 public: |
16 void SetUp() { | 16 virtual void SetUp() { |
17 } | 17 } |
18 | 18 |
19 void TearDown() { | 19 virtual void TearDown() { |
20 } | 20 } |
21 }; | 21 }; |
22 | 22 |
23 TEST_F(InputMethodConfigurationTest, TestInitialize) { | 23 TEST_F(InputMethodConfigurationTest, TestInitialize) { |
24 Initialize( | 24 Initialize( |
25 content::BrowserThread::GetMessageLoopProxyForThread( | 25 content::BrowserThread::GetMessageLoopProxyForThread( |
26 content::BrowserThread::UI), | 26 content::BrowserThread::UI), |
27 content::BrowserThread::GetMessageLoopProxyForThread( | 27 content::BrowserThread::GetMessageLoopProxyForThread( |
28 content::BrowserThread::FILE)); | 28 content::BrowserThread::FILE)); |
29 InputMethodManager* manager = GetInputMethodManager(); | 29 InputMethodManager* manager = GetInputMethodManager(); |
30 EXPECT_TRUE(manager); | 30 EXPECT_TRUE(manager); |
31 Shutdown(); | 31 Shutdown(); |
32 } | 32 } |
33 | 33 |
34 TEST_F(InputMethodConfigurationTest, TestInitializeForTesting) { | 34 TEST_F(InputMethodConfigurationTest, TestInitializeForTesting) { |
35 InitializeForTesting(new MockInputMethodManager); | 35 InitializeForTesting(new MockInputMethodManager); |
36 InputMethodManager* manager = GetInputMethodManager(); | 36 InputMethodManager* manager = GetInputMethodManager(); |
37 EXPECT_TRUE(manager); | 37 EXPECT_TRUE(manager); |
38 Shutdown(); | 38 Shutdown(); |
39 } | 39 } |
40 | 40 |
41 } // namespace input_method | 41 } // namespace input_method |
42 } // namespace chromeos | 42 } // namespace chromeos |
OLD | NEW |