| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "base/strings/string_util.h" | 6 #include "base/strings/string_util.h" |
| 7 #include "base/strings/stringprintf.h" | 7 #include "base/strings/stringprintf.h" |
| 8 #include "base/strings/utf_string_conversions.h" | 8 #include "base/strings/utf_string_conversions.h" |
| 9 #include "chrome/browser/chrome_notification_types.h" | 9 #include "chrome/browser/chrome_notification_types.h" |
| 10 #include "chrome/browser/ui/browser.h" | 10 #include "chrome/browser/ui/browser.h" |
| (...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 129 | 129 |
| 130 // Visit a page that tries to establish WebSocket connection. The title | 130 // Visit a page that tries to establish WebSocket connection. The title |
| 131 // of the page will be 'PASS' on success. | 131 // of the page will be 'PASS' on success. |
| 132 GURL::Replacements replacements; | 132 GURL::Replacements replacements; |
| 133 replacements.SetSchemeStr("http"); | 133 replacements.SetSchemeStr("http"); |
| 134 ui_test_utils::NavigateToURL(browser(), | 134 ui_test_utils::NavigateToURL(browser(), |
| 135 ws_server.GetURL("proxied_request_check.html") | 135 ws_server.GetURL("proxied_request_check.html") |
| 136 .ReplaceComponents(replacements)); | 136 .ReplaceComponents(replacements)); |
| 137 | 137 |
| 138 const base::string16 result = watcher.WaitAndGetTitle(); | 138 const base::string16 result = watcher.WaitAndGetTitle(); |
| 139 EXPECT_TRUE(EqualsASCII(result, "PASS")); | 139 EXPECT_TRUE(base::EqualsASCII(result, "PASS")); |
| 140 EXPECT_TRUE(observer.auth_handled()); | 140 EXPECT_TRUE(observer.auth_handled()); |
| 141 } | 141 } |
| 142 | 142 |
| 143 // Fetch PAC script via an http:// URL. | 143 // Fetch PAC script via an http:// URL. |
| 144 class HttpProxyScriptBrowserTest : public InProcessBrowserTest { | 144 class HttpProxyScriptBrowserTest : public InProcessBrowserTest { |
| 145 public: | 145 public: |
| 146 HttpProxyScriptBrowserTest() | 146 HttpProxyScriptBrowserTest() |
| 147 : http_server_(net::SpawnedTestServer::TYPE_HTTP, | 147 : http_server_(net::SpawnedTestServer::TYPE_HTTP, |
| 148 net::SpawnedTestServer::kLocalhost, | 148 net::SpawnedTestServer::kLocalhost, |
| 149 base::FilePath(FILE_PATH_LITERAL("chrome/test/data"))) { | 149 base::FilePath(FILE_PATH_LITERAL("chrome/test/data"))) { |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 269 | 269 |
| 270 private: | 270 private: |
| 271 DISALLOW_COPY_AND_ASSIGN(OutOfProcessProxyResolverBrowserTest); | 271 DISALLOW_COPY_AND_ASSIGN(OutOfProcessProxyResolverBrowserTest); |
| 272 }; | 272 }; |
| 273 | 273 |
| 274 IN_PROC_BROWSER_TEST_F(OutOfProcessProxyResolverBrowserTest, Verify) { | 274 IN_PROC_BROWSER_TEST_F(OutOfProcessProxyResolverBrowserTest, Verify) { |
| 275 VerifyProxyScript(browser()); | 275 VerifyProxyScript(browser()); |
| 276 } | 276 } |
| 277 | 277 |
| 278 } // namespace | 278 } // namespace |
| OLD | NEW |