Skip to content

Make running test in Intellij work with JaCoCo#8526

Merged
fjy merged 2 commits intoapache:masterfrom
ccaominh:run-tests-in-intellij
Sep 14, 2019
Merged

Make running test in Intellij work with JaCoCo#8526
fjy merged 2 commits intoapache:masterfrom
ccaominh:run-tests-in-intellij

Conversation

@ccaominh
Copy link
Copy Markdown
Contributor

Fixes #8524.

Description

After the jacoco-maven-plugin was added, running test in IntelliJ fails with the error Could not find or load main class @{jacocoArgLine}. Add a default IntelliJ configuration file so that running tests in the IDE works with the jacoco-maven-plugin configuration and the out-of-the-box developer experience is better. Other solutions described in https://stackoverflow.com/q/24115142 (e.g., setting an empty "jacocoArgLine" maven property) did not work.


This PR has:

  • been self-reviewed.

After the jacoco-maven-plugin was added, running test in IntelliJ fails
with the error "Could not find or load main class @{jacocoArgLine}".
Add a default IntelliJ configuration file so that running tests in the
IDE works with the jacoco-maven-plugin configuration and the
out-of-the-box developer experience is better. Other solutions described
in https://stackoverflow.com/q/24115142 (e.g., setting an empty
"jacocoArgLine" maven property) did not work.
@ccaominh
Copy link
Copy Markdown
Contributor Author

(openjdk11) server module test (SQL Compatibility) needs to be retriggered on Travis

@clintropolis clintropolis added the Area - Dev For items related to the project itself, like dev docs and checklists, but not CI label Sep 13, 2019
Copy link
Copy Markdown
Member

@leventov leventov left a comment

Choose a reason for hiding this comment

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

Thanks! I confirm that it works.

Comment thread .idea/mavenProjectSettings.xml Outdated
<component name="MavenProjectSettings">
<option name="testRunningSettings">
<MavenTestRunningSettings>
<option name="passArgLine" value="false" />
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Could you please add line

        <!-- See https://github.com/apache/incubator-druid/issues/8524 -->

Before this line.

Copy link
Copy Markdown
Member

@leventov leventov Sep 13, 2019

Choose a reason for hiding this comment

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

Or better reference https://github.com/apache/incubator-druid/pull/8526 (i. e. this PR) because it has extra details in the description.

@fjy fjy merged commit c254261 into apache:master Sep 14, 2019
@ccaominh ccaominh deleted the run-tests-in-intellij branch September 20, 2019 20:42
@jon-wei jon-wei added this to the 0.17.0 milestone Dec 17, 2019
gianm pushed a commit to implydata/druid-public that referenced this pull request Jan 2, 2020
* Make running test in Intellij work with JaCoCo

After the jacoco-maven-plugin was added, running test in IntelliJ fails
with the error "Could not find or load main class @{jacocoArgLine}".
Add a default IntelliJ configuration file so that running tests in the
IDE works with the jacoco-maven-plugin configuration and the
out-of-the-box developer experience is better. Other solutions described
in https://stackoverflow.com/q/24115142 (e.g., setting an empty
"jacocoArgLine" maven property) did not work.

* Add comment with link to PR
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area - Dev For items related to the project itself, like dev docs and checklists, but not CI Bug Development Blocker

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cannot run an individual test method from IntelliJ IDEA

5 participants