@@ -0,0 +1,1757 @@
+package javasnack.net;%0A%0Aimport static org.testng.Assert.assertFalse;%0Aimport static org.testng.Assert.assertTrue;%0A%0Aimport java.net.HttpCookie;%0Aimport java.net.URISyntaxException;%0A%0Aimport org.testng.annotations.Test;%0A%0Apublic class TestHttpCookie1 %7B%0A%0A    @Test%0A    public void testDomainMatches() throws URISyntaxException %7B%0A        assertFalse(HttpCookie.domainMatches(%22%22, %22aaa.bbb.com%22));%0A        assertTrue(HttpCookie.domainMatches(%22aaa.bbb.com%22, %22aaa.bbb.com%22));%0A%0A        assertFalse(HttpCookie.domainMatches(%22com%22, %22com%22));%0A        assertFalse(HttpCookie.domainMatches(%22com%22, %22xxxcom%22));%0A        assertFalse(HttpCookie.domainMatches(%22com%22, %22aaa.com%22));%0A        assertFalse(HttpCookie.domainMatches(%22.com%22, %22com%22));%0A        assertFalse(HttpCookie.domainMatches(%22.com%22, %22xxxcom%22));%0A        assertFalse(HttpCookie.domainMatches(%22.com%22, %22aaa.com%22));%0A        assertFalse(HttpCookie.domainMatches(%22.com%22, %22xxxaaa.com%22));%0A%0A        assertFalse(HttpCookie.domainMatches(%22example%22, %22example%22));%0A        assertFalse(HttpCookie.domainMatches(%22example%22, %22example.local%22));%0A%0A        assertTrue(HttpCookie.domainMatches(%22.local%22, %22example%22)); // see javadoc%0A        assertTrue(HttpCookie.domainMatches(%22.local%22, %22example.local%22)); // see javadoc%0A%0A        assertTrue(HttpCookie.domainMatches(%22bbb.com%22, %22bbb.com%22));%0A        assertTrue(HttpCookie.domainMatches(%22bbb.com%22, %22xxxbbb.com%22)); // WOW!!%0A        assertFalse(HttpCookie.domainMatches(%22bbb.com%22, %22aaa.bbb.com%22));%0A%0A        assertTrue(HttpCookie.domainMatches(%22.bbb.com%22, %22bbb.com%22));%0A        assertFalse(HttpCookie.domainMatches(%22.bbb.com%22, %22xxxbbb.com%22));%0A        assertTrue(HttpCookie.domainMatches(%22.bbb.com%22, %22aaa.bbb.com%22));%0A        assertFalse(HttpCookie.domainMatches(%22.bbb.com%22, %22xxx.aaa.bbb.com%22));%0A    %7D%0A%7D%0A

add HttpCookie.domainMatches() test cases.