Skip to content

Commit

Permalink
Fix checkstyle
Browse files Browse the repository at this point in the history
  • Loading branch information
garydgregory committed Jan 4, 2025
1 parent b63a788 commit 7f64d84
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/site/xdoc/user-guide.xml
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,10 @@ for (CSVRecord record : records) {
for example:
</p>
<source>
try (final Reader reader = new InputStreamReader(BOMInputStream.builder()
try (Reader reader = new InputStreamReader(BOMInputStream.builder()
.setPath(path)
.get(), "UTF-8");
final CSVParser parser = CSVFormat.EXCEL.builder()
CSVParser parser = CSVFormat.EXCEL.builder()
.setHeader()
.get()
.parse(reader)) {
Expand Down
10 changes: 5 additions & 5 deletions src/test/java/org/apache/commons/csv/UserGuideTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@ public void testBomFull() throws UnsupportedEncodingException, IOException {
final Path path = tempDir.resolve("test1.csv");
Files.copy(Utils.createUtf8Input("ColumnA, ColumnB, ColumnC\r\nA, B, C\r\n".getBytes(StandardCharsets.UTF_8), true), path);
// @formatter:off
try (final Reader reader = new InputStreamReader(BOMInputStream.builder()
try (Reader reader = new InputStreamReader(BOMInputStream.builder()
.setPath(path)
.get(), "UTF-8");
final CSVParser parser = CSVFormat.EXCEL.builder()
CSVParser parser = CSVFormat.EXCEL.builder()
.setHeader()
.get()
.parse(reader)) {
Expand All @@ -72,14 +72,14 @@ public void testBomFull() throws UnsupportedEncodingException, IOException {
}
}
}

@Test
public void testBomUtil() throws UnsupportedEncodingException, IOException {
final Path path = tempDir.resolve("test2.csv");
Files.copy(Utils.createUtf8Input("ColumnA, ColumnB, ColumnC\r\nA, B, C\r\n".getBytes(StandardCharsets.UTF_8), true), path);
try (final Reader reader = newReader(path);
try (Reader reader = newReader(path);
// @formatter:off
final CSVParser parser = CSVFormat.EXCEL.builder()
CSVParser parser = CSVFormat.EXCEL.builder()
.setHeader()
.get()
.parse(reader)) {
Expand Down

0 comments on commit 7f64d84

Please sign in to comment.