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 <algorithm> | 5 #include <algorithm> |
6 #include <string> | 6 #include <string> |
7 | 7 |
8 #include "net/base/escape.h" | 8 #include "net/base/escape.h" |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
11 #include "base/i18n/icu_string_conversions.h" | |
12 #include "base/strings/string_util.h" | 11 #include "base/strings/string_util.h" |
13 #include "base/strings/stringprintf.h" | 12 #include "base/strings/stringprintf.h" |
14 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
15 #include "testing/gtest/include/gtest/gtest.h" | 14 #include "testing/gtest/include/gtest/gtest.h" |
16 | 15 |
17 namespace net { | 16 namespace net { |
18 namespace { | 17 namespace { |
19 | 18 |
20 struct EscapeCase { | 19 struct EscapeCase { |
21 const char* input; | 20 const char* input; |
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
450 }; | 449 }; |
451 for (size_t i = 0; i < arraysize(tests); ++i) { | 450 for (size_t i = 0; i < arraysize(tests); ++i) { |
452 base::string16 result = UnescapeForHTML(base::ASCIIToUTF16(tests[i].input)); | 451 base::string16 result = UnescapeForHTML(base::ASCIIToUTF16(tests[i].input)); |
453 EXPECT_EQ(base::ASCIIToUTF16(tests[i].expected_output), result); | 452 EXPECT_EQ(base::ASCIIToUTF16(tests[i].expected_output), result); |
454 } | 453 } |
455 } | 454 } |
456 | 455 |
457 | 456 |
458 } // namespace | 457 } // namespace |
459 } // namespace net | 458 } // namespace net |
OLD | NEW |