-
Notifications
You must be signed in to change notification settings - Fork 79
Description
Is your feature request related to a problem? Please describe.
I'd like to be able to run only certain tests from the gradle nativeTest
target, in the same way as gradle test --tests 'testPattern'
(gradle test filtering) works.
Please make sure that you are using the latest plugin version, and that similar feature hasn't been requested before.
native-build-tools
version 0.9.23
gradle
versions tried:
- 8.2.1
- 7.6
Describe the solution you'd like
When executing the gradle nativeTest target --tests PATTERN
, the test runner should run only tests whose method name matches PATTERN
, following the same specification as the gradle test
target does as documented in the Gradle Test Filtering docs:
https://docs.gradle.org/current/userguide/java_testing.html#test_filtering
Describe alternatives you've considered
I've resorted to commenting-out the unwanted tests.
Note that I have successfully configured the test filter in build.gradle
. The following works fine, and only runs the TestClass.testMethod
test:
test {
filter {
//include specific method in any of the tests
includeTestsMatching "*TestClass.testMethod"
}
}
I'm logging this issue because it'd be convenient for the command line option to work as well.
Additional context
none