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

Unified Diff: chrome_frame/test/automation_client_mock.cc

Issue 5698005: Add support for gcf:about:plugins in chrome frame full tab mode. The URL vali... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome_frame/navigation_constraints.cc ('k') | chrome_frame/test/util_unittests.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome_frame/test/automation_client_mock.cc
===================================================================
--- chrome_frame/test/automation_client_mock.cc (revision 68895)
+++ chrome_frame/test/automation_client_mock.cc (working copy)
@@ -4,9 +4,10 @@
#include "chrome_frame/test/automation_client_mock.h"
#include "base/callback.h"
-#include "net/base/net_errors.h"
#include "chrome_frame/custom_sync_call_context.h"
+#include "chrome_frame/navigation_constraints.h"
#include "chrome_frame/test/chrome_frame_test_utils.h"
+#include "net/base/net_errors.h"
#define GMOCK_MUTANT_INCLUDE_LATE_OBJECT_BINDING
#include "testing/gmock_mutant.h"
@@ -85,8 +86,8 @@
delete context;
}
-ACTION_P4(InitiateNavigation, client, url, referrer, privileged) {
- client->InitiateNavigation(url, referrer, privileged);
+ACTION_P4(InitiateNavigation, client, url, referrer, constraints) {
+ client->InitiateNavigation(url, referrer, constraints);
}
// We mock ChromeFrameDelegate only. The rest is with real AutomationProxy
@@ -151,6 +152,8 @@
TEST(CFACWithChrome, NavigateOk) {
MockCFDelegate cfd;
+ NavigationConstraintsImpl navigation_constraints;
+
chrome_frame_test::TimedMsgLoop loop;
const std::string url = "about:version";
const FilePath profile_path(
@@ -162,7 +165,8 @@
EXPECT_CALL(cfd, OnAutomationServerReady())
.WillOnce(InitiateNavigation(client.get(),
- url, std::string(), false));
+ url, std::string(),
+ &navigation_constraints));
EXPECT_CALL(cfd, GetBounds(_)).Times(testing::AnyNumber());
@@ -196,6 +200,7 @@
TEST(CFACWithChrome, NavigateFailed) {
MockCFDelegate cfd;
+ NavigationConstraintsImpl navigation_constraints;
chrome_frame_test::TimedMsgLoop loop;
const FilePath profile_path(
chrome_frame_test::GetProfilePath(L"Adam.N.Epilinter"));
@@ -210,7 +215,7 @@
EXPECT_CALL(cfd, OnAutomationServerReady())
.WillOnce(testing::IgnoreResult(testing::InvokeWithoutArgs(CreateFunctor(
client.get(), &ChromeFrameAutomationClient::InitiateNavigation,
- url, std::string(), false))));
+ url, std::string(), &navigation_constraints))));
EXPECT_CALL(cfd, GetBounds(_)).Times(testing::AnyNumber());
EXPECT_CALL(cfd, OnNavigationStateChanged(_, _)).Times(testing::AnyNumber());
@@ -420,6 +425,8 @@
TEST_F(CFACMockTest, NavigateTwiceAfterInitToSameUrl) {
int timeout = 500;
+ NavigationConstraintsImpl navigation_constraints;
+
CreateTab();
SetAutomationServerOk(1);
@@ -440,7 +447,7 @@
EXPECT_CALL(cfd_, OnAutomationServerReady())
.WillOnce(InitiateNavigation(client_.get(),
std::string("http://www.nonexistent.com"),
- std::string(), false));
+ std::string(), &navigation_constraints));
EXPECT_CALL(mock_proxy_, SendAsAsync(testing::Property(
&IPC::SyncMessage::type, AutomationMsg_NavigateInExternalTab::ID),
« no previous file with comments | « chrome_frame/navigation_constraints.cc ('k') | chrome_frame/test/util_unittests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698