From 3a4f3d5bd9afb69f124b8a31adf2229b243cab5e Mon Sep 17 00:00:00 2001 From: "Hiram R. Chirino" Date: Sat, 1 Jul 2006 18:37:22 +0000 Subject: [PATCH] Fixed ItStillMarshallsTheSameTest git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@418496 13f79535-47bb-0310-9956-ffa450edef68 --- activemq-core/project.xml | 4 --- .../activemq/openwire/DataFileGenerator.java | 26 ++++-------------- .../org.activemq.openwire.BrokerInfoData.bin | Bin 63 -> 0 bytes ...g.activemq.openwire.WireFormatInfoData.bin | Bin 19 -> 0 bytes ...pache.activemq.openwire.BrokerInfoData.bin | Bin 0 -> 71 bytes ...e.activemq.openwire.WireFormatInfoData.bin | Bin 0 -> 42 bytes 6 files changed, 5 insertions(+), 25 deletions(-) delete mode 100644 activemq-core/src/test/resources/openwire-control/org.activemq.openwire.BrokerInfoData.bin delete mode 100644 activemq-core/src/test/resources/openwire-control/org.activemq.openwire.WireFormatInfoData.bin create mode 100644 activemq-core/src/test/resources/openwire-control/org.apache.activemq.openwire.BrokerInfoData.bin create mode 100644 activemq-core/src/test/resources/openwire-control/org.apache.activemq.openwire.WireFormatInfoData.bin diff --git a/activemq-core/project.xml b/activemq-core/project.xml index 1aa347aa17..1c23754723 100755 --- a/activemq-core/project.xml +++ b/activemq-core/project.xml @@ -341,13 +341,9 @@ **/perf/* - **/RendezvousDiscoverTransportTest.* - - **/ItStillMarshallsTheSameTest.* - **/KahaXARecoveryBrokerTest.* **/KahaRecoveryBrokerTest.* diff --git a/activemq-core/src/test/java/org/apache/activemq/openwire/DataFileGenerator.java b/activemq-core/src/test/java/org/apache/activemq/openwire/DataFileGenerator.java index 136223bb95..3820f0c025 100644 --- a/activemq-core/src/test/java/org/apache/activemq/openwire/DataFileGenerator.java +++ b/activemq-core/src/test/java/org/apache/activemq/openwire/DataFileGenerator.java @@ -24,35 +24,19 @@ import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; import java.io.InputStream; -import java.net.URI; -import java.net.URL; import java.util.ArrayList; import java.util.Iterator; -import org.apache.activemq.openwire.OpenWireFormat; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - import junit.framework.Assert; abstract public class DataFileGenerator extends Assert { - - private static final Log log = LogFactory.getLog(DataFileGenerator.class); static final File moduleBaseDir; static final File controlDir; static final File classFileDir; static { - File basedir=null; - try { - URL resource = DataFileGenerator.class.getResource("DataFileGenerator.class"); - URI baseURI = new URI(resource.toString()).resolve("../../../../.."); - basedir = new File(baseURI).getCanonicalFile(); - } catch (Exception e) { - throw new RuntimeException(e); - } - moduleBaseDir = basedir; + moduleBaseDir = new File(System.getProperty("basedir", ".")); controlDir = new File(moduleBaseDir, "src/test/resources/openwire-control"); classFileDir = new File(moduleBaseDir, "src/test/java/org/apache/activemq/openwire"); } @@ -69,7 +53,7 @@ abstract public class DataFileGenerator extends Assert { * @throws IllegalAccessException */ public static ArrayList getAllDataFileGenerators() throws Exception{ - log.info("Looking for generators in : "+classFileDir); + System.out.println("Looking for generators in : "+classFileDir); ArrayList l = new ArrayList(); File[] files = classFileDir.listFiles(); for (int i = 0; files!=null && i < files.length; i++) { @@ -89,10 +73,10 @@ abstract public class DataFileGenerator extends Assert { for (Iterator iter = generators.iterator(); iter.hasNext();) { DataFileGenerator object = (DataFileGenerator) iter.next(); try { - log.info("Processing: "+object.getClass()); + System.out.println("Processing: "+object.getClass()); object.generateControlFile(); } catch (Exception e) { - log.error("Error while processing: "+object.getClass() + ". Reason: " + e, e); + System.err.println("Error while processing: "+object.getClass() + ". Reason: " + e); } } } @@ -130,7 +114,7 @@ abstract public class DataFileGenerator extends Assert { ArrayList generators = getAllDataFileGenerators(); for (Iterator iter = generators.iterator(); iter.hasNext();) { DataFileGenerator object = (DataFileGenerator) iter.next(); - log.info("Processing: "+object.getClass()); + System.out.println("Processing: "+object.getClass()); object.assertControlFileIsEqual(); } } diff --git a/activemq-core/src/test/resources/openwire-control/org.activemq.openwire.BrokerInfoData.bin b/activemq-core/src/test/resources/openwire-control/org.activemq.openwire.BrokerInfoData.bin deleted file mode 100644 index 9e034f89c5365d9c2ed5002ea643cd153ebea2d8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 63 zcmZQzV6bLlvSVi8sbLWCbg?otvamD&62?Hnm_f88xxh+aKPNvqF()IxxWvlL5C|DK G;Q|1Fhz~^o diff --git a/activemq-core/src/test/resources/openwire-control/org.activemq.openwire.WireFormatInfoData.bin b/activemq-core/src/test/resources/openwire-control/org.activemq.openwire.WireFormatInfoData.bin deleted file mode 100644 index 88dd693d9796b088719e8bbb4aacb499264ca61c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 19 acmZQzVBlwDWN=I_$t+9t4P;