Skip to content

Commit

Permalink
fix fail test run with enabled junit.testFilter option
Browse files Browse the repository at this point in the history
  • Loading branch information
Sparkymann committed Oct 7, 2024
1 parent 0420683 commit 7e3c820
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ void filter(TestDescriptor descriptor) {

String testFilterProperty = configuration.getProperty(JUNIT_TEST_FILTER_PROPERTY_NAME);
List<String> memberNames = Splitter.on(",").splitToList(testFilterProperty);
Predicate<TestDescriptor> shouldRunPredicate = testDescriptor -> memberNameMatches(testDescriptor, memberNames);
Predicate<TestDescriptor> shouldRunPredicate =
testDescriptor -> !(testDescriptor instanceof AbstractArchUnitTestDescriptor) || memberNameMatches(testDescriptor, memberNames);
removeNonMatching(descriptor, shouldRunPredicate);
}

Expand Down

0 comments on commit 7e3c820

Please sign in to comment.