Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Better support --test-junit-test with classname, remove support for file path #7589
jsirois left a comment
The code tries awfully hard to support all four:
Do you mind cleaning up dead code to match your help change or else fixing the code and reverting your help change?
changed the title
[WIP] Better support --test-junit-test with classname, remove support for file name
Apr 21, 2019
Sorry I meant to update the help message in the description as well. For non fully qualified classname, the current implementation is to exact match the last portion of the fully qualified name. If that's not immediately obvious or reasonable to folks, I'd be happy to trim it off.…
On Sat, Apr 20, 2019, 7:18 PM John Sirois ***@***.***> wrote: ***@***.**** commented on this pull request. ------------------------------ In src/python/pants/backend/jvm/tasks/junit_run.py <#7589 (comment)>: > @@ -513,11 +409,29 @@ def _sort_properties(properties_with_tests): for i in range(0, len(sorted_tests), stride): yield properties, sorted_tests[i:i + stride] + def _parse(self, test_spec_str): + """Parses a test specification string into an object that can yield corresponding tests. + + Tests can be specified in one of four forms: + + * [classname] Just two forms: - [fully qualified classname - [fully qualified classname]#[methodname] In order to support [classname] variants of this we'd have to support some sort of policy for finding unqualified classnames which I'm pretty sure we'd all agree we don't want to wade into... but you did below! I vote to stick to the PR purpose and just trim the option help / code to do what it claims and not add new functionality (guessing unqualifed class names). That is better added in a follow up iff there is agreement this is a wise feature to add. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#7589 (review)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AAERTBU7WACRY3QGG7KYHA3PRPFG3ANCNFSM4HHAJ5RQ> .