private SchemaConfig newSchemaConfig() {
            final ArrayList<ColumnConfig> schema = new ArrayList<>();
            try (final BufferedReader reader = Files.newBufferedReader(inputPath, StandardCharsets.UTF_8)) {
                for (String column : reader.readLine().split(",")) {
                    ColumnConfig columnConfig = newColumnConfig(column);
                    if (columnConfig != null) {
                        schema.add(columnConfig);
                    }
                }
                return new SchemaConfig(Collections.unmodifiableList(schema));
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
This method returns PreviewResult.

@return PreviewResult returns the result by PreviewExecutor
@throws IOException in case of failures in file operations
embulk-junit4/src/main/java/org/embulk/test/TestingEmbulk.java