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/browser_state_monitor.h" | 5 #include "chrome/browser/chromeos/input_method/browser_state_monitor.h" |
6 | 6 |
| 7 #include "chrome/browser/api/prefs/pref_member.h" |
7 #include "chrome/browser/chromeos/input_method/mock_input_method_manager.h" | 8 #include "chrome/browser/chromeos/input_method/mock_input_method_manager.h" |
8 #include "chrome/browser/prefs/pref_member.h" | |
9 #include "chrome/common/chrome_notification_types.h" | 9 #include "chrome/common/chrome_notification_types.h" |
10 #include "chrome/common/pref_names.h" | 10 #include "chrome/common/pref_names.h" |
11 #include "chrome/test/base/testing_pref_service.h" | 11 #include "chrome/test/base/testing_pref_service.h" |
12 #include "content/public/browser/notification_details.h" | 12 #include "content/public/browser/notification_details.h" |
13 #include "content/public/browser/notification_service.h" | 13 #include "content/public/browser/notification_service.h" |
14 #include "testing/gtest/include/gtest/gtest.h" | 14 #include "testing/gtest/include/gtest/gtest.h" |
15 | 15 |
16 namespace chromeos { | 16 namespace chromeos { |
17 namespace input_method { | 17 namespace input_method { |
18 namespace { | 18 namespace { |
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
383 monitor.InputMethodChanged(&mock_manager, false); | 383 monitor.InputMethodChanged(&mock_manager, false); |
384 EXPECT_EQ(0, monitor.update_local_state_count()); | 384 EXPECT_EQ(0, monitor.update_local_state_count()); |
385 EXPECT_EQ(5, monitor.update_user_pref_count()); | 385 EXPECT_EQ(5, monitor.update_user_pref_count()); |
386 EXPECT_EQ(input_method_id_3, monitor.last_user_pref()); | 386 EXPECT_EQ(input_method_id_3, monitor.last_user_pref()); |
387 EXPECT_EQ(input_method_id_2, previous.GetValue()); | 387 EXPECT_EQ(input_method_id_2, previous.GetValue()); |
388 EXPECT_EQ(input_method_id_3, current.GetValue()); | 388 EXPECT_EQ(input_method_id_3, current.GetValue()); |
389 } | 389 } |
390 | 390 |
391 } // namespace input_method | 391 } // namespace input_method |
392 } // namespace chromeos | 392 } // namespace chromeos |
OLD | NEW |