You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by st...@apache.org on 2006/11/08 19:54:53 UTC
svn commit: r472588 -
/incubator/qpid/trunk/qpid/java/client/test/src/org/apache/qpid/framing/FieldTableTest.java
Author: steshaw
Date: Wed Nov 8 10:54:53 2006
New Revision: 472588
URL: http://svn.apache.org/viewvc?view=rev&rev=472588
Log:
QPID-73 Updated FieldTableTest to no longer use the Base64 decoder included in jboss-all-client.jar. Instead it uses the one from commons-codec.
Modified:
incubator/qpid/trunk/qpid/java/client/test/src/org/apache/qpid/framing/FieldTableTest.java
Modified: incubator/qpid/trunk/qpid/java/client/test/src/org/apache/qpid/framing/FieldTableTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/client/test/src/org/apache/qpid/framing/FieldTableTest.java?view=diff&rev=472588&r1=472587&r2=472588
==============================================================================
--- incubator/qpid/trunk/qpid/java/client/test/src/org/apache/qpid/framing/FieldTableTest.java (original)
+++ incubator/qpid/trunk/qpid/java/client/test/src/org/apache/qpid/framing/FieldTableTest.java Wed Nov 8 10:54:53 2006
@@ -19,12 +19,6 @@
import junit.framework.JUnit4TestAdapter;
import org.apache.mina.common.ByteBuffer;
-import org.apache.xml.security.utils.Base64;
-import org.apache.xml.security.exceptions.Base64DecodingException;
-import org.apache.qpid.framing.AMQFrameDecodingException;
-import org.apache.qpid.framing.FieldTable;
-import org.apache.qpid.framing.ContentHeaderBody;
-import org.apache.qpid.framing.BasicContentHeaderProperties;
import static org.junit.Assert.assertEquals;
import org.junit.Test;
@@ -38,7 +32,7 @@
public class FieldTableTest
{
@Test
- public void dataDump() throws IOException, AMQFrameDecodingException, Base64DecodingException
+ public void dataDump() throws IOException, AMQFrameDecodingException
{
byte[] data = readBase64("content.txt");
System.out.println("Got " + data.length + " bytes of data");
@@ -105,10 +99,11 @@
return ((BasicContentHeaderProperties) header.properties).getHeaders();
}
- byte[] readBase64(String name) throws IOException, Base64DecodingException
+ byte[] readBase64(String name) throws IOException
{
String content = read(new InputStreamReader(getClass().getResourceAsStream(name)));
- return Base64.decode(content);
+
+ return org.apache.commons.codec.binary.Base64.decodeBase64(content.getBytes());
}
FieldTable load(String name) throws IOException