| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "components/favicon/core/fallback_url_util.h" | 5 #include "components/favicon/core/fallback_url_util.h" |
| 6 | 6 |
| 7 #include <stddef.h> |
| 8 |
| 7 #include "base/macros.h" | 9 #include "base/macros.h" |
| 8 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| 9 #include "testing/gtest/include/gtest/gtest.h" | 11 #include "testing/gtest/include/gtest/gtest.h" |
| 10 #include "url/gurl.h" | 12 #include "url/gurl.h" |
| 11 | 13 |
| 12 namespace favicon { | 14 namespace favicon { |
| 13 namespace { | 15 namespace { |
| 14 | 16 |
| 15 TEST(FallbackURLUtilTest, GetFallbackIconText) { | 17 TEST(FallbackURLUtilTest, GetFallbackIconText) { |
| 16 struct { | 18 struct { |
| (...skipping 28 matching lines...) Expand all Loading... |
| 45 for (size_t i = 0; i < arraysize(test_cases); ++i) { | 47 for (size_t i = 0; i < arraysize(test_cases); ++i) { |
| 46 base::string16 expected = base::ASCIIToUTF16(test_cases[i].expected); | 48 base::string16 expected = base::ASCIIToUTF16(test_cases[i].expected); |
| 47 GURL url(test_cases[i].url_str); | 49 GURL url(test_cases[i].url_str); |
| 48 EXPECT_EQ(expected, GetFallbackIconText(url)) << " for test_cases[" << i | 50 EXPECT_EQ(expected, GetFallbackIconText(url)) << " for test_cases[" << i |
| 49 << "]"; | 51 << "]"; |
| 50 } | 52 } |
| 51 } | 53 } |
| 52 | 54 |
| 53 } // namespace | 55 } // namespace |
| 54 } // namespace favicon | 56 } // namespace favicon |
| OLD | NEW |