Search in sources :

Example 1 with FileSelector

use of org.junit.platform.engine.discovery.FileSelector in project junit5 by junit-team.

the class DiscoveryRequestCreatorTests method convertsFileSelectors.

@Test
void convertsFileSelectors() {
    options.setSelectedFiles(asList("foo.txt", "bar.csv"));
    LauncherDiscoveryRequest request = convert();
    List<FileSelector> fileSelectors = request.getSelectorsByType(FileSelector.class);
    assertThat(fileSelectors).extracting(FileSelector::getRawPath).containsExactly("foo.txt", "bar.csv");
}
Also used : LauncherDiscoveryRequest(org.junit.platform.launcher.LauncherDiscoveryRequest) FileSelector(org.junit.platform.engine.discovery.FileSelector) Test(org.junit.jupiter.api.Test)

Aggregations

Test (org.junit.jupiter.api.Test)1 FileSelector (org.junit.platform.engine.discovery.FileSelector)1 LauncherDiscoveryRequest (org.junit.platform.launcher.LauncherDiscoveryRequest)1