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

Side by Side Diff: chrome/test/chromedriver/session_commands.cc

Issue 1669453002: [chromedriver] Apply page load timeout to slow cross-process navigations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 #include "chrome/test/chromedriver/session_commands.h" 5 #include "chrome/test/chromedriver/session_commands.h"
6 6
7 #include <list> 7 #include <list>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after
462 Status status = session->GetTargetWindow(&web_view); 462 Status status = session->GetTargetWindow(&web_view);
463 if (status.IsError()) 463 if (status.IsError())
464 return status; 464 return status;
465 465
466 status = web_view->ConnectIfNecessary(); 466 status = web_view->ConnectIfNecessary();
467 if (status.IsError()) 467 if (status.IsError())
468 return status; 468 return status;
469 469
470 bool is_pending; 470 bool is_pending;
471 status = web_view->IsPendingNavigation( 471 status = web_view->IsPendingNavigation(
472 session->GetCurrentFrameId(), &is_pending); 472 session->GetCurrentFrameId(), nullptr, &is_pending);
473 if (status.IsError()) 473 if (status.IsError())
474 return status; 474 return status;
475 value->reset(new base::FundamentalValue(is_pending)); 475 value->reset(new base::FundamentalValue(is_pending));
476 return Status(kOk); 476 return Status(kOk);
477 } 477 }
478 478
479 Status ExecuteGetLocation( 479 Status ExecuteGetLocation(
480 Session* session, 480 Session* session,
481 const base::DictionaryValue& params, 481 const base::DictionaryValue& params,
482 scoped_ptr<base::Value>* value) { 482 scoped_ptr<base::Value>* value) {
(...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
710 Status ExecuteSetAutoReporting( 710 Status ExecuteSetAutoReporting(
711 Session* session, 711 Session* session,
712 const base::DictionaryValue& params, 712 const base::DictionaryValue& params,
713 scoped_ptr<base::Value>* value) { 713 scoped_ptr<base::Value>* value) {
714 bool enabled; 714 bool enabled;
715 if (!params.GetBoolean("enabled", &enabled)) 715 if (!params.GetBoolean("enabled", &enabled))
716 return Status(kUnknownError, "missing parameter 'enabled'"); 716 return Status(kUnknownError, "missing parameter 'enabled'");
717 session->auto_reporting_enabled = enabled; 717 session->auto_reporting_enabled = enabled;
718 return Status(kOk); 718 return Status(kOk);
719 } 719 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698