cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From marc...@apache.org
Subject git commit: Remove avro usage in DataOutputTest
Date Mon, 24 Mar 2014 11:36:37 GMT
Repository: cassandra
Updated Branches:
  refs/heads/cassandra-2.1 fbc112d4b -> 5baa72f7f


Remove avro usage in DataOutputTest


Project: http://git-wip-us.apache.org/repos/asf/cassandra/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra/commit/5baa72f7
Tree: http://git-wip-us.apache.org/repos/asf/cassandra/tree/5baa72f7
Diff: http://git-wip-us.apache.org/repos/asf/cassandra/diff/5baa72f7

Branch: refs/heads/cassandra-2.1
Commit: 5baa72f7f299b4ec190ddb30b897d5519a6a2a75
Parents: fbc112d
Author: Marcus Eriksson <marcuse@apache.org>
Authored: Mon Mar 24 12:36:05 2014 +0100
Committer: Marcus Eriksson <marcuse@apache.org>
Committed: Mon Mar 24 12:36:05 2014 +0100

----------------------------------------------------------------------
 test/unit/org/apache/cassandra/io/util/DataOutputTest.java | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra/blob/5baa72f7/test/unit/org/apache/cassandra/io/util/DataOutputTest.java
----------------------------------------------------------------------
diff --git a/test/unit/org/apache/cassandra/io/util/DataOutputTest.java b/test/unit/org/apache/cassandra/io/util/DataOutputTest.java
index 4eeec4d..2a8c7a9 100644
--- a/test/unit/org/apache/cassandra/io/util/DataOutputTest.java
+++ b/test/unit/org/apache/cassandra/io/util/DataOutputTest.java
@@ -31,14 +31,12 @@ import java.io.IOException;
 import java.io.RandomAccessFile;
 import java.nio.ByteBuffer;
 import java.nio.channels.Channels;
-import java.util.Arrays;
 import java.util.Random;
 import java.util.concurrent.ThreadLocalRandom;
 
 import org.junit.Assert;
 import org.junit.Test;
 
-import org.apache.avro.util.ByteBufferInputStream;
 import org.apache.cassandra.utils.ByteBufferUtil;
 
 public class DataOutputTest
@@ -79,7 +77,7 @@ public class DataOutputTest
         ByteBuffer buf = wrap(new byte[345], true);
         DataOutputByteBuffer write = new DataOutputByteBuffer(buf.duplicate());
         DataInput canon = testWrite(write);
-        DataInput test = new DataInputStream(new ByteBufferInputStream(Arrays.asList(buf)));
+        DataInput test = new DataInputStream(new ByteArrayInputStream(ByteBufferUtil.getArray(buf)));
         testRead(test, canon);
     }
 
@@ -89,7 +87,7 @@ public class DataOutputTest
         ByteBuffer buf = wrap(new byte[345], false);
         DataOutputByteBuffer write = new DataOutputByteBuffer(buf.duplicate());
         DataInput canon = testWrite(write);
-        DataInput test = new DataInputStream(new ByteBufferInputStream(Arrays.asList(buf)));
+        DataInput test = new DataInputStream(new ByteArrayInputStream(ByteBufferUtil.getArray(buf)));
         testRead(test, canon);
     }
 


Mime
View raw message