Index: chrome/browser/net/proxy_browsertest.cc |
diff --git a/chrome/browser/net/proxy_browsertest.cc b/chrome/browser/net/proxy_browsertest.cc |
index f2453ea9d816794b392a4cb642f41f07a13bc188..8ba5fa5bfd7f881427d7d2a44c74802307bb627b 100644 |
--- a/chrome/browser/net/proxy_browsertest.cc |
+++ b/chrome/browser/net/proxy_browsertest.cc |
@@ -21,6 +21,7 @@ |
#include "content/public/browser/notification_source.h" |
#include "content/public/browser/web_contents.h" |
#include "content/public/browser/web_contents_observer.h" |
+#include "content/public/common/content_switches.h" |
hush (inactive)
2016/09/09 22:24:16
Except for this line, are the changes in the file
Nate Fischer
2016/09/09 22:55:31
Whoops! I think that was generated by "clang-forma
|
#include "content/public/test/browser_test_utils.h" |
#include "net/test/embedded_test_server/embedded_test_server.h" |
#include "net/test/spawned_test_server/spawned_test_server.h" |
@@ -29,8 +30,8 @@ |
namespace { |
// PAC script that sends all requests to an invalid proxy server. |
-const base::FilePath::CharType kPACScript[] = FILE_PATH_LITERAL( |
- "bad_server.pac"); |
+const base::FilePath::CharType kPACScript[] = |
+ FILE_PATH_LITERAL("bad_server.pac"); |
// Verify kPACScript is installed as the PAC script. |
void VerifyProxyScript(Browser* browser) { |
@@ -81,8 +82,7 @@ class ProxyBrowserTest : public InProcessBrowserTest { |
ProxyBrowserTest() |
: proxy_server_(net::SpawnedTestServer::TYPE_BASIC_AUTH_PROXY, |
net::SpawnedTestServer::kLocalhost, |
- base::FilePath()) { |
- } |
+ base::FilePath()) {} |
void SetUp() override { |
ASSERT_TRUE(proxy_server_.Start()); |
@@ -98,7 +98,6 @@ class ProxyBrowserTest : public InProcessBrowserTest { |
net::SpawnedTestServer proxy_server_; |
private: |
- |
DISALLOW_COPY_AND_ASSIGN(ProxyBrowserTest); |
}; |
@@ -159,8 +158,10 @@ class HttpProxyScriptBrowserTest : public InProcessBrowserTest { |
void SetUpCommandLine(base::CommandLine* command_line) override { |
base::FilePath pac_script_path(FILE_PATH_LITERAL("/")); |
- command_line->AppendSwitchASCII(switches::kProxyPacUrl, http_server_.GetURL( |
- pac_script_path.Append(kPACScript).MaybeAsASCII()).spec()); |
+ command_line->AppendSwitchASCII( |
+ switches::kProxyPacUrl, |
+ http_server_.GetURL(pac_script_path.Append(kPACScript).MaybeAsASCII()) |
+ .spec()); |
} |
private: |
@@ -180,10 +181,12 @@ class FileProxyScriptBrowserTest : public InProcessBrowserTest { |
~FileProxyScriptBrowserTest() override {} |
void SetUpCommandLine(base::CommandLine* command_line) override { |
- command_line->AppendSwitchASCII(switches::kProxyPacUrl, |
+ command_line->AppendSwitchASCII( |
+ switches::kProxyPacUrl, |
ui_test_utils::GetTestUrl( |
base::FilePath(base::FilePath::kCurrentDirectory), |
- base::FilePath(kPACScript)).spec()); |
+ base::FilePath(kPACScript)) |
+ .spec()); |
} |
private: |
@@ -200,8 +203,7 @@ class FtpProxyScriptBrowserTest : public InProcessBrowserTest { |
FtpProxyScriptBrowserTest() |
: ftp_server_(net::SpawnedTestServer::TYPE_FTP, |
net::SpawnedTestServer::kLocalhost, |
- base::FilePath(FILE_PATH_LITERAL("chrome/test/data"))) { |
- } |
+ base::FilePath(FILE_PATH_LITERAL("chrome/test/data"))) {} |
~FtpProxyScriptBrowserTest() override {} |
void SetUp() override { |
@@ -235,12 +237,13 @@ class DataProxyScriptBrowserTest : public InProcessBrowserTest { |
void SetUpCommandLine(base::CommandLine* command_line) override { |
std::string contents; |
// Read in kPACScript contents. |
- ASSERT_TRUE(base::ReadFileToString(ui_test_utils::GetTestFilePath( |
- base::FilePath(base::FilePath::kCurrentDirectory), |
- base::FilePath(kPACScript)), |
+ ASSERT_TRUE(base::ReadFileToString( |
+ ui_test_utils::GetTestFilePath( |
+ base::FilePath(base::FilePath::kCurrentDirectory), |
+ base::FilePath(kPACScript)), |
&contents)); |
command_line->AppendSwitchASCII(switches::kProxyPacUrl, |
- std::string("data:,") + contents); |
+ std::string("data:,") + contents); |
} |
private: |
@@ -260,12 +263,13 @@ class OutOfProcessProxyResolverBrowserTest : public InProcessBrowserTest { |
void SetUpCommandLine(base::CommandLine* command_line) override { |
std::string contents; |
// Read in kPACScript contents. |
- ASSERT_TRUE(base::ReadFileToString(ui_test_utils::GetTestFilePath( |
- base::FilePath(base::FilePath::kCurrentDirectory), |
- base::FilePath(kPACScript)), |
+ ASSERT_TRUE(base::ReadFileToString( |
+ ui_test_utils::GetTestFilePath( |
+ base::FilePath(base::FilePath::kCurrentDirectory), |
+ base::FilePath(kPACScript)), |
&contents)); |
- command_line->AppendSwitchASCII( |
- switches::kProxyPacUrl, "data:," + contents); |
+ command_line->AppendSwitchASCII(switches::kProxyPacUrl, |
+ "data:," + contents); |
command_line->AppendSwitch(switches::kV8PacMojoOutOfProcess); |
} |