OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 <stddef.h> | 5 #include <stddef.h> |
| 6 #include <string.h> |
| 7 #include <string> |
6 | 8 |
7 #include "base/macros.h" | 9 #include "base/macros.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
9 #include "third_party/icu/source/common/unicode/ucnv.h" | 11 #include "third_party/icu/source/common/unicode/ucnv.h" |
| 12 #include "third_party/icu/source/common/unicode/urename.h" |
| 13 #include "third_party/icu/source/common/unicode/utypes.h" |
| 14 #include "url/third_party/mozilla/url_parse.h" |
10 #include "url/url_canon.h" | 15 #include "url/url_canon.h" |
11 #include "url/url_canon_icu.h" | 16 #include "url/url_canon_icu.h" |
12 #include "url/url_canon_stdstring.h" | 17 #include "url/url_canon_stdstring.h" |
13 #include "url/url_test_utils.h" | 18 #include "url/url_test_utils.h" |
14 | 19 |
15 namespace url { | 20 namespace url { |
16 | 21 |
17 using test_utils::WStringToUTF16; | 22 using test_utils::WStringToUTF16; |
18 | 23 |
19 namespace { | 24 namespace { |
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 StdStringCanonOutput output(&out_str); | 158 StdStringCanonOutput output(&out_str); |
154 Component out_comp; | 159 Component out_comp; |
155 CanonicalizeQuery("a \x00z\x01", Component(0, 5), NULL, &output, &out_comp); | 160 CanonicalizeQuery("a \x00z\x01", Component(0, 5), NULL, &output, &out_comp); |
156 output.Complete(); | 161 output.Complete(); |
157 EXPECT_EQ("?a%20%00z%01", out_str); | 162 EXPECT_EQ("?a%20%00z%01", out_str); |
158 } | 163 } |
159 | 164 |
160 } // namespace | 165 } // namespace |
161 | 166 |
162 } // namespace url | 167 } // namespace url |
OLD | NEW |