Repository: gora Updated Branches: refs/heads/master d61a1735e -> 79808e5e4
GORA-289 TestIOUtils to print objects with native data values as oppose to Bytes Project: http://git-wip-us.apache.org/repos/asf/gora/repo Commit: http://git-wip-us.apache.org/repos/asf/gora/commit/79808e5e Tree: http://git-wip-us.apache.org/repos/asf/gora/tree/79808e5e Diff: http://git-wip-us.apache.org/repos/asf/gora/diff/79808e5e Branch: refs/heads/master Commit: 79808e5e4f51abd504656731ca26f5cdd607598e Parents: d61a173 Author: Lewis John McGibbney <lewis.j.mcgibb...@jpl.nasa.gov> Authored: Mon Jun 30 13:59:48 2014 -0400 Committer: Lewis John McGibbney <lewis.j.mcgibb...@jpl.nasa.gov> Committed: Mon Jun 30 13:59:48 2014 -0400 ---------------------------------------------------------------------- gora-core/pom.xml | 9 -------- .../java/org/apache/gora/util/TestIOUtils.java | 22 +++++++++++++++----- .../org/apache/gora/util/TestWritableUtils.java | 2 ++ pom.xml | 2 +- 4 files changed, 20 insertions(+), 15 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/gora/blob/79808e5e/gora-core/pom.xml ---------------------------------------------------------------------- diff --git a/gora-core/pom.xml b/gora-core/pom.xml index 62ea5f3..c6ef288 100644 --- a/gora-core/pom.xml +++ b/gora-core/pom.xml @@ -78,15 +78,6 @@ </goals> </execution> </executions> - <configuration> - <archive> - <manifest> - <mainClass>org.apache.gora.compiler.GoraCompiler</mainClass> - <addClasspath>true</addClasspath> - <classpathPrefix>../lib/</classpathPrefix> - </manifest> - </archive> - </configuration> </plugin> <plugin> <groupId>org.codehaus.mojo</groupId> http://git-wip-us.apache.org/repos/asf/gora/blob/79808e5e/gora-core/src/test/java/org/apache/gora/util/TestIOUtils.java ---------------------------------------------------------------------- diff --git a/gora-core/src/test/java/org/apache/gora/util/TestIOUtils.java b/gora-core/src/test/java/org/apache/gora/util/TestIOUtils.java index 381d366..03ccd1b 100644 --- a/gora-core/src/test/java/org/apache/gora/util/TestIOUtils.java +++ b/gora-core/src/test/java/org/apache/gora/util/TestIOUtils.java @@ -37,7 +37,9 @@ import org.apache.hadoop.io.DataOutputBuffer; import org.apache.hadoop.io.Text; import org.apache.hadoop.io.Writable; import org.junit.Test; + import static org.junit.Assert.assertEquals; + import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -117,10 +119,20 @@ public class TestIOUtils { for(T before : objects) { T after = IOUtils.deserialize(conf, dis, null, (Class<T>)before.getClass()); - - log.info("Before: " + before); - log.info("After : " + after); - + if (before instanceof BoolArrayWrapper) { + if (after instanceof BoolArrayWrapper) { + log.info("Before : " + java.util.Arrays.toString(((BoolArrayWrapper) before).arr)); + log.info("After : " + java.util.Arrays.toString(((BoolArrayWrapper) after).arr)); + } + } else if (before instanceof StringArrayWrapper){ + if (after instanceof StringArrayWrapper) { + log.info("Before : " + java.util.Arrays.toString(((StringArrayWrapper) before).arr)); + log.info("After : " + java.util.Arrays.toString(((StringArrayWrapper) after).arr)); + } + } else { + log.info("Before : " + before); + log.info("After : " + before); + } assertEquals(before, after); } @@ -138,7 +150,7 @@ public class TestIOUtils { org.apache.hadoop.io.IOUtils.closeStream(is); } } - + @Test public void testWritableSerde() throws Exception { Text text = new Text("foo goes to a bar to get some buzz"); http://git-wip-us.apache.org/repos/asf/gora/blob/79808e5e/gora-core/src/test/java/org/apache/gora/util/TestWritableUtils.java ---------------------------------------------------------------------- diff --git a/gora-core/src/test/java/org/apache/gora/util/TestWritableUtils.java b/gora-core/src/test/java/org/apache/gora/util/TestWritableUtils.java index e72335a..59fe105 100644 --- a/gora-core/src/test/java/org/apache/gora/util/TestWritableUtils.java +++ b/gora-core/src/test/java/org/apache/gora/util/TestWritableUtils.java @@ -27,6 +27,8 @@ import java.io.DataOutputStream; import java.util.Properties; import static org.junit.Assert.assertEquals; + +import org.apache.gora.util.WritableUtils; import org.junit.Test; /** http://git-wip-us.apache.org/repos/asf/gora/blob/79808e5e/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index 68e13e5..f881fdc 100644 --- a/pom.xml +++ b/pom.xml @@ -608,12 +608,12 @@ <!-- Dependencies --> <osgi.version>4.2.0</osgi.version> <!-- Avro Dependencies --> + <avro.version>1.7.6</avro.version> <jackson.version>1.6.9</jackson.version> <!-- Hadoop Dependencies --> <hadoop.version>1.0.1</hadoop.version> <hadoop.test.version>1.0.1</hadoop.test.version> <hbase.version>0.94.14</hbase.version> - <avro.version>1.7.4</avro.version> <cxf-rt-frontend-jaxrs.version>2.5.2</cxf-rt-frontend-jaxrs.version> <!-- Amazon Dependencies --> <amazon.version>1.3.12</amazon.version>