Repository: incubator-hivemall Updated Branches: refs/heads/master 037a96c6a -> 880ee8a2a
Fixed failing test Project: http://git-wip-us.apache.org/repos/asf/incubator-hivemall/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-hivemall/commit/d13ac418 Tree: http://git-wip-us.apache.org/repos/asf/incubator-hivemall/tree/d13ac418 Diff: http://git-wip-us.apache.org/repos/asf/incubator-hivemall/diff/d13ac418 Branch: refs/heads/master Commit: d13ac4185872478ddc9fac71060cd018e7e991fd Parents: 037a96c Author: Makoto Yui <[email protected]> Authored: Tue Nov 6 19:41:15 2018 +0900 Committer: Makoto Yui <[email protected]> Committed: Tue Nov 6 19:41:15 2018 +0900 ---------------------------------------------------------------------- .../test/java/hivemall/sketch/bloom/BloomContainsUDFTest.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-hivemall/blob/d13ac418/core/src/test/java/hivemall/sketch/bloom/BloomContainsUDFTest.java ---------------------------------------------------------------------- diff --git a/core/src/test/java/hivemall/sketch/bloom/BloomContainsUDFTest.java b/core/src/test/java/hivemall/sketch/bloom/BloomContainsUDFTest.java index 58e0db9..4478da8 100644 --- a/core/src/test/java/hivemall/sketch/bloom/BloomContainsUDFTest.java +++ b/core/src/test/java/hivemall/sketch/bloom/BloomContainsUDFTest.java @@ -33,7 +33,7 @@ import org.junit.Test; public class BloomContainsUDFTest { @Test - public void test() throws IOException, HiveException { + public void testUDF() throws IOException, HiveException { BloomContainsUDF udf = new BloomContainsUDF(); final long seed = 43L; final int size = 100; @@ -47,7 +47,8 @@ public class BloomContainsUDFTest { double d = rnd1.nextGaussian(); String s = Double.toHexString(d); key.set(s); - Assert.assertEquals(Boolean.TRUE, udf.evaluate(bfstr, key)); + Assert.assertEquals("Look up failed for key: " + key, Boolean.TRUE, + udf.evaluate(bfstr, key)); } } @@ -61,7 +62,7 @@ public class BloomContainsUDFTest { double d = rnd1.nextGaussian(); String s = Double.toHexString(d); Text t = new Text(s); - key.set(t.getBytes(), 1.0); + key.set(t.copyBytes(), 1.0); dbf.add(key); }
