Extraction of the filename from a URL handles the parameters differently now by returning the string after the last slash till its following semicolon as FileName.
BUG=323156
Review URL: https://codereview.chromium.org/560283003
Cr-Commit-Position: refs/heads/master@{#299848}
diff --git a/url/url_parse_unittest.cc b/url/url_parse_unittest.cc
index 7f6bfe3..71b2438 100644
--- a/url/url_parse_unittest.cc
+++ b/url/url_parse_unittest.cc
@@ -498,8 +498,13 @@
{"http://www.google.com/foo/bar.html#ref", "bar.html"},
{"http://www.google.com/search/;param", ""},
{"http://www.google.com/foo/bar.html;param#ref", "bar.html"},
- {"http://www.google.com/foo/bar.html;foo;param#ref", "bar.html;foo"},
+ {"http://www.google.com/foo/bar.html;foo;param#ref", "bar.html"},
{"http://www.google.com/foo/bar.html?query#ref", "bar.html"},
+ {"http://www.google.com/foo;/bar.html", "bar.html"},
+ {"http://www.google.com/foo;/", ""},
+ {"http://www.google.com/foo;", "foo"},
+ {"http://www.google.com/;", ""},
+ {"http://www.google.com/foo;bar;html", "foo"},
};
for (size_t i = 0; i < arraysize(file_cases); i++) {