Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(349)

Side by Side Diff: chrome/browser/ui/webui/options/font_settings_utils_unittest.cc

Issue 2919343005: Remove tests for deprecated Options UI (Closed)
Patch Set: and more Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 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/font_settings_utils.h"
6
7 #include "testing/gtest/include/gtest/gtest.h"
8
9 namespace options {
10
11 TEST(FontSettingsUtilitiesTest, ResolveFontList) {
12 EXPECT_TRUE(FontSettingsUtilities::ResolveFontList("").empty());
13
14 // Returns the first available font if starts with ",".
15 EXPECT_EQ("Arial",
16 FontSettingsUtilities::ResolveFontList(",not exist, Arial"));
17
18 // Returns the first font if no fonts are available.
19 EXPECT_EQ("not exist",
20 FontSettingsUtilities::ResolveFontList(",not exist, not exist 2"));
21
22 // Otherwise returns any strings as they were set.
23 std::string non_lists[] = {
24 "Arial", "not exist", "not exist, Arial",
25 };
26 for (const std::string& name : non_lists)
27 EXPECT_EQ(name, FontSettingsUtilities::ResolveFontList(name));
28 }
29
30 } // namespace options
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698