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

Side by Side Diff: net/base/net_util_unittest.cc

Issue 1614001: Pull latest googleurl to get it to stop unescaping at signs in paths.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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
« no previous file with comments | « net/base/net_util.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/base/net_util.h" 5 #include "net/base/net_util.h"
6 6
7 #include "base/file_path.h" 7 #include "base/file_path.h"
8 #include "base/format_macros.h" 8 #include "base/format_macros.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "base/sys_string_conversions.h" 10 #include "base/sys_string_conversions.h"
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 { 547 {
548 "http://username:password@google.com", 548 "http://username:password@google.com",
549 L"username", 549 L"username",
550 L"password", 550 L"password",
551 }, 551 },
552 { // Test for http://crbug.com/19200 552 { // Test for http://crbug.com/19200
553 "http://username:p@ssword@google.com", 553 "http://username:p@ssword@google.com",
554 L"username", 554 L"username",
555 L"p@ssword", 555 L"p@ssword",
556 }, 556 },
557 { // Special URL characters should be unescaped.
558 "http://username:p%3fa%26s%2fs%23@google.com",
559 L"username",
560 L"p?a&s/s#",
561 },
557 { // Username contains %20. 562 { // Username contains %20.
558 "http://use rname:password@google.com", 563 "http://use rname:password@google.com",
559 L"use rname", 564 L"use rname",
560 L"password", 565 L"password",
561 }, 566 },
562 { // Keep %00 as is. 567 { // Keep %00 as is.
563 "http://use%00rname:password@google.com", 568 "http://use%00rname:password@google.com",
564 L"use%00rname", 569 L"use%00rname",
565 L"password", 570 L"password",
566 }, 571 },
(...skipping 1052 matching lines...) Expand 10 before | Expand all | Expand 10 after
1619 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(invalid); ++i) { 1624 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(invalid); ++i) {
1620 net::SetExplicitlyAllowedPorts(invalid[i]); 1625 net::SetExplicitlyAllowedPorts(invalid[i]);
1621 EXPECT_EQ(0, static_cast<int>(net::explicitly_allowed_ports.size())); 1626 EXPECT_EQ(0, static_cast<int>(net::explicitly_allowed_ports.size()));
1622 } 1627 }
1623 1628
1624 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(valid); ++i) { 1629 for (size_t i = 0; i < ARRAYSIZE_UNSAFE(valid); ++i) {
1625 net::SetExplicitlyAllowedPorts(valid[i]); 1630 net::SetExplicitlyAllowedPorts(valid[i]);
1626 EXPECT_EQ(i, net::explicitly_allowed_ports.size()); 1631 EXPECT_EQ(i, net::explicitly_allowed_ports.size());
1627 } 1632 }
1628 } 1633 }
OLDNEW
« no previous file with comments | « net/base/net_util.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698