RFR: 7903934: Add support for query strings to the IntelliJ plugin [v2]

Christian Stein cstein at openjdk.org
Tue Feb 4 11:16:25 UTC 2025


On Wed, 29 Jan 2025 19:15:13 GMT, Jorn Vernee <jvernee at openjdk.org> wrote:

>> This patch adds support for JTReg query strings to the IntelliJ plugin. Query strings can be used to run individual test methods in JUnit and TestNG tests, and nested test classes (`@Nested`) in JUnit tests. When creating a run configuration from an element in a source file, e.g. by clicking on the little green 'play' button in the margin, the plugin will automatically compute a query string to run that element (if it knows how to).
>> 
>> One issue I faced when implementing this, is that the IntelliJ type API `PsiType` does not have a way to retrieve the binary name of that type, which is required to run JUnit tests that have parameters. So, I had to manually implement this. You'll see this back in the code.
>> 
>> I've tested this by creating and running a variety of configurations for different test methods, accepting different parameter types, as well as running `@Nested` test classes.
>
> Jorn Vernee has updated the pull request incrementally with one additional commit since the last revision:
> 
>   Use qualified class name, for the sake of nested test classes

Seeing more errors with the Gradle Wrapper check lately. Anything we can do about it in this PR?

https://github.com/sormuras/jtreg/actions/runs/13132506775/job/36640486792

![image](https://github.com/user-attachments/assets/88d3c64b-2263-465b-ad6c-57893cb475c0)

-------------

PR Comment: https://git.openjdk.org/jtreg/pull/240#issuecomment-2633593805


More information about the jtreg-dev mailing list