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

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

Issue 2644223002: Integration tests for WebStateDelegate::OnAuthRequired callback. (Closed)
Patch Set: Addressed review comments Created 3 years, 11 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
« no previous file with comments | « ios/web/BUILD.gn ('k') | ios/web/public/test/fakes/test_web_state_delegate.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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_WEB_STATE_DELEGATE_H_ 5 #ifndef IOS_WEB_PUBLIC_TEST_FAKES_TEST_WEB_STATE_DELEGATE_H_
6 #define IOS_WEB_PUBLIC_TEST_FAKES_TEST_WEB_STATE_DELEGATE_H_ 6 #define IOS_WEB_PUBLIC_TEST_FAKES_TEST_WEB_STATE_DELEGATE_H_
7 7
8 #import <Foundation/Foundation.h> 8 #import <Foundation/Foundation.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 // called. 58 // called.
59 bool get_java_script_dialog_presenter_called() const { 59 bool get_java_script_dialog_presenter_called() const {
60 return get_java_script_dialog_presenter_called_; 60 return get_java_script_dialog_presenter_called_;
61 } 61 }
62 62
63 // Returns the last HTTP Authentication request passed to |OnAuthRequired|. 63 // Returns the last HTTP Authentication request passed to |OnAuthRequired|.
64 TestAuthenticationRequest* last_authentication_request() const { 64 TestAuthenticationRequest* last_authentication_request() const {
65 return last_authentication_request_.get(); 65 return last_authentication_request_.get();
66 } 66 }
67 67
68 // Clears the last HTTP Authentication request passed to |OnAuthRequired|.
69 void ClearLastAuthenticationRequest() {
70 last_authentication_request_.reset();
71 }
72
68 private: 73 private:
69 bool load_progress_changed_called_ = false; 74 bool load_progress_changed_called_ = false;
70 bool handle_context_menu_called_ = false; 75 bool handle_context_menu_called_ = false;
71 bool get_java_script_dialog_presenter_called_ = false; 76 bool get_java_script_dialog_presenter_called_ = false;
72 TestJavaScriptDialogPresenter java_script_dialog_presenter_; 77 TestJavaScriptDialogPresenter java_script_dialog_presenter_;
73 std::unique_ptr<TestAuthenticationRequest> last_authentication_request_; 78 std::unique_ptr<TestAuthenticationRequest> last_authentication_request_;
74 }; 79 };
75 80
76 } // namespace web 81 } // namespace web
77 82
78 #endif // IOS_WEB_PUBLIC_TEST_FAKES_TEST_WEB_STATE_DELEGATE_H_ 83 #endif // IOS_WEB_PUBLIC_TEST_FAKES_TEST_WEB_STATE_DELEGATE_H_
OLDNEW
« no previous file with comments | « ios/web/BUILD.gn ('k') | ios/web/public/test/fakes/test_web_state_delegate.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698