OLD | NEW |
| (Empty) |
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. | |
4 | |
5 #include "chrome/browser/ui/webui/options/language_options_handler.h" | |
6 | |
7 #include <string> | |
8 | |
9 #include "base/values.h" | |
10 #include "build/build_config.h" | |
11 #include "testing/gtest/include/gtest/gtest.h" | |
12 | |
13 #if !defined(OS_MACOSX) | |
14 TEST(LanguageOptionsHandlerTest, GetUILanguageCodeSet) { | |
15 std::unique_ptr<base::DictionaryValue> dictionary( | |
16 options::LanguageOptionsHandler::GetUILanguageCodeSet()); | |
17 EXPECT_TRUE(dictionary->HasKey("en-US")); | |
18 // Note that we don't test a false case, as such an expectation will | |
19 // fail when we add support for the language. | |
20 // EXPECT_FALSE(dictionary->HasKey("no")); | |
21 } | |
22 #endif // !defined(OS_MACOSX) | |
23 | |
24 TEST(LanguageOptionsHandlerTest, GetSpellCheckLanguageCodeSet) { | |
25 std::unique_ptr<base::DictionaryValue> dictionary( | |
26 options::LanguageOptionsHandler::GetSpellCheckLanguageCodeSet()); | |
27 EXPECT_TRUE(dictionary->HasKey("en-US")); | |
28 } | |
OLD | NEW |