Search in sources :

Example 1 with CsvSource

use of org.junit.jupiter.params.provider.CsvSource in project VocabHunter by VocabHunter.

the class FileNameToolTest method testIsSessionFile.

@ParameterizedTest
@CsvSource({ "'test.wordy',       true", "'/home/test.wordy', true", "'/home/test',       false", "'/home/test.txt',   false" })
public void testIsSessionFile(final String name, final boolean expected) {
    Path file = Paths.get(name);
    assertEquals(expected, FileNameTool.isSessionFile(file));
}
Also used : Path(java.nio.file.Path) CsvSource(org.junit.jupiter.params.provider.CsvSource) ParameterizedTest(org.junit.jupiter.params.ParameterizedTest)

Aggregations

Path (java.nio.file.Path)1 ParameterizedTest (org.junit.jupiter.params.ParameterizedTest)1 CsvSource (org.junit.jupiter.params.provider.CsvSource)1