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

Side by Side Diff: chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac_unittest.mm

Issue 24120005: Cleanup and IWYU-ify CocoaProfileTest and related tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: include order Created 7 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import "chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac.h" 5 #import "chrome/browser/ui/cocoa/omnibox/omnibox_popup_view_mac.h"
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "base/strings/sys_string_conversions.h" 8 #include "base/strings/sys_string_conversions.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "chrome/browser/ui/cocoa/cocoa_profile_test.h" 10 #include "chrome/browser/ui/cocoa/cocoa_profile_test.h"
11 #import "chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.h" 11 #import "chrome/browser/ui/cocoa/omnibox/omnibox_view_mac.h"
12 #include "chrome/test/base/testing_profile.h"
13 #include "ui/gfx/rect.h"
12 #include "ui/gfx/text_elider.h" 14 #include "ui/gfx/text_elider.h"
13 15
14 namespace { 16 namespace {
15 17
16 const float kLargeWidth = 10000; 18 const float kLargeWidth = 10000;
17 19
18 // Returns the length of the run starting at |location| for which 20 // Returns the length of the run starting at |location| for which
19 // |attributeName| remains the same. 21 // |attributeName| remains the same.
20 NSUInteger RunLengthForAttribute(NSAttributedString* string, 22 NSUInteger RunLengthForAttribute(NSAttributedString* string,
21 NSUInteger location, 23 NSUInteger location,
(...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 EXPECT_GT(popup_view.GetTargetBounds().height(), old_height); 352 EXPECT_GT(popup_view.GetTargetBounds().height(), old_height);
351 EXPECT_EQ(5, [popup_view.matrix() numberOfRows]); 353 EXPECT_EQ(5, [popup_view.matrix() numberOfRows]);
352 354
353 popup_view.SetResultCount(0); 355 popup_view.SetResultCount(0);
354 popup_view.UpdatePopupAppearance(); 356 popup_view.UpdatePopupAppearance();
355 EXPECT_FALSE(popup_view.IsOpen()); 357 EXPECT_FALSE(popup_view.IsOpen());
356 EXPECT_EQ(0, [popup_view.matrix() numberOfRows]); 358 EXPECT_EQ(0, [popup_view.matrix() numberOfRows]);
357 } 359 }
358 360
359 } // namespace 361 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698