You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by ol...@apache.org on 2005/03/24 19:48:04 UTC
svn commit: r158934 -
jakarta/httpclient/trunk/http-common/src/test/org/apache/http/TestStatusLine.java
Author: olegk
Date: Thu Mar 24 10:48:03 2005
New Revision: 158934
URL: http://svn.apache.org/viewcvs?view=rev&rev=158934
Log:
Removed unnecessary instance variable
Modified:
jakarta/httpclient/trunk/http-common/src/test/org/apache/http/TestStatusLine.java
Modified: jakarta/httpclient/trunk/http-common/src/test/org/apache/http/TestStatusLine.java
URL: http://svn.apache.org/viewcvs/jakarta/httpclient/trunk/http-common/src/test/org/apache/http/TestStatusLine.java?view=diff&r1=158933&r2=158934
==============================================================================
--- jakarta/httpclient/trunk/http-common/src/test/org/apache/http/TestStatusLine.java (original)
+++ jakarta/httpclient/trunk/http-common/src/test/org/apache/http/TestStatusLine.java Thu Mar 24 10:48:03 2005
@@ -39,8 +39,6 @@
*/
public class TestStatusLine extends TestCase {
- private StatusLine statusLine = null;
-
// ------------------------------------------------------------ Constructor
public TestStatusLine(String testName) {
super(testName);
@@ -93,7 +91,7 @@
public void testSuccess() throws Exception {
//typical status line
- statusLine = StatusLine.parse("HTTP/1.1 200 OK");
+ StatusLine statusLine = StatusLine.parse("HTTP/1.1 200 OK");
assertEquals("HTTP/1.1 200 OK", statusLine.toString());
assertEquals(HttpVersion.HTTP_1_1, statusLine.getHttpVersion());
assertEquals(200, statusLine.getStatusCode());
@@ -141,6 +139,7 @@
}
public void testFailure() throws Exception {
+ StatusLine statusLine = null;
try {
statusLine = StatusLine.parse("xxx 200 OK");
fail();
@@ -162,6 +161,7 @@
}
public void testNullInput() throws Exception {
+ StatusLine statusLine = null;
try {
statusLine = StatusLine.parse(null);
fail("IllegalArgumentException should have been thrown");