You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@drill.apache.org by hg...@apache.org on 2015/05/12 02:42:31 UTC

[2/2] drill git commit: DRILL-2776: add extensive tests for empty population coverage

DRILL-2776: add extensive tests for empty population coverage


Project: http://git-wip-us.apache.org/repos/asf/drill/repo
Commit: http://git-wip-us.apache.org/repos/asf/drill/commit/27b4aae2
Tree: http://git-wip-us.apache.org/repos/asf/drill/tree/27b4aae2
Diff: http://git-wip-us.apache.org/repos/asf/drill/diff/27b4aae2

Branch: refs/heads/master
Commit: 27b4aae2008a8125411eb0ec23a07cad8cea096e
Parents: c8769ed
Author: Hanifi Gunes <hg...@maprtech.com>
Authored: Mon May 11 16:13:52 2015 -0700
Committer: Hanifi Gunes <hg...@maprtech.com>
Committed: Mon May 11 17:20:05 2015 -0700

----------------------------------------------------------------------
 .../vector/complex/TestEmptyPopulation.java     | 314 +++++++++++++++++++
 .../exec/vector/complex/TestEmptyPopulator.java |  86 -----
 .../vector/complex/map-empty-between.json       |   3 +
 .../vector/complex/map-empty-first.json         |   3 +
 .../vector/complex/map-empty-last.json          |   3 +
 .../multi-repeated-list-empty-between.json      |   3 +
 .../multi-repeated-list-empty-first.json        |   3 +
 .../complex/multi-repeated-list-empty-last.json |   3 +
 .../multi-repeated-list-multi-empty.json        |   3 +
 .../complex/repeated-list-empty-between.json    |   3 +
 .../complex/repeated-list-empty-first.json      |   3 +
 .../complex/repeated-list-empty-last.json       |   3 +
 .../complex/repeated-map-empty-between.json     |   3 +
 .../complex/repeated-map-empty-first.json       |   3 +
 .../vector/complex/repeated-map-empty-last.json |   3 +
 .../complex/repeated-scalar-empty-between.json  |   3 +
 .../complex/repeated-scalar-empty-first.json    |   3 +
 .../complex/repeated-scalar-empty-last.json     |   3 +
 18 files changed, 362 insertions(+), 86 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulation.java
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulation.java b/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulation.java
new file mode 100644
index 0000000..06a73e2
--- /dev/null
+++ b/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulation.java
@@ -0,0 +1,314 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.drill.exec.vector.complex;
+
+import static org.apache.drill.TestBuilder.listOf;
+import static org.apache.drill.TestBuilder.mapOf;
+import org.apache.drill.BaseTestQuery;
+import org.apache.drill.exec.memory.BufferAllocator;
+import org.apache.drill.exec.memory.TopLevelAllocator;
+import org.apache.drill.exec.vector.UInt4Vector;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.runners.MockitoJUnitRunner;
+
+@RunWith(MockitoJUnitRunner.class)
+public class TestEmptyPopulation extends BaseTestQuery {
+
+  private UInt4Vector offsets;
+  private UInt4Vector.Accessor accessor;
+  private UInt4Vector.Mutator mutator;
+  private EmptyValuePopulator populator;
+  private BufferAllocator allocator = new TopLevelAllocator();
+
+
+  @Before
+  public void initialize() {
+    offsets = new UInt4Vector(null, allocator);
+    offsets.allocateNewSafe();
+    accessor = offsets.getAccessor();
+    mutator = offsets.getMutator();
+    mutator.set(0, 0);
+    mutator.setValueCount(1);
+    Assert.assertTrue("offsets must have one value", accessor.getValueCount() == 1);
+    populator = new EmptyValuePopulator(offsets);
+  }
+
+  @Test(expected = IndexOutOfBoundsException.class)
+  public void testNegativeValuesThrowException() {
+    populator.populate(-1);
+  }
+
+  @Test
+  public void testZeroHasNoEffect() {
+    populator.populate(0);
+    Assert.assertTrue("offset must have one value", accessor.getValueCount() == 1);
+  }
+
+  @Test
+  public void testEmptyPopulationWorks() {
+    populator.populate(1);
+    Assert.assertEquals("offset must have valid size", 2, accessor.getValueCount());
+    Assert.assertEquals("value must match", 0, accessor.get(1));
+
+    mutator.set(1, 10);
+    populator.populate(2);
+    Assert.assertEquals("offset must have valid size", 3, accessor.getValueCount());
+    Assert.assertEquals("value must match", 10, accessor.get(1));
+
+    mutator.set(2, 20);
+    populator.populate(5);
+    Assert.assertEquals("offset must have valid size", 6, accessor.getValueCount());
+    for (int i=2; i<=5;i++) {
+      Assert.assertEquals(String.format("value at index[%s] must match", i), 20, accessor.get(i));
+    }
+
+    populator.populate(0);
+    Assert.assertEquals("offset must have valid size", 1, accessor.getValueCount());
+    Assert.assertEquals("value must match", 0, accessor.get(0));
+  }
+
+  @Test
+  public void testRepeatedScalarEmptyFirst() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-scalar-empty-first.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf())
+        .baselineValues(listOf(1L))
+        .baselineValues(listOf(2L))
+        .go();
+  }
+
+  @Test
+  public void testRepeatedScalarEmptyLast() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-scalar-empty-last.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(1L))
+        .baselineValues(listOf(2L))
+        .baselineValues(listOf())
+        .go();
+  }
+
+  @Test
+  public void testRepeatedScalarEmptyInBetween() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-scalar-empty-between.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(1L))
+        .baselineValues(listOf())
+        .baselineValues(listOf(2L))
+        .go();
+  }
+
+  @Test
+  public void testRepeatedListEmptyFirst() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-list-empty-first.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf())
+        .baselineValues(listOf(listOf(1L)))
+        .baselineValues(listOf(listOf(2L)))
+        .go();
+  }
+
+  @Test
+  public void testRepeatedListEmptyLast() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-list-empty-last.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(listOf(1L)))
+        .baselineValues(listOf(listOf(2L)))
+        .baselineValues(listOf())
+        .go();
+  }
+
+  @Test
+  public void testRepeatedListEmptyBetween() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-list-empty-between.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(listOf(1L)))
+        .baselineValues(listOf())
+        .baselineValues(listOf(listOf(2L)))
+        .go();
+  }
+
+
+  @Test
+  public void testRepeatedMapEmptyFirst() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-map-empty-first.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf())
+        .baselineValues(listOf(mapOf("b", 1L)))
+        .baselineValues(listOf(mapOf("b", 2L)))
+        .go();
+  }
+
+  @Test
+  public void testRepeatedMapEmptyLast() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-map-empty-last.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(mapOf("b", 1L)))
+        .baselineValues(listOf(mapOf("b", 2L)))
+        .baselineValues(listOf())
+        .go();
+  }
+
+  @Test
+  public void testRepeatedMapEmptyBetween() throws Exception {
+    final String query = "select * from cp.`vector/complex/repeated-map-empty-between.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(mapOf("b", 1L)))
+        .baselineValues(listOf())
+        .baselineValues(listOf(mapOf("b", 2L)))
+        .go();
+  }
+
+  @Test
+  public void testMapEmptyFirst() throws Exception {
+    final String query = "select * from cp.`vector/complex/map-empty-first.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a", "c")
+        .baselineValues(mapOf(), 1L)
+        .baselineValues(mapOf("b", 1L), null)
+        .baselineValues(mapOf("b", 2L), null)
+        .go();
+  }
+
+  @Test
+  public void testMapEmptyLast() throws Exception {
+    final String query = "select * from cp.`vector/complex/map-empty-last.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a", "c")
+        .baselineValues(mapOf("b", 1L), null)
+        .baselineValues(mapOf("b", 2L), null)
+        .baselineValues(mapOf(), 1L)
+        .go();
+  }
+
+  @Test
+  public void testMapEmptyBetween() throws Exception {
+    final String query = "select * from cp.`vector/complex/map-empty-between.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a", "c")
+        .baselineValues(mapOf("b", 1L), null)
+        .baselineValues(mapOf(), 1L)
+        .baselineValues(mapOf("b", 2L), null)
+        .go();
+  }
+
+  @Test
+  public void testMultiLevelRepeatedListEmptyFirst() throws Exception {
+    final String query = "select * from cp.`vector/complex/multi-repeated-list-empty-first.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf())
+        .baselineValues(listOf(listOf(listOf(1L), listOf(3L)), listOf(listOf(5L, 7L))))
+        .baselineValues(listOf(listOf(listOf(2L), listOf(4L))))
+        .go();
+  }
+
+  @Test
+  public void testMultiLevelRepeatedListEmptyLast() throws Exception {
+    final String query = "select * from cp.`vector/complex/multi-repeated-list-empty-last.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(listOf(listOf(1L), listOf(3L)), listOf(listOf(5L, 7L))))
+        .baselineValues(listOf(listOf(listOf(2L), listOf(4L))))
+        .baselineValues(listOf())
+        .go();
+  }
+
+  @Test
+  public void testMultiLevelRepeatedListEmptyBetween() throws Exception {
+    final String query = "select * from cp.`vector/complex/multi-repeated-list-empty-between.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf(listOf(listOf(1L), listOf(3L)), listOf(listOf(5L, 7L))))
+        .baselineValues(listOf())
+        .baselineValues(listOf(listOf(listOf(2L), listOf(4L))))
+        .go();
+  }
+
+
+  @Test
+  public void testMultiLevelRepeatedListWithMultipleEmpties() throws Exception {
+    final String query = "select * from cp.`vector/complex/multi-repeated-list-multi-empty.json`";
+
+    testBuilder()
+        .sqlQuery(query)
+        .ordered()
+        .baselineColumns("a")
+        .baselineValues(listOf())
+        .baselineValues(listOf(listOf(listOf(1L), listOf(3L)), listOf(listOf())))
+        .baselineValues(listOf(listOf(listOf(2L), listOf()), listOf()))
+        .go();
+  }
+
+}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulator.java
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulator.java b/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulator.java
deleted file mode 100644
index 23cc316..0000000
--- a/exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulator.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.drill.exec.vector.complex;
-
-import org.apache.drill.exec.ExecTest;
-import org.apache.drill.exec.memory.BufferAllocator;
-import org.apache.drill.exec.memory.TopLevelAllocator;
-import org.apache.drill.exec.vector.UInt4Vector;
-import org.junit.Assert;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.mockito.runners.MockitoJUnitRunner;
-
-@RunWith(MockitoJUnitRunner.class)
-public class TestEmptyPopulator extends ExecTest {
-  private static final int BUF_SIZE = 10000;
-
-  private UInt4Vector offsets;
-  private UInt4Vector.Accessor accessor;
-  private UInt4Vector.Mutator mutator;
-  private EmptyValuePopulator populator;
-  private BufferAllocator allocator = new TopLevelAllocator();
-
-
-  @Before
-  public void initialize() {
-    offsets = new UInt4Vector(null, allocator);
-    offsets.allocateNewSafe();
-    accessor = offsets.getAccessor();
-    mutator = offsets.getMutator();
-    mutator.set(0, 0);
-    mutator.setValueCount(1);
-    Assert.assertTrue("offsets must have one value", accessor.getValueCount() == 1);
-    populator = new EmptyValuePopulator(offsets);
-  }
-
-  @Test(expected = IndexOutOfBoundsException.class)
-  public void testNegativeValuesThrowException() {
-    populator.populate(-1);
-  }
-
-  @Test
-  public void testZeroHasNoEffect() {
-    populator.populate(0);
-    Assert.assertTrue("offset must have one value", accessor.getValueCount() == 1);
-  }
-
-  @Test
-  public void testEmptyPopulationWorks() {
-    populator.populate(1);
-    Assert.assertEquals("offset must have valid size", 2, accessor.getValueCount());
-    Assert.assertEquals("value must match", 0, accessor.get(1));
-
-    mutator.set(1, 10);
-    populator.populate(2);
-    Assert.assertEquals("offset must have valid size", 3, accessor.getValueCount());
-    Assert.assertEquals("value must match", 10, accessor.get(1));
-
-    mutator.set(2, 20);
-    populator.populate(5);
-    Assert.assertEquals("offset must have valid size", 6, accessor.getValueCount());
-    for (int i=2; i<=5;i++) {
-      Assert.assertEquals(String.format("value at index[%s] must match", i), 20, accessor.get(i));
-    }
-
-    populator.populate(0);
-    Assert.assertEquals("offset must have valid size", 1, accessor.getValueCount());
-    Assert.assertEquals("value must match", 0, accessor.get(0));
-  }
-}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/map-empty-between.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/map-empty-between.json b/exec/java-exec/src/test/resources/vector/complex/map-empty-between.json
new file mode 100644
index 0000000..eb206d9
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/map-empty-between.json
@@ -0,0 +1,3 @@
+{"a":{b:1}}
+{"c": 1}
+{"a":{b:2}}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/map-empty-first.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/map-empty-first.json b/exec/java-exec/src/test/resources/vector/complex/map-empty-first.json
new file mode 100644
index 0000000..ab3009d
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/map-empty-first.json
@@ -0,0 +1,3 @@
+{"c": 1}
+{"a":{b:1}}
+{"a":{b:2}}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/map-empty-last.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/map-empty-last.json b/exec/java-exec/src/test/resources/vector/complex/map-empty-last.json
new file mode 100644
index 0000000..7b74271
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/map-empty-last.json
@@ -0,0 +1,3 @@
+{"a":{b:1}}
+{"a":{b:2}}
+{"c": 1}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-between.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-between.json b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-between.json
new file mode 100644
index 0000000..0c007a9
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-between.json
@@ -0,0 +1,3 @@
+{"a":[[[1], [3]], [[5, 7]]]}
+{"a":[]}
+{"a":[[[2], [4]]]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-first.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-first.json b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-first.json
new file mode 100644
index 0000000..469bb57
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-first.json
@@ -0,0 +1,3 @@
+{"a":[]}
+{"a":[[[1], [3]], [[5, 7]]]}
+{"a":[[[2], [4]]]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-last.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-last.json b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-last.json
new file mode 100644
index 0000000..73bf266
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-empty-last.json
@@ -0,0 +1,3 @@
+{"a":[[[1], [3]], [[5, 7]]]}
+{"a":[[[2], [4]]]}
+{"a":[]}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-multi-empty.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-multi-empty.json b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-multi-empty.json
new file mode 100644
index 0000000..9b911de
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/multi-repeated-list-multi-empty.json
@@ -0,0 +1,3 @@
+{"a":[]}
+{"a":[[[1], [3]], [[]]]}
+{"a":[[[2], []], []]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-between.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-between.json b/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-between.json
new file mode 100644
index 0000000..4136783
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-between.json
@@ -0,0 +1,3 @@
+{"a":[[1]]}
+{"a":[]}
+{"a":[[2]]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-first.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-first.json b/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-first.json
new file mode 100644
index 0000000..6ac00b7
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-first.json
@@ -0,0 +1,3 @@
+{"a":[]}
+{"a":[[1]]}
+{"a":[[2]]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-last.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-last.json b/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-last.json
new file mode 100644
index 0000000..8b0c3d5
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-list-empty-last.json
@@ -0,0 +1,3 @@
+{"a":[[1]]}
+{"a":[[2]]}
+{"a":[]}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-between.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-between.json b/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-between.json
new file mode 100644
index 0000000..1aa626a
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-between.json
@@ -0,0 +1,3 @@
+{"a":[{b:1}]}
+{"a":[]}
+{"a":[{b:2}]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-first.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-first.json b/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-first.json
new file mode 100644
index 0000000..7c2301c
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-first.json
@@ -0,0 +1,3 @@
+{"a":[]}
+{"a":[{b:1}]}
+{"a":[{b:2}]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-last.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-last.json b/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-last.json
new file mode 100644
index 0000000..e9816d9
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-map-empty-last.json
@@ -0,0 +1,3 @@
+{"a":[{b:1}]}
+{"a":[{b:2}]}
+{"a":[]}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-between.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-between.json b/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-between.json
new file mode 100644
index 0000000..e303329
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-between.json
@@ -0,0 +1,3 @@
+{"a":[1]}
+{"a":[]}
+{"a":[2]}

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-first.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-first.json b/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-first.json
new file mode 100644
index 0000000..2121221
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-first.json
@@ -0,0 +1,3 @@
+{"a":[]}
+{"a":[1]}
+{"a":[2]}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/drill/blob/27b4aae2/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-last.json
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-last.json b/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-last.json
new file mode 100644
index 0000000..926b370
--- /dev/null
+++ b/exec/java-exec/src/test/resources/vector/complex/repeated-scalar-empty-last.json
@@ -0,0 +1,3 @@
+{"a":[1]}
+{"a":[2]}
+{"a":[]}