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

Unified Diff: chrome/browser/captive_portal/captive_portal_service.h

Issue 10795038: Enable captive portal detection by default. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Missed the browser_tests Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/captive_portal/captive_portal_service.h
===================================================================
--- chrome/browser/captive_portal/captive_portal_service.h (revision 148558)
+++ chrome/browser/captive_portal/captive_portal_service.h (working copy)
@@ -76,6 +76,13 @@
// checks return INTERNET_CONNECTED.
bool enabled() const { return enabled_; }
+ // Used to disable captive portal detection so it doesn't interfere with
+ // tests. Should be called before the service is created.
+ static void set_is_disabled_for_testing(bool is_disabled_for_testing) {
+ is_disabled_for_testing_ = is_disabled_for_testing;
+ }
+ static bool is_disabled_for_testing() { return is_disabled_for_testing_; }
+
private:
friend class CaptivePortalServiceTest;
friend class CaptivePortalBrowserTest;
@@ -211,6 +218,8 @@
base::OneShotTimer<CaptivePortalService> check_captive_portal_timer_;
+ static bool is_disabled_for_testing_;
+
DISALLOW_COPY_AND_ASSIGN(CaptivePortalService);
};
« no previous file with comments | « chrome/browser/captive_portal/captive_portal_browsertest.cc ('k') | chrome/browser/captive_portal/captive_portal_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698