Remove dependency of NaCl untarred toolchain from NaCl SDK Tests.
[chromium-blink-merge.git] / chromeos / ime / input_method_whitelist_unittest.cc
blob6a0d5c50109a5afe6ae102c4dbaded0f5b6e1628
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
3 // found in the LICENSE file.
5 #include "base/logging.h"
6 #include "chromeos/ime/input_method_whitelist.h"
7 #include "testing/gtest/include/gtest/gtest.h"
9 namespace chromeos {
10 namespace input_method {
12 namespace {
14 class InputMethodWhitelistTest : public testing::Test {
15 protected:
16 const InputMethodWhitelist whitelist_;
19 } // namespace
21 TEST_F(InputMethodWhitelistTest, TestInputMethodIdIsWhitelisted) {
22 EXPECT_TRUE(whitelist_.InputMethodIdIsWhitelisted("xkb:us:dvorak:eng"));
23 EXPECT_FALSE(whitelist_.InputMethodIdIsWhitelisted("mozc,"));
24 EXPECT_FALSE(whitelist_.InputMethodIdIsWhitelisted(
25 "mozc-pinyin,xkb:us:dvorak:eng"));
26 EXPECT_FALSE(whitelist_.InputMethodIdIsWhitelisted("not-supported-id"));
27 EXPECT_FALSE(whitelist_.InputMethodIdIsWhitelisted(","));
28 EXPECT_FALSE(whitelist_.InputMethodIdIsWhitelisted(""));
31 } // namespace input_method
32 } // namespace chromeos