DO NOT MERGE Add CTS test for URI fix.

Bug: 68341964
Test: cts -m CtsNetTestCases (on NYC branch)
Change-Id: If532123542155ea3be281044a3ea4ca0b6cf2db5
(cherry picked from commit a01da8536c)
This commit is contained in:
Adam Vartanian
2017-11-07 13:56:04 +00:00
committed by JP Sugarbroad
parent 07e00f7523
commit 53a9c9bc34

View File

@@ -109,6 +109,11 @@ public class UriTest extends AndroidTestCase {
uri = Uri.parse("http://localhost");
assertEquals("localhost", uri.getHost());
assertEquals(-1, uri.getPort());
uri = Uri.parse("http://a:a@example.com:a@example2.com/path");
assertEquals("a:a@example.com:a@example2.com", uri.getAuthority());
assertEquals("example2.com", uri.getHost());
assertEquals(-1, uri.getPort());
}
public void testCompareTo() {