diff --git a/httpclient/src/test/java/org/apache/http/client/utils/TestDateUtils.java b/httpclient/src/test/java/org/apache/http/client/utils/TestDateUtils.java index 1d6b21355..8d6af6fd7 100644 --- a/httpclient/src/test/java/org/apache/http/client/utils/TestDateUtils.java +++ b/httpclient/src/test/java/org/apache/http/client/utils/TestDateUtils.java @@ -138,6 +138,7 @@ public class TestDateUtils { Assert.assertEquals("Fri, 14 Oct 2005 00:00:00 GMT", DateUtils.formatDate(date, DateUtils.PATTERN_RFC1123)); } + @SuppressWarnings("unused") @Test public void testConstructor() { new DateParseException(); diff --git a/httpclient/src/test/java/org/apache/http/cookie/TestCookieOrigin.java b/httpclient/src/test/java/org/apache/http/cookie/TestCookieOrigin.java index 681c96edf..ca721c4f5 100644 --- a/httpclient/src/test/java/org/apache/http/cookie/TestCookieOrigin.java +++ b/httpclient/src/test/java/org/apache/http/cookie/TestCookieOrigin.java @@ -44,21 +44,25 @@ public class TestCookieOrigin { Assert.assertFalse(origin.isSecure()); } + @SuppressWarnings("unused") @Test(expected=IllegalArgumentException.class) public void testNullHost() { new CookieOrigin(null, 80, "/", false); } + @SuppressWarnings("unused") @Test(expected=IllegalArgumentException.class) public void testEmptyHost() { new CookieOrigin(" ", 80, "/", false); } + @SuppressWarnings("unused") @Test(expected=IllegalArgumentException.class) public void testNegativePort() { new CookieOrigin("www.apache.org", -80, "/", false); } + @SuppressWarnings("unused") @Test(expected=IllegalArgumentException.class) public void testNullPath() { new CookieOrigin("www.apache.org", 80, null, false); diff --git a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie.java b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie.java index f654a5051..c807a2f9c 100644 --- a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie.java +++ b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie.java @@ -40,6 +40,7 @@ import org.junit.Test; */ public class TestBasicClientCookie { + @SuppressWarnings("unused") @Test public void testConstructor() { final BasicClientCookie cookie = new BasicClientCookie("name", "value"); diff --git a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie2.java b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie2.java index 407ab1f38..9af1608bb 100644 --- a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie2.java +++ b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicClientCookie2.java @@ -40,6 +40,7 @@ import org.junit.Test; */ public class TestBasicClientCookie2 { + @SuppressWarnings("unused") @Test public void testConstructor() { final BasicClientCookie2 cookie = new BasicClientCookie2("name", "value"); diff --git a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicCookieAttribHandlers.java b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicCookieAttribHandlers.java index d1164f0da..ba5de58e4 100644 --- a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicCookieAttribHandlers.java +++ b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBasicCookieAttribHandlers.java @@ -450,6 +450,7 @@ public class TestBasicCookieAttribHandlers { } } + @SuppressWarnings("unused") @Test public void testBasicExpiresInvalidInput() throws Exception { try { diff --git a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBrowserCompatSpec.java b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBrowserCompatSpec.java index 3cb0c92af..544a0050a 100644 --- a/httpclient/src/test/java/org/apache/http/impl/cookie/TestBrowserCompatSpec.java +++ b/httpclient/src/test/java/org/apache/http/impl/cookie/TestBrowserCompatSpec.java @@ -48,6 +48,7 @@ import org.junit.Test; */ public class TestBrowserCompatSpec { + @SuppressWarnings("unused") @Test public void testConstructor() throws Exception { new BrowserCompatSpec(); @@ -956,6 +957,7 @@ public class TestBrowserCompatSpec { Assert.assertEquals("name1=value1; name2=value2", headers.get(0).getValue()); } + @SuppressWarnings("unused") @Test public void testKeepCloverHappy() throws Exception { new MalformedCookieException(); diff --git a/httpclient/src/test/java/org/apache/http/impl/cookie/TestCookieRFC2109Spec.java b/httpclient/src/test/java/org/apache/http/impl/cookie/TestCookieRFC2109Spec.java index 8ee4a31ff..bc1596fcc 100644 --- a/httpclient/src/test/java/org/apache/http/impl/cookie/TestCookieRFC2109Spec.java +++ b/httpclient/src/test/java/org/apache/http/impl/cookie/TestCookieRFC2109Spec.java @@ -46,6 +46,7 @@ import org.junit.Test; */ public class TestCookieRFC2109Spec { + @SuppressWarnings("unused") @Test public void testConstructor() throws Exception { new RFC2109Spec();