Repository: beam Updated Branches: refs/heads/master c93b3aa3d -> f458065da
[BEAM-2318] Ensure that tables that don't exist are not created We use the same test table name in two tests: one that expects the table not to exist, another that creates the table. Obviously, the correctness of this will depend on the order in which unit tests are executed. Fix the flake by using different and more explicit test names. Project: http://git-wip-us.apache.org/repos/asf/beam/repo Commit: http://git-wip-us.apache.org/repos/asf/beam/commit/54808be1 Tree: http://git-wip-us.apache.org/repos/asf/beam/tree/54808be1 Diff: http://git-wip-us.apache.org/repos/asf/beam/diff/54808be1 Branch: refs/heads/master Commit: 54808be14ff2e86088807adc3c0dc0965c8a6f03 Parents: c93b3aa Author: Dan Halperin <[email protected]> Authored: Thu May 18 18:43:31 2017 -0400 Committer: Dan Halperin <[email protected]> Committed: Thu May 18 16:41:39 2017 -0700 ---------------------------------------------------------------------- .../src/test/java/org/apache/beam/sdk/io/hbase/HBaseIOTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/beam/blob/54808be1/sdks/java/io/hbase/src/test/java/org/apache/beam/sdk/io/hbase/HBaseIOTest.java ---------------------------------------------------------------------- diff --git a/sdks/java/io/hbase/src/test/java/org/apache/beam/sdk/io/hbase/HBaseIOTest.java b/sdks/java/io/hbase/src/test/java/org/apache/beam/sdk/io/hbase/HBaseIOTest.java index dbeab04..1cdfc7f 100644 --- a/sdks/java/io/hbase/src/test/java/org/apache/beam/sdk/io/hbase/HBaseIOTest.java +++ b/sdks/java/io/hbase/src/test/java/org/apache/beam/sdk/io/hbase/HBaseIOTest.java @@ -282,7 +282,7 @@ public class HBaseIOTest { /** Tests that when writing to a non-existent table, the write fails. */ @Test public void testWritingFailsTableDoesNotExist() throws Exception { - final String table = "TEST-TABLE"; + final String table = "TEST-TABLE-DOES-NOT-EXIST"; PCollection<KV<byte[], Iterable<Mutation>>> emptyInput = p.apply(Create.empty(HBaseIO.WRITE_CODER)); @@ -298,7 +298,7 @@ public class HBaseIOTest { /** Tests that when writing an element fails, the write fails. */ @Test public void testWritingFailsBadElement() throws Exception { - final String table = "TEST-TABLE"; + final String table = "TEST-TABLE-BAD-ELEMENT"; final String key = "KEY"; createTable(table);
