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

Side by Side Diff: net/proxy/proxy_script_fetcher_impl_unittest.cc

Issue 10068021: Fix file access on Chrome for ChromeOS on Linux (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed clang problem Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "net/proxy/proxy_script_fetcher_impl.h" 5 #include "net/proxy/proxy_script_fetcher_impl.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 118
119 class ProxyScriptFetcherImplTest : public PlatformTest { 119 class ProxyScriptFetcherImplTest : public PlatformTest {
120 public: 120 public:
121 ProxyScriptFetcherImplTest() 121 ProxyScriptFetcherImplTest()
122 : test_server_(TestServer::TYPE_HTTP, 122 : test_server_(TestServer::TYPE_HTTP,
123 net::TestServer::kLocalhost, 123 net::TestServer::kLocalhost,
124 FilePath(kDocRoot)) { 124 FilePath(kDocRoot)) {
125 } 125 }
126 126
127 static void SetUpTestCase() { 127 static void SetUpTestCase() {
128 URLRequest::AllowFileAccess(); 128 URLRequest::AllowAccessToAllFiles();
129 } 129 }
130 130
131 protected: 131 protected:
132 TestServer test_server_; 132 TestServer test_server_;
133 }; 133 };
134 134
135 TEST_F(ProxyScriptFetcherImplTest, FileUrl) { 135 TEST_F(ProxyScriptFetcherImplTest, FileUrl) {
136 scoped_refptr<URLRequestContext> context(new RequestContext); 136 scoped_refptr<URLRequestContext> context(new RequestContext);
137 ProxyScriptFetcherImpl pac_fetcher(context); 137 ProxyScriptFetcherImpl pac_fetcher(context);
138 138
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
409 { 409 {
410 GURL url(kEncodedUrlBroken); 410 GURL url(kEncodedUrlBroken);
411 string16 text; 411 string16 text;
412 TestCompletionCallback callback; 412 TestCompletionCallback callback;
413 int result = pac_fetcher.Fetch(url, &text, callback.callback()); 413 int result = pac_fetcher.Fetch(url, &text, callback.callback());
414 EXPECT_EQ(ERR_FAILED, result); 414 EXPECT_EQ(ERR_FAILED, result);
415 } 415 }
416 } 416 }
417 417
418 } // namespace net 418 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698