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

Side by Side Diff: ios/web/web_state/web_state_delegate_bridge_unittest.mm

Issue 2074733002: Add public API for handling Javascript alerts and prompt. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Replace BOOL with bool in unittest. Created 4 years, 5 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 #import "ios/web/public/web_state/web_state_delegate_bridge.h" 5 #import "ios/web/public/web_state/web_state_delegate_bridge.h"
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #import "base/mac/scoped_nsobject.h" 9 #import "base/mac/scoped_nsobject.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 EXPECT_EQ(context_menu_params.menu_title, result_params->menu_title); 61 EXPECT_EQ(context_menu_params.menu_title, result_params->menu_title);
62 EXPECT_EQ(context_menu_params.link_url, result_params->link_url); 62 EXPECT_EQ(context_menu_params.link_url, result_params->link_url);
63 EXPECT_EQ(context_menu_params.src_url, result_params->src_url); 63 EXPECT_EQ(context_menu_params.src_url, result_params->src_url);
64 EXPECT_EQ(context_menu_params.referrer_policy, 64 EXPECT_EQ(context_menu_params.referrer_policy,
65 result_params->referrer_policy); 65 result_params->referrer_policy);
66 EXPECT_EQ(context_menu_params.view, result_params->view); 66 EXPECT_EQ(context_menu_params.view, result_params->view);
67 EXPECT_EQ(context_menu_params.location.x, result_params->location.x); 67 EXPECT_EQ(context_menu_params.location.x, result_params->location.x);
68 EXPECT_EQ(context_menu_params.location.y, result_params->location.y); 68 EXPECT_EQ(context_menu_params.location.y, result_params->location.y);
69 } 69 }
70 70
71 // Tests |GetJavaScriptDialogPresenter| forwarding.
72 TEST_F(WebStateDelegateBridgeTest, GetJavaScriptDialogPresenter) {
73 EXPECT_FALSE([delegate_ javaScriptDialogPresenterRequested]);
74 bridge_->GetJavaScriptDialogPresenter(nullptr);
75 EXPECT_TRUE([delegate_ javaScriptDialogPresenterRequested]);
76 }
77
71 } // namespace web 78 } // namespace web
OLDNEW
« no previous file with comments | « ios/web/web_state/web_state_delegate_bridge.mm ('k') | ios/web/web_state/web_state_delegate_stub.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698