Skip to content

Add new option to allow full delegation of IntelliJ tests to Gradle #126772

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

lukewhiting
Copy link
Contributor

Low priority

This PR adds a new option to our Gradle build that lets the user specify they would like all runs and test runs created by IntelliJ through clicking gutter icons etc to use Gradle as the execution engine rather than IntelliJs own runner.

Currently, we use the IntelliJ plugin for Gradle to override these settings in the IDE every time we import the ES repo. This means the user has no way to express their preference for how tests should be run in the IDE as any change made to IntelliJ's settings is overridden next import.

This is especially frustrating as running test with the IntelliJ test runner is generally not possible so it just adds extra clicks when running tests.

Users can enable this delegation of all runs by setting org.elasticsearch.idea-delegate-to-gradle=true in ~/.gradle/gradle.settings. Default's to existing behaviour (Prompt user for test runner choice)

This PR also contains documentation for this setting and the currently undocumented setting that appends --configuration-cache to all generated run configs.

I tagged @mark-vieira in this one as he created the initial config. Also open to just making this the default behaviour and prompting be the override.

@lukewhiting lukewhiting requested review from mark-vieira and a team April 14, 2025 10:15
@lukewhiting lukewhiting added the Team:Delivery Meta label for Delivery team label Apr 14, 2025
Copy link
Contributor

@mark-vieira mark-vieira left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems reasonable to me but I think @breskeby should have eyes on this as well.

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

Successfully merging this pull request may close these issues.

3 participants