| Index: components/password_manager/core/browser/password_ui_utils_unittest.cc
|
| diff --git a/components/password_manager/core/browser/password_ui_utils_unittest.cc b/components/password_manager/core/browser/password_ui_utils_unittest.cc
|
| index 780fa8c50e468c9fde8c98658af768d3efbd845c..40f7e1768ccdc732164a5de4ed536166dc60593f 100644
|
| --- a/components/password_manager/core/browser/password_ui_utils_unittest.cc
|
| +++ b/components/password_manager/core/browser/password_ui_utils_unittest.cc
|
| @@ -93,4 +93,16 @@ TEST(GetShownOriginAndLinkUrlTest, OriginFromNonAndroidForm) {
|
| EXPECT_EQ(form.origin, link_url);
|
| }
|
|
|
| +TEST(SplitByDotAndReverseTest, ReversedHostname) {
|
| + const struct {
|
| + const char* input;
|
| + const char* output;
|
| + } kTestCases[] = {{"com.example.android", "android.example.com"},
|
| + {"com.example.mobile", "mobile.example.com"},
|
| + {"net.example.subdomain", "subdomain.example.net"}};
|
| + for (const auto& test_case : kTestCases) {
|
| + EXPECT_EQ(test_case.output, SplitByDotAndReverse(test_case.input));
|
| + }
|
| +}
|
| +
|
| } // namespace password_manager
|
|
|