hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ol...@apache.org
Subject svn commit: r1101003 - in /httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http: ./ impl/nio/codecs/ nio/util/
Date Mon, 09 May 2011 13:01:16 GMT
Author: olegk
Date: Mon May  9 13:01:15 2011
New Revision: 1101003

URL: http://svn.apache.org/viewvc?rev=1101003&view=rev
Log:
Renamed mock classes

Added:
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMock.java
      - copied, changed from r1100998, httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMockup.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentDecoderMock.java
      - copied, changed from r1100998, httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupDecoder.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentEncoderMock.java
      - copied, changed from r1100998, httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupEncoder.java
Removed:
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMockup.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupDecoder.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupEncoder.java
Modified:
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestChunkDecoder.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestIdentityDecoder.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestLengthDelimitedDecoder.java
    httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/TestBuffers.java

Copied: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMock.java
(from r1100998, httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMockup.java)
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMock.java?p2=httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMock.java&p1=httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMockup.java&r1=1100998&r2=1101003&rev=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMockup.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/ReadableByteChannelMock.java
Mon May  9 13:01:15 2011
@@ -33,7 +33,7 @@ import java.nio.channels.ReadableByteCha
 
 import org.apache.http.util.EncodingUtils;
 
-public class ReadableByteChannelMockup implements ReadableByteChannel {
+public class ReadableByteChannelMock implements ReadableByteChannel {
 
     private final String[] chunks;
     private final String charset;
@@ -43,7 +43,7 @@ public class ReadableByteChannelMockup i
     private ByteBuffer currentChunk;
     private boolean closed = false;
 
-    public ReadableByteChannelMockup(final String[] chunks, final String charset) {
+    public ReadableByteChannelMock(final String[] chunks, final String charset) {
         super();
         this.chunks = chunks;
         this.charset = charset;

Modified: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestChunkDecoder.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestChunkDecoder.java?rev=1101003&r1=1101002&r2=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestChunkDecoder.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestChunkDecoder.java
Mon May  9 13:01:15 2011
@@ -33,7 +33,7 @@ import java.nio.channels.ReadableByteCha
 
 import org.apache.http.Header;
 import org.apache.http.MalformedChunkCodingException;
-import org.apache.http.ReadableByteChannelMockup;
+import org.apache.http.ReadableByteChannelMock;
 import org.apache.http.impl.io.HttpTransportMetricsImpl;
 import org.apache.http.impl.nio.reactor.SessionInputBufferImpl;
 import org.apache.http.nio.reactor.SessionInputBuffer;
@@ -59,7 +59,7 @@ public class TestChunkDecoder {
     @Test
     public void testBasicDecoding() throws Exception {
         String s = "5\r\n01234\r\n5\r\n56789\r\n6\r\nabcdef\r\n0\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -85,7 +85,7 @@ public class TestChunkDecoder {
     public void testComplexDecoding() throws Exception {
         String s = "10;key=\"value\"\r\n1234567890123456\r\n" +
                 "5\r\n12345\r\n5\r\n12345\r\n0\r\nFooter1: abcde\r\nFooter2: fghij\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -123,7 +123,7 @@ public class TestChunkDecoder {
     public void testDecodingWithSmallBuffer() throws Exception {
         String s1 = "5\r\n01234\r\n5\r\n5678";
         String s2 = "9\r\n6\r\nabcdef\r\n0\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s1, s2}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -168,7 +168,7 @@ public class TestChunkDecoder {
                 "er1: abcde\r\nFooter2: f",
                 "ghij\r\n\r\n"
         };
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 chunks, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -206,7 +206,7 @@ public class TestChunkDecoder {
     @Test
     public void testMalformedChunkSizeDecoding() throws Exception {
         String s = "5\r\n01234\r\n5zz\r\n56789\r\n6\r\nabcdef\r\n0\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -227,7 +227,7 @@ public class TestChunkDecoder {
     @Test
     public void testMalformedChunkEndingDecoding() throws Exception {
         String s = "5\r\n01234\r\n5\r\n56789\n\r6\r\nabcdef\r\n0\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -248,7 +248,7 @@ public class TestChunkDecoder {
     @Test
     public void testMalformedChunkTruncatedChunk() throws Exception {
         String s = "3\r\n12";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -270,7 +270,7 @@ public class TestChunkDecoder {
     public void testFoldedFooters() throws Exception {
         String s = "10;key=\"value\"\r\n1234567890123456\r\n" +
                 "5\r\n12345\r\n5\r\n12345\r\n0\r\nFooter1: abcde\r\n   \r\n  fghij\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -294,7 +294,7 @@ public class TestChunkDecoder {
     public void testMalformedFooters() throws Exception {
         String s = "10;key=\"value\"\r\n1234567890123456\r\n" +
                 "5\r\n12345\r\n5\r\n12345\r\n0\r\nFooter1 abcde\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -316,7 +316,7 @@ public class TestChunkDecoder {
     public void testEndOfStreamConditionReadingLastChunk() throws Exception {
         String s = "10\r\n1234567890123456\r\n" +
                 "5\r\n12345\r\n5\r\n12345";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -344,7 +344,7 @@ public class TestChunkDecoder {
         String s = "10\r\n1234567890123456\r\n" +
                 "40\r\n12345678901234561234567890123456" +
                 "12345678901234561234567890123456\r\n0\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -377,7 +377,7 @@ public class TestChunkDecoder {
     public void testEndOfStreamConditionReadingFooters() throws Exception {
         String s = "10\r\n1234567890123456\r\n" +
                 "5\r\n12345\r\n5\r\n12345\r\n0\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -402,7 +402,7 @@ public class TestChunkDecoder {
 
     @Test
     public void testInvalidConstructor() {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -431,7 +431,7 @@ public class TestChunkDecoder {
     public void testInvalidInput() throws Exception {
         String s = "10;key=\"value\"\r\n1234567890123456\r\n" +
                 "5\r\n12345\r\n5\r\n12345\r\n0\r\nFooter1 abcde\r\n\r\n";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 

Modified: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestIdentityDecoder.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestIdentityDecoder.java?rev=1101003&r1=1101002&r2=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestIdentityDecoder.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestIdentityDecoder.java
Mon May  9 13:01:15 2011
@@ -36,7 +36,7 @@ import java.nio.ByteBuffer;
 import java.nio.channels.FileChannel;
 import java.nio.channels.ReadableByteChannel;
 
-import org.apache.http.ReadableByteChannelMockup;
+import org.apache.http.ReadableByteChannelMock;
 import org.apache.http.impl.io.HttpTransportMetricsImpl;
 import org.apache.http.impl.nio.reactor.SessionInputBufferImpl;
 import org.apache.http.nio.reactor.SessionInputBuffer;
@@ -77,7 +77,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testBasicDecoding() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -115,7 +115,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testDecodingFromSessionBuffer() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -159,7 +159,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testBasicDecodingFile() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff; ", "more stuff; ", "a lot more stuff!"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -197,7 +197,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testDecodingFileWithBufferedSessionData() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff; ", "more stuff; ", "a lot more stuff!"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -233,7 +233,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testDecodingFileWithOffsetAndBufferedSessionData() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff; ", "more stuff; ", "a lot more stuff!"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -276,7 +276,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testWriteBeyondFileSize() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"a"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -302,7 +302,7 @@ public class TestIdentityDecoder {
 
     @Test
     public void testInvalidConstructor() {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -330,7 +330,7 @@ public class TestIdentityDecoder {
     @Test
     public void testInvalidInput() throws Exception {
         String s = "stuff";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 

Modified: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestLengthDelimitedDecoder.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestLengthDelimitedDecoder.java?rev=1101003&r1=1101002&r2=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestLengthDelimitedDecoder.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/impl/nio/codecs/TestLengthDelimitedDecoder.java
Mon May  9 13:01:15 2011
@@ -36,7 +36,7 @@ import java.nio.ByteBuffer;
 import java.nio.channels.FileChannel;
 import java.nio.channels.ReadableByteChannel;
 
-import org.apache.http.ReadableByteChannelMockup;
+import org.apache.http.ReadableByteChannelMock;
 import org.apache.http.impl.io.HttpTransportMetricsImpl;
 import org.apache.http.impl.nio.reactor.SessionInputBufferImpl;
 import org.apache.http.nio.reactor.SessionInputBuffer;
@@ -77,7 +77,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testBasicDecoding() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -110,7 +110,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testCodingBeyondContentLimit() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {
                         "stuff;",
                         "more stuff; and a lot more stuff"}, "US-ASCII");
@@ -145,7 +145,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testBasicDecodingSmallBuffer() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -199,7 +199,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testDecodingFromSessionBuffer1() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -237,7 +237,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testDecodingFromSessionBuffer2() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {
                         "stuff;",
                         "more stuff; and a lot more stuff"}, "US-ASCII");
@@ -271,7 +271,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testBasicDecodingFile() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff; ", "more stuff; ", "a lot more stuff!!!"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -308,7 +308,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testDecodingFileWithBufferedSessionData() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff; ", "more stuff; ", "a lot more stuff!!!"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -343,7 +343,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testDecodingFileWithOffsetAndBufferedSessionData() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff; ", "more stuff; ", "a lot more stuff!"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -386,7 +386,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testWriteBeyondFileSize() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"a"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -412,7 +412,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testCodingBeyondContentLimitFile() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {
                         "stuff;",
                         "more stuff; and a lot more stuff"}, "US-ASCII");
@@ -448,7 +448,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testInvalidConstructor() {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -483,7 +483,7 @@ public class TestLengthDelimitedDecoder 
     @Test
     public void testInvalidInput() throws Exception {
         String s = "stuff";
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {s}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 
@@ -502,7 +502,7 @@ public class TestLengthDelimitedDecoder 
 
     @Test
     public void testZeroLengthDecoding() throws Exception {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff"}, "US-ASCII");
         HttpParams params = new BasicHttpParams();
 

Copied: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentDecoderMock.java
(from r1100998, httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupDecoder.java)
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentDecoderMock.java?p2=httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentDecoderMock.java&p1=httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupDecoder.java&r1=1100998&r2=1101003&rev=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupDecoder.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentDecoderMock.java
Mon May  9 13:01:15 2011
@@ -33,12 +33,12 @@ import java.nio.channels.ReadableByteCha
 
 import org.apache.http.nio.ContentDecoder;
 
-public class MockupDecoder implements ContentDecoder {
+public class ContentDecoderMock implements ContentDecoder {
 
     private final ReadableByteChannel channel;
     private boolean completed;
 
-    public MockupDecoder(final ReadableByteChannel channel) {
+    public ContentDecoderMock(final ReadableByteChannel channel) {
         super();
         this.channel = channel;
     }

Copied: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentEncoderMock.java
(from r1100998, httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupEncoder.java)
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentEncoderMock.java?p2=httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentEncoderMock.java&p1=httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupEncoder.java&r1=1100998&r2=1101003&rev=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/MockupEncoder.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/ContentEncoderMock.java
Mon May  9 13:01:15 2011
@@ -35,12 +35,12 @@ import org.apache.http.impl.io.HttpTrans
 import org.apache.http.impl.nio.codecs.AbstractContentEncoder;
 import org.apache.http.nio.reactor.SessionOutputBuffer;
 
-public class MockupEncoder extends AbstractContentEncoder {
+public class ContentEncoderMock extends AbstractContentEncoder {
 
     // TODO? remove this field and the complete() and isCompleted() methods
     private boolean completed;
 
-    public MockupEncoder(
+    public ContentEncoderMock(
             final WritableByteChannel channel,
             final SessionOutputBuffer buffer,
             final HttpTransportMetricsImpl metrics) {

Modified: httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/TestBuffers.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/TestBuffers.java?rev=1101003&r1=1101002&r2=1101003&view=diff
==============================================================================
--- httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/TestBuffers.java
(original)
+++ httpcomponents/httpcore/trunk/httpcore-nio/src/test/java/org/apache/http/nio/util/TestBuffers.java
Mon May  9 13:01:15 2011
@@ -34,7 +34,7 @@ import java.nio.channels.Channels;
 import java.nio.channels.ReadableByteChannel;
 import java.nio.channels.WritableByteChannel;
 
-import org.apache.http.ReadableByteChannelMockup;
+import org.apache.http.ReadableByteChannelMock;
 import org.apache.http.impl.io.HttpTransportMetricsImpl;
 import org.apache.http.impl.nio.reactor.SessionOutputBufferImpl;
 import org.apache.http.io.BufferInfo;
@@ -54,10 +54,10 @@ public class TestBuffers {
 
     @Test
     public void testInputBufferOperations() throws IOException {
-        ReadableByteChannel channel = new ReadableByteChannelMockup(
+        ReadableByteChannel channel = new ReadableByteChannelMock(
                 new String[] {"stuff;", "more stuff"}, "US-ASCII");
 
-        ContentDecoder decoder = new MockupDecoder(channel);
+        ContentDecoder decoder = new ContentDecoderMock(channel);
 
         SimpleInputBuffer buffer = new SimpleInputBuffer(4, new DirectByteBufferAllocator());
         int count = buffer.consumeContent(decoder);
@@ -94,7 +94,7 @@ public class TestBuffers {
         SessionOutputBuffer outbuf = new SessionOutputBufferImpl(1024, 128, params);
         HttpTransportMetricsImpl metrics = new HttpTransportMetricsImpl();
 
-        ContentEncoder encoder = new MockupEncoder(channel, outbuf, metrics);
+        ContentEncoder encoder = new ContentEncoderMock(channel, outbuf, metrics);
 
         SimpleOutputBuffer buffer = new SimpleOutputBuffer(4, new DirectByteBufferAllocator());
 



Mime
View raw message