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

Side by Side Diff: ios/web/navigation/crw_session_controller_unittest.mm

Issue 1861593005: Convert //ios from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add header Created 4 years, 8 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
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 "ios/web/navigation/crw_session_controller.h" 5 #import "ios/web/navigation/crw_session_controller.h"
6 6
7 #import <Foundation/Foundation.h> 7 #import <Foundation/Foundation.h>
8 8
9 #include <memory>
noyau (Ping after 24h) 2016/04/07 13:34:05 Not needed.
9 #include <utility> 10 #include <utility>
10 11
11 #include "base/logging.h" 12 #include "base/logging.h"
12 #import "base/mac/scoped_nsobject.h" 13 #import "base/mac/scoped_nsobject.h"
13 #include "base/memory/scoped_ptr.h"
14 #include "base/strings/sys_string_conversions.h" 14 #include "base/strings/sys_string_conversions.h"
15 #import "ios/web/navigation/crw_session_controller+private_constructors.h" 15 #import "ios/web/navigation/crw_session_controller+private_constructors.h"
16 #include "ios/web/navigation/crw_session_entry.h" 16 #include "ios/web/navigation/crw_session_entry.h"
17 #include "ios/web/navigation/navigation_item_impl.h" 17 #include "ios/web/navigation/navigation_item_impl.h"
18 #include "ios/web/public/referrer.h" 18 #include "ios/web/public/referrer.h"
19 #include "ios/web/public/test/test_browser_state.h" 19 #include "ios/web/public/test/test_browser_state.h"
20 #include "ios/web/public/test/test_web_thread_bundle.h" 20 #include "ios/web/public/test/test_web_thread_bundle.h"
21 #import "net/base/mac/url_conversions.h" 21 #import "net/base/mac/url_conversions.h"
22 #include "testing/gtest/include/gtest/gtest.h" 22 #include "testing/gtest/include/gtest/gtest.h"
23 #include "testing/gtest_mac.h" 23 #include "testing/gtest_mac.h"
(...skipping 1002 matching lines...) Expand 10 before | Expand all | Expand 10 after
1026 1026
1027 // Remove an entry and attempt to go it. Ensure it outlives the removal. 1027 // Remove an entry and attempt to go it. Ensure it outlives the removal.
1028 base::scoped_nsobject<CRWSessionEntry> entry3( 1028 base::scoped_nsobject<CRWSessionEntry> entry3(
1029 [[session_controller_.get().entries objectAtIndex:3] retain]); 1029 [[session_controller_.get().entries objectAtIndex:3] retain]);
1030 [session_controller_ removeEntryAtIndex:3]; 1030 [session_controller_ removeEntryAtIndex:3];
1031 [session_controller_ goToEntry:entry3]; 1031 [session_controller_ goToEntry:entry3];
1032 EXPECT_EQ(1, session_controller_.get().currentNavigationIndex); 1032 EXPECT_EQ(1, session_controller_.get().currentNavigationIndex);
1033 } 1033 }
1034 1034
1035 } // anonymous namespace 1035 } // anonymous namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698