Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

@Option to select tests for PitestTask #143

Closed
Vampire opened this issue Sep 2, 2019 · 4 comments
Closed

@Option to select tests for PitestTask #143

Vampire opened this issue Sep 2, 2019 · 4 comments

Comments

@Vampire
Copy link
Contributor

Vampire commented Sep 2, 2019

Since Gradle 4.6 you can add custom command-line flags for tasks using the @option annotation.
It would be nice if the PitestTask had such an option like --tests for the Test task, to easily select the tests to run to not have to always run all tests when you are working on something specific.

@szpak szpak added this to the 1.4.6 milestone Sep 6, 2019
@szpak
Copy link
Owner

szpak commented Sep 9, 2019

Last of support for List/SetProperty (explained in #139) makes the implemention of that harder (more "hacky").

@szpak
Copy link
Owner

szpak commented Sep 11, 2019

I implemented it as:

gw pitets --targetTests com.example.tests.*

which overrides targetTests defined in the project configuration. Does it satisfy your needed?

@Vampire
Copy link
Contributor Author

Vampire commented Sep 16, 2019

Well, I called it --tests to have it consistent with the default Gradle Test task, but --targetTests will probably also do, as long as it works as intended. :-)

@Vampire
Copy link
Contributor Author

Vampire commented Sep 18, 2019

Hm, while thinking about it, for my use-case it would actually be more helpful to be able to (also) set targetClasses, can you do the same for that one please? :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants