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

Unified Diff: chrome/browser/captive_portal/captive_portal_browsertest.cc

Issue 242483003: Move CaptivePortalDetector to src/components/captive_portal (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Move CaptivePortalDetector to a component Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/captive_portal/captive_portal_browsertest.cc
diff --git a/chrome/browser/captive_portal/captive_portal_browsertest.cc b/chrome/browser/captive_portal/captive_portal_browsertest.cc
index 9f4ce844cc68163bdf580345c10b72b4bc397936..749139be58586823d921cd7f4fe02816826bc74b 100644
--- a/chrome/browser/captive_portal/captive_portal_browsertest.cc
+++ b/chrome/browser/captive_portal/captive_portal_browsertest.cc
@@ -53,6 +53,7 @@
#include "net/url_request/url_request_status.h"
#include "testing/gtest/include/gtest/gtest.h"
+using captive_portal::CaptivePortalDetector;
mmenke 2014/04/21 14:32:43 If we're going to share the captive_portal namespa
stevenjb 2014/04/21 16:42:27 Done.
using content::BrowserThread;
using content::URLRequestFailedJob;
using content::URLRequestMockHTTPJob;
@@ -685,7 +686,7 @@ class CaptivePortalObserver : public content::NotificationObserver {
int num_results_received() const { return num_results_received_; }
- Result captive_portal_result() const {
+ CaptivePortalResult captive_portal_result() const {
return captive_portal_result_;
}
@@ -709,7 +710,7 @@ class CaptivePortalObserver : public content::NotificationObserver {
CaptivePortalService* captive_portal_service_;
// Last result received.
- Result captive_portal_result_;
+ CaptivePortalResult captive_portal_result_;
content::NotificationRegistrar registrar_;
@@ -835,12 +836,14 @@ class CaptivePortalBrowserTest : public InProcessBrowserTest {
// triggering a captive portal check, which is expected to give the result
// |expected_result|. The page finishes loading, with a timeout, after the
// captive portal check.
- void SlowLoadNoCaptivePortal(Browser* browser, Result expected_result);
+ void SlowLoadNoCaptivePortal(Browser* browser,
+ CaptivePortalResult expected_result);
// Navigates |browser|'s active tab to an SSL timeout, expecting a captive
// portal check to be triggered and return a result which will indicates
// there's no detected captive portal.
- void FastTimeoutNoCaptivePortal(Browser* browser, Result expected_result);
+ void FastTimeoutNoCaptivePortal(Browser* browser,
+ CaptivePortalResult expected_result);
// Navigates the active tab to a slow loading SSL page, which will then
// trigger a captive portal test. The test is expected to find a captive
@@ -1051,7 +1054,8 @@ void CaptivePortalBrowserTest::NavigateToPageExpectNoTest(
}
void CaptivePortalBrowserTest::SlowLoadNoCaptivePortal(
- Browser* browser, Result expected_result) {
+ Browser* browser,
+ CaptivePortalResult expected_result) {
CaptivePortalTabReloader* tab_reloader =
GetTabReloader(browser->tab_strip_model()->GetActiveWebContents());
ASSERT_TRUE(tab_reloader);
@@ -1090,7 +1094,8 @@ void CaptivePortalBrowserTest::SlowLoadNoCaptivePortal(
}
void CaptivePortalBrowserTest::FastTimeoutNoCaptivePortal(
- Browser* browser, Result expected_result) {
+ Browser* browser,
+ CaptivePortalResult expected_result) {
ASSERT_NE(expected_result, RESULT_BEHIND_CAPTIVE_PORTAL);
// Set the load time to be large, so the timer won't trigger. The value is

Powered by Google App Engine
This is Rietveld 408576698