-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
40 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
src/test/java/org/embulk/output/ParquetOutputPluginTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
package org.embulk.output; | ||
|
||
import org.embulk.EmbulkTestRuntime; | ||
import org.embulk.config.ConfigException; | ||
import org.embulk.config.ConfigSource; | ||
import org.embulk.spi.Exec; | ||
import org.junit.Rule; | ||
import org.junit.Test; | ||
|
||
import static org.junit.Assert.*; | ||
|
||
public class ParquetOutputPluginTest { | ||
@Rule | ||
public EmbulkTestRuntime runtime = new EmbulkTestRuntime(); | ||
|
||
@Test | ||
public void checkDefaultValues() { | ||
ConfigSource config = Exec.newConfigSource() | ||
.set("path_prefix", "test"); | ||
|
||
ParquetOutputPlugin.PluginTask task = config.loadConfig(ParquetOutputPlugin.PluginTask.class); | ||
assertEquals(".parquet", task.getFileNameExtension()); | ||
assertEquals(".%03d", task.getSequenceFormat()); | ||
assertEquals(134217728, task.getBlockSize()); | ||
assertEquals(1048576, task.getPageSize()); | ||
assertEquals("UNCOMPRESSED", task.getCompressionCodec()); | ||
} | ||
|
||
@Test(expected = ConfigException.class) | ||
public void checkColumnsRequired() { | ||
ConfigSource config = Exec.newConfigSource(); | ||
|
||
config.loadConfig(ParquetOutputPlugin.PluginTask.class); | ||
} | ||
|
||
|
||
} |
This file was deleted.
Oops, something went wrong.