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

Unified Diff: ui/gfx/platform_font_win_unittest.cc

Issue 11188005: Merge 161704 - Don't hang if can't downsize font. (Closed) Base URL: svn://svn.chromium.org/chrome/branches/1271/src/
Patch Set: Created 8 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/platform_font_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/platform_font_win_unittest.cc
===================================================================
--- ui/gfx/platform_font_win_unittest.cc (revision 162156)
+++ ui/gfx/platform_font_win_unittest.cc (working copy)
@@ -92,4 +92,13 @@
PlatformFontWin::get_minimum_font_size_callback = old_callback;
}
+TEST(PlatformFontWinTest, DeriveFontWithHeight_TooSmall) {
+ const Font base_font;
+ PlatformFontWin* platform_font =
+ static_cast<PlatformFontWin*>(base_font.platform_font());
+
+ const Font derived_font = platform_font->DeriveFontWithHeight(1, 0);
+ EXPECT_GT(derived_font.GetHeight(), 1);
+}
+
} // namespace gfx
« no previous file with comments | « ui/gfx/platform_font_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698