summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/proxy/dhcp_proxy_script_fetcher_factory.cc4
-rw-r--r--net/proxy/dhcp_proxy_script_fetcher_factory.h2
-rw-r--r--net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc6
3 files changed, 8 insertions, 4 deletions
diff --git a/net/proxy/dhcp_proxy_script_fetcher_factory.cc b/net/proxy/dhcp_proxy_script_fetcher_factory.cc
index faedf86..01ede05 100644
--- a/net/proxy/dhcp_proxy_script_fetcher_factory.cc
+++ b/net/proxy/dhcp_proxy_script_fetcher_factory.cc
@@ -15,9 +15,7 @@ namespace net {
DhcpProxyScriptFetcherFactory::DhcpProxyScriptFetcherFactory()
: feature_enabled_(false) {
- // TODO(joi): Change this default, and the comment on |set_enabled()|,
- // when the time is right.
- set_enabled(false);
+ set_enabled(true);
}
DhcpProxyScriptFetcher* DhcpProxyScriptFetcherFactory::Create(
diff --git a/net/proxy/dhcp_proxy_script_fetcher_factory.h b/net/proxy/dhcp_proxy_script_fetcher_factory.h
index 02f1dcd..273f321 100644
--- a/net/proxy/dhcp_proxy_script_fetcher_factory.h
+++ b/net/proxy/dhcp_proxy_script_fetcher_factory.h
@@ -47,7 +47,7 @@ class NET_API DhcpProxyScriptFetcherFactory {
// Attempts to enable/disable the DHCP WPAD feature. Does nothing
// if |IsSupported()| returns false.
//
- // The current default is |enabled() == false|.
+ // The default is |enabled() == true|.
void set_enabled(bool enabled);
// Returns true if the DHCP WPAD feature is enabled. Always returns
diff --git a/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc b/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc
index 902a41b..97730bc 100644
--- a/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc
+++ b/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc
@@ -9,8 +9,10 @@
namespace net {
namespace {
+
TEST(DhcpProxyScriptFetcherFactoryTest, DoNothingWhenDisabled) {
DhcpProxyScriptFetcherFactory factory;
+ factory.set_enabled(false);
scoped_ptr<DhcpProxyScriptFetcher> fetcher(factory.Create(NULL));
EXPECT_EQ("", fetcher->GetFetcherName());
}
@@ -36,7 +38,11 @@ TEST(DhcpProxyScriptFetcherFactoryTest, IsSupported) {
TEST(DhcpProxyScriptFetcherFactoryTest, SetEnabled) {
DhcpProxyScriptFetcherFactory factory;
+#if defined(OS_WIN)
+ EXPECT_TRUE(factory.enabled());
+#else
EXPECT_FALSE(factory.enabled());
+#endif // defined(OS_WIN)
factory.set_enabled(false);
EXPECT_FALSE(factory.enabled());