Skip to content

Commit f97c172

Browse files
committed
Use JUnit 5 convention for test method visibility
1 parent cff3260 commit f97c172

35 files changed

+503
-503
lines changed

src/test/java/org/apache/commons/csv/CSVDuplicateHeaderTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ static Stream<Arguments> duplicateHeaderData() {
272272
*/
273273
@ParameterizedTest
274274
@MethodSource(value = {"duplicateHeaderAllowsMissingColumnsNamesData"})
275-
public void testCSVFormat(final DuplicateHeaderMode duplicateHeaderMode,
275+
void testCSVFormat(final DuplicateHeaderMode duplicateHeaderMode,
276276
final boolean allowMissingColumnNames,
277277
final boolean ignoreHeaderCase,
278278
final String[] headers,
@@ -305,7 +305,7 @@ public void testCSVFormat(final DuplicateHeaderMode duplicateHeaderMode,
305305
*/
306306
@ParameterizedTest
307307
@MethodSource(value = {"duplicateHeaderData"})
308-
public void testCSVParser(final DuplicateHeaderMode duplicateHeaderMode,
308+
void testCSVParser(final DuplicateHeaderMode duplicateHeaderMode,
309309
final boolean allowMissingColumnNames,
310310
final boolean ignoreHeaderCase,
311311
final String[] headers,

src/test/java/org/apache/commons/csv/CSVFileParserTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ private String readTestData(final BufferedReader reader) throws IOException {
5959

6060
@ParameterizedTest
6161
@MethodSource("generateData")
62-
public void testCSVFile(final File testFile) throws Exception {
62+
void testCSVFile(final File testFile) throws Exception {
6363
try (FileReader fr = new FileReader(testFile); BufferedReader testDataReader = new BufferedReader(fr)) {
6464
String line = readTestData(testDataReader);
6565
assertNotNull("file must contain config line", line);
@@ -104,7 +104,7 @@ public void testCSVFile(final File testFile) throws Exception {
104104

105105
@ParameterizedTest
106106
@MethodSource("generateData")
107-
public void testCSVUrl(final File testFile) throws Exception {
107+
void testCSVUrl(final File testFile) throws Exception {
108108
try (FileReader fr = new FileReader(testFile); BufferedReader testData = new BufferedReader(fr)) {
109109
String line = readTestData(testData);
110110
assertNotNull("file must contain config line", line);

src/test/java/org/apache/commons/csv/CSVFormatPredefinedTest.java

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -34,52 +34,52 @@ private void test(final CSVFormat format, final String enumName) {
3434
}
3535

3636
@Test
37-
public void testDefault() {
37+
void testDefault() {
3838
test(CSVFormat.DEFAULT, "Default");
3939
}
4040

4141
@Test
42-
public void testExcel() {
42+
void testExcel() {
4343
test(CSVFormat.EXCEL, "Excel");
4444
}
4545

4646
@Test
47-
public void testMongoDbCsv() {
47+
void testMongoDbCsv() {
4848
test(CSVFormat.MONGODB_CSV, "MongoDBCsv");
4949
}
5050

5151
@Test
52-
public void testMongoDbTsv() {
52+
void testMongoDbTsv() {
5353
test(CSVFormat.MONGODB_TSV, "MongoDBTsv");
5454
}
5555

5656
@Test
57-
public void testMySQL() {
57+
void testMySQL() {
5858
test(CSVFormat.MYSQL, "MySQL");
5959
}
6060

6161
@Test
62-
public void testOracle() {
62+
void testOracle() {
6363
test(CSVFormat.ORACLE, "Oracle");
6464
}
6565

6666
@Test
67-
public void testPostgreSqlCsv() {
67+
void testPostgreSqlCsv() {
6868
test(CSVFormat.POSTGRESQL_CSV, "PostgreSQLCsv");
6969
}
7070

7171
@Test
72-
public void testPostgreSqlText() {
72+
void testPostgreSqlText() {
7373
test(CSVFormat.POSTGRESQL_TEXT, "PostgreSQLText");
7474
}
7575

7676
@Test
77-
public void testRFC4180() {
77+
void testRFC4180() {
7878
test(CSVFormat.RFC4180, "RFC4180");
7979
}
8080

8181
@Test
82-
public void testTDF() {
82+
void testTDF() {
8383
test(CSVFormat.TDF, "TDF");
8484
}
8585
}

0 commit comments

Comments
 (0)