Skip to content

Commit 5d06504

Browse files
committed
Polish contribution
1 parent 8f71c19 commit 5d06504

File tree

2 files changed

+2
-10
lines changed

2 files changed

+2
-10
lines changed

platform-tests/src/test/java/org/junit/platform/engine/discovery/DiscoverySelectorsTests.java

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -389,16 +389,11 @@ void parseClasspathResourcesWithFilePosition() {
389389
.containsExactly("A/B/C/spec.json", Optional.of(filePosition));
390390
}
391391

392-
private static class StubResource implements Resource {
393-
private final String name;
394-
395-
private StubResource(String name) {
396-
this.name = name;
397-
}
392+
private record StubResource(String name) implements Resource {
398393

399394
@Override
400395
public String getName() {
401-
return name;
396+
return name();
402397
}
403398

404399
@Override

platform-tests/src/test/java/org/junit/platform/engine/support/discovery/ResourceContainerSelectorResolverTest.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ void shouldDiscoverAllResourcesInPackage() {
5959
"org/junit/platform/commons/example.resource",
6060
"org/junit/platform/commons/other-example.resource");
6161
// @formatter:on
62-
6362
}
6463

6564
@Test
@@ -78,7 +77,6 @@ void shouldDiscoverAllResourcesInRootPackage() {
7877
"org/junit/platform/commons/example.resource",
7978
"org/junit/platform/commons/other-example.resource");
8079
// @formatter:on
81-
8280
}
8381

8482
@Test
@@ -97,7 +95,6 @@ void shouldFilterPackages() {
9795
"org/junit/platform/commons/example.resource",
9896
"org/junit/platform/commons/other-example.resource");
9997
// @formatter:on
100-
10198
}
10299

103100
@Test

0 commit comments

Comments
 (0)