summaryrefslogtreecommitdiffstats
path: root/chromeos/ime/input_method_property_unittest.cc
diff options
context:
space:
mode:
authornona@chromium.org <nona@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-25 15:32:04 +0000
committernona@chromium.org <nona@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-03-25 15:32:04 +0000
commit4acc18b555e36d72ac556f5b96735059b23a2650 (patch)
tree77d5ba9b0f4834eacbdd5af51c81d8c36128f004 /chromeos/ime/input_method_property_unittest.cc
parentf8462f50f0e36a949867d04c367fd3c5fe597f74 (diff)
downloadchromium_src-4acc18b555e36d72ac556f5b96735059b23a2650.zip
chromium_src-4acc18b555e36d72ac556f5b96735059b23a2650.tar.gz
chromium_src-4acc18b555e36d72ac556f5b96735059b23a2650.tar.bz2
Move InputMethod misc class from c/b/chromeos
This is part of extraction work for input method from chrome/browser/chromeos. This CL extract InputMethodProperty, InputMethodConfig and IBus related key mapping function from chrome/browser/chromeos to chromeos/ime. BUG=164375 TEST=None TBR=sky Review URL: https://chromiumcodereview.appspot.com/12438013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@190403 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chromeos/ime/input_method_property_unittest.cc')
-rw-r--r--chromeos/ime/input_method_property_unittest.cc31
1 files changed, 31 insertions, 0 deletions
diff --git a/chromeos/ime/input_method_property_unittest.cc b/chromeos/ime/input_method_property_unittest.cc
new file mode 100644
index 0000000..d00b532
--- /dev/null
+++ b/chromeos/ime/input_method_property_unittest.cc
@@ -0,0 +1,31 @@
+// Copyright 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "base/logging.h"
+#include "chromeos/ime/input_method_property.h"
+#include "testing/gtest/include/gtest/gtest.h"
+
+namespace chromeos {
+namespace input_method {
+
+TEST(InputMethodPropertyTest, TestOperatorEqual) {
+ InputMethodProperty empty;
+ InputMethodProperty reference("key", "label", true, true);
+
+ InputMethodProperty p1("X", "label", true, true);
+ InputMethodProperty p2("key", "X", true, true);
+ InputMethodProperty p3("key", "label", false, true);
+ InputMethodProperty p4("key", "label", true, false);
+
+ EXPECT_EQ(empty, empty);
+ EXPECT_EQ(reference, reference);
+ EXPECT_NE(reference, empty);
+ EXPECT_NE(reference, p1);
+ EXPECT_NE(reference, p2);
+ EXPECT_NE(reference, p3);
+ EXPECT_NE(reference, p4);
+}
+
+} // namespace input_method
+} // namespace chromeos