@Test public void testDoubleWithNull() throws Exception { runTest("test_flat_map/flat_map_double_with_null.dwrf", IntegerType.INTEGER, DoubleType.DOUBLE, ExpectedValuesBuilder.get(Function.identity(), Double::valueOf).setNullValuesFrequency(SOME)); }
@Test public void testStringWithNull() throws Exception { runTest("test_flat_map/flat_map_string_with_null.dwrf", VarcharType.VARCHAR, ExpectedValuesBuilder.get(i -> Integer.toString(i)).setNullValuesFrequency(SOME)); }
@Test public void testStructWithNull() throws Exception { runTest( "test_flat_map/flat_map_struct_with_null.dwrf", IntegerType.INTEGER, STRUCT_TYPE, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToList).setNullValuesFrequency(SOME)); }
@Test public void testMapWithNull() throws Exception { runTest( "test_flat_map/flat_map_map_with_null.dwrf", IntegerType.INTEGER, MAP_TYPE, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToMap).setNullValuesFrequency(SOME)); }
@Test public void testStringWithNull() throws Exception { runTest("test_flat_map/flat_map_string_with_null.dwrf", VarcharType.VARCHAR, ExpectedValuesBuilder.get(i -> Integer.toString(i)).setNullValuesFrequency(SOME)); }
@Test public void testByteWithNull() throws Exception { runTest("test_flat_map/flat_map_byte_with_null.dwrf", TinyintType.TINYINT, ExpectedValuesBuilder.get(Integer::byteValue).setNullValuesFrequency(SOME)); }
@Test public void testMapWithNull() throws Exception { runTest( "test_flat_map/flat_map_map_with_null.dwrf", IntegerType.INTEGER, MAP_TYPE, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToMap).setNullValuesFrequency(SOME)); }
@Test public void testListWithNull() throws Exception { runTest( "test_flat_map/flat_map_list_with_null.dwrf", IntegerType.INTEGER, LIST_TYPE, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToList).setNullValuesFrequency(SOME)); }
@Test public void testIntegerWithNull() throws Exception { runTest("test_flat_map/flat_map_int_with_null.dwrf", IntegerType.INTEGER, ExpectedValuesBuilder.get(Function.identity()).setNullValuesFrequency(SOME)); }
@Test public void testDoubleWithNull() throws Exception { runTest("test_flat_map/flat_map_double_with_null.dwrf", IntegerType.INTEGER, DoubleType.DOUBLE, ExpectedValuesBuilder.get(Function.identity(), Double::valueOf).setNullValuesFrequency(SOME)); }
@Test public void testBooleanWithNull() throws Exception { runTest("test_flat_map/flat_map_boolean_with_null.dwrf", IntegerType.INTEGER, BooleanType.BOOLEAN, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToBoolean).setNullValuesFrequency(SOME)); }
@Test public void testStructWithNull() throws Exception { runTest( "test_flat_map/flat_map_struct_with_null.dwrf", IntegerType.INTEGER, STRUCT_TYPE, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToList).setNullValuesFrequency(SOME)); }
@Test public void testIntegerWithNull() throws Exception { runTest("test_flat_map/flat_map_int_with_null.dwrf", IntegerType.INTEGER, ExpectedValuesBuilder.get(Function.identity()).setNullValuesFrequency(SOME)); }
@Test public void testBooleanWithNull() throws Exception { runTest("test_flat_map/flat_map_boolean_with_null.dwrf", IntegerType.INTEGER, BooleanType.BOOLEAN, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToBoolean).setNullValuesFrequency(SOME)); }
@Test public void testByteWithNull() throws Exception { runTest("test_flat_map/flat_map_byte_with_null.dwrf", TinyintType.TINYINT, ExpectedValuesBuilder.get(Integer::byteValue).setNullValuesFrequency(SOME)); }
@Test public void testFloatWithNull() throws Exception { runTest("test_flat_map/flat_map_float_with_null.dwrf", IntegerType.INTEGER, RealType.REAL, ExpectedValuesBuilder.get(Function.identity(), Float::valueOf).setNullValuesFrequency(SOME)); }
@Test public void testListWithNull() throws Exception { runTest( "test_flat_map/flat_map_list_with_null.dwrf", IntegerType.INTEGER, LIST_TYPE, ExpectedValuesBuilder.get(Function.identity(), TestFlatMap::intToList).setNullValuesFrequency(SOME)); }
@Test public void testFloatWithNull() throws Exception { runTest("test_flat_map/flat_map_float_with_null.dwrf", IntegerType.INTEGER, RealType.REAL, ExpectedValuesBuilder.get(Function.identity(), Float::valueOf).setNullValuesFrequency(SOME)); }