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

Side by Side Diff: net/tools/dump_cache/url_utilities_unittest.cc

Issue 16652007: Use a direct include of strings headers in net/test/, net/third_party/, net/tools/, net/udp/, net/u… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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/tools/dump_cache/url_utilities.cc ('k') | net/tools/fetch/fetch_client.cc » ('j') | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/tools/dump_cache/url_utilities.h" 5 #include "net/tools/dump_cache/url_utilities.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/stringprintf.h" 10 #include "base/strings/stringprintf.h"
11 #include "testing/gtest/include/gtest/gtest.h" 11 #include "testing/gtest/include/gtest/gtest.h"
12 12
13 namespace net { 13 namespace net {
14 14
15 TEST(UrlUtilitiesTest, GetUrlHost) { 15 TEST(UrlUtilitiesTest, GetUrlHost) {
16 EXPECT_EQ("www.foo.com", 16 EXPECT_EQ("www.foo.com",
17 UrlUtilities::GetUrlHost("http://www.foo.com")); 17 UrlUtilities::GetUrlHost("http://www.foo.com"));
18 EXPECT_EQ("www.foo.com", 18 EXPECT_EQ("www.foo.com",
19 UrlUtilities::GetUrlHost("http://www.foo.com:80")); 19 UrlUtilities::GetUrlHost("http://www.foo.com:80"));
20 EXPECT_EQ("www.foo.com", 20 EXPECT_EQ("www.foo.com",
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 EXPECT_EQ("%1", UrlUtilities::Unescape("%1")); 105 EXPECT_EQ("%1", UrlUtilities::Unescape("%1"));
106 EXPECT_EQ("%1x", UrlUtilities::Unescape("%1x")); 106 EXPECT_EQ("%1x", UrlUtilities::Unescape("%1x"));
107 EXPECT_EQ("%%", UrlUtilities::Unescape("%%")); 107 EXPECT_EQ("%%", UrlUtilities::Unescape("%%"));
108 // Escapes following non-escapes. 108 // Escapes following non-escapes.
109 EXPECT_EQ("%!", UrlUtilities::Unescape("%%21")); 109 EXPECT_EQ("%!", UrlUtilities::Unescape("%%21"));
110 EXPECT_EQ("%2!", UrlUtilities::Unescape("%2%21")); 110 EXPECT_EQ("%2!", UrlUtilities::Unescape("%2%21"));
111 } 111 }
112 112
113 } // namespace net 113 } // namespace net
114 114
OLDNEW
« no previous file with comments | « net/tools/dump_cache/url_utilities.cc ('k') | net/tools/fetch/fetch_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698