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

Side by Side Diff: ios/web/public/test/fakes/test_navigation_manager.h

Issue 2745873002: Created NavigationManager::CopyStateFromAndPrune(). (Closed)
Patch Set: Added no-op tests, addressed Eugene's comments Created 3 years, 9 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 2016 The Chromium Authors. All rights reserved. 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 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 #ifndef IOS_WEB_PUBLIC_TEST_FAKES_TEST_NAVIGATION_MANAGER_H_ 5 #ifndef IOS_WEB_PUBLIC_TEST_FAKES_TEST_NAVIGATION_MANAGER_H_
6 #define IOS_WEB_PUBLIC_TEST_FAKES_TEST_NAVIGATION_MANAGER_H_ 6 #define IOS_WEB_PUBLIC_TEST_FAKES_TEST_NAVIGATION_MANAGER_H_
7 7
8 #import "ios/web/public/navigation_item.h" 8 #import "ios/web/public/navigation_item.h"
9 #include "ios/web/public/navigation_item_list.h" 9 #include "ios/web/public/navigation_item_list.h"
10 #import "ios/web/public/navigation_manager.h" 10 #import "ios/web/public/navigation_manager.h"
(...skipping 26 matching lines...) Expand all
37 bool RemoveItemAtIndex(int index) override; 37 bool RemoveItemAtIndex(int index) override;
38 bool CanGoBack() const override; 38 bool CanGoBack() const override;
39 bool CanGoForward() const override; 39 bool CanGoForward() const override;
40 bool CanGoToOffset(int offset) const override; 40 bool CanGoToOffset(int offset) const override;
41 void GoBack() override; 41 void GoBack() override;
42 void GoForward() override; 42 void GoForward() override;
43 void GoToIndex(int index) override; 43 void GoToIndex(int index) override;
44 void Reload(ReloadType reload_type, bool check_for_reposts) override; 44 void Reload(ReloadType reload_type, bool check_for_reposts) override;
45 NavigationItemList GetBackwardItems() const override; 45 NavigationItemList GetBackwardItems() const override;
46 NavigationItemList GetForwardItems() const override; 46 NavigationItemList GetForwardItems() const override;
47 void CopyStateFromAndPrune(const NavigationManager* source) override;
48 bool CanPruneAllButLastCommittedItem() const override;
47 void OverrideDesktopUserAgentForNextPendingItem() override; 49 void OverrideDesktopUserAgentForNextPendingItem() override;
48 50
49 // Setters for test data. 51 // Setters for test data.
50 // Sets a value for last committed item that will be returned by 52 // Sets a value for last committed item that will be returned by
51 // GetLastCommittedItem(). 53 // GetLastCommittedItem().
52 void SetLastCommittedItem(NavigationItem* item); 54 void SetLastCommittedItem(NavigationItem* item);
53 55
54 // Sets a value for pending item that will be returned by GetPendingItem(). 56 // Sets a value for pending item that will be returned by GetPendingItem().
55 void SetPendingItem(NavigationItem* item); 57 void SetPendingItem(NavigationItem* item);
56 58
(...skipping 14 matching lines...) Expand all
71 int items_index_; 73 int items_index_;
72 // Individual backing instance variables for Set* test set up methods. 74 // Individual backing instance variables for Set* test set up methods.
73 NavigationItem* pending_item_; 75 NavigationItem* pending_item_;
74 NavigationItem* last_committed_item_; 76 NavigationItem* last_committed_item_;
75 NavigationItem* visible_item_; 77 NavigationItem* visible_item_;
76 }; 78 };
77 79
78 } // namespace web 80 } // namespace web
79 81
80 #endif // IOS_WEB_PUBLIC_TEST_FAKES_TEST_NAVIGATION_MANAGER_H_ 82 #endif // IOS_WEB_PUBLIC_TEST_FAKES_TEST_NAVIGATION_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698