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

Duplicate org.pitest pitest-maven in both build and reporting sections #1286

Open
patpatpat123 opened this issue Dec 21, 2023 · 0 comments
Open

Comments

@patpatpat123
Copy link

  • What I am trying to achieve:

I would like to generate pitest mutation report without a duplicate for org.pitest pitest-maven in both the build and reporting sections.

Following this guide: https://pitest.org/quickstart/maven/ the bottom of the page, I have this configuration:

 <build>
        <plugins>
            <plugin>
                <groupId>org.pitest</groupId>
                <artifactId>pitest-maven</artifactId>
                <version>1.15.3</version>
            </plugin>

And in the reporting section:

  <reporting>
        <plugins>
          <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-pmd-plugin</artifactId>
                <version>3.21.2</version>
                <configuration>
                    <outputDirectory>target/reports/pmd</outputDirectory>
                    <skipEmptyReport>false</skipEmptyReport>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.pitest</groupId>
                <artifactId>pitest-maven</artifactId>
            </plugin>

Please note the one and only one PMD plugin section, maven-pmd-plugin is only present in reporting, not in build.

I took pmd, but it is also true with spotbugs, checkstyle, and others.

With this, when I run mvn site, the pmd plugin is being invoked (I did not use mvn pmd:pmd).

Furthermore, the pmd report is available to view on the site generated by maven, happy.

This is also true for spotbugs, checkstyle, etc...

With that, I was hoping the same would happen for pitest.

Meaning, mvn site would run pitest, as well as generate the pitest report, visible in the final site, and if possible, with only one pitest section in reporting only (like pmd, checkstyle, spotbugs etc)

  • Issue:

If I add pitest only in the reporting section, pitest is not being invoked at all

If I add pitest in both the reporting and build sections, pitest is invoked, but it is duplicated between the two sections.

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

No branches or pull requests

1 participant