| Index: ios/chrome/browser/ui/history/tab_history_popup_controller_unittest.mm
|
| diff --git a/ios/chrome/browser/ui/history/tab_history_popup_controller_unittest.mm b/ios/chrome/browser/ui/history/tab_history_popup_controller_unittest.mm
|
| index 6f1e9e77e87b5912eb244edf347a7f0a35cf33fd..e0471ddd6e73bacc657e34f82c523092aede232b 100644
|
| --- a/ios/chrome/browser/ui/history/tab_history_popup_controller_unittest.mm
|
| +++ b/ios/chrome/browser/ui/history/tab_history_popup_controller_unittest.mm
|
| @@ -12,6 +12,7 @@
|
| #import "ios/chrome/browser/ui/history/tab_history_view_controller.h"
|
| #include "ios/chrome/browser/ui/ui_util.h"
|
| #include "ios/web/public/navigation_item.h"
|
| +#include "ios/web/public/navigation_item_list.h"
|
| #include "ios/web/public/referrer.h"
|
| #include "testing/gtest/include/gtest/gtest.h"
|
| #include "testing/platform_test.h"
|
| @@ -30,7 +31,9 @@ + (CGFloat)popupWidthForItems:(const web::NavigationItemList)items;
|
|
|
| class TabHistoryPopupControllerTest : public PlatformTest {
|
| protected:
|
| - void SetUp() override {
|
| + TabHistoryPopupControllerTest() : PlatformTest() {
|
| + parent_.reset([[UIView alloc] initWithFrame:[UIScreen mainScreen].bounds]);
|
| + // Create test items and populate |items_|.
|
| web::Referrer referrer(GURL("http://www.example.com"),
|
| web::ReferrerPolicyDefault);
|
| items_.push_back(web::NavigationItem::Create());
|
| @@ -40,10 +43,10 @@ void SetUp() override {
|
| items_.back()->SetURL(GURL("http://www.example.com/1"));
|
| items_.back()->SetReferrer(referrer);
|
| items_.push_back(web::NavigationItem::Create());
|
| - items_.back()->SetURL(GURL("http://www.example.com/0"));
|
| + items_.back()->SetURL(GURL("http://www.example.com/2"));
|
| items_.back()->SetReferrer(referrer);
|
| -
|
| - parent_.reset([[UIView alloc] initWithFrame:[UIScreen mainScreen].bounds]);
|
| + // Create the popup controller using CRWSessionEntries created from the
|
| + // NavigationItems in |items_|.
|
| popup_.reset([[TabHistoryPopupController alloc]
|
| initWithOrigin:CGPointZero
|
| parentView:parent_
|
|
|