Skip to content

addScalacArgs option breaks scoverage #99

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

Closed
ashokaupadhya opened this issue Dec 14, 2021 · 3 comments
Closed

addScalacArgs option breaks scoverage #99

ashokaupadhya opened this issue Dec 14, 2021 · 3 comments

Comments

@ashokaupadhya
Copy link

ashokaupadhya commented Dec 14, 2021

I have following configuration for scala maven plugin. Adding "addScalacArgs" doesn't generate coverage info. I see "Skipping SCoverage report generation" in the log but if i remove "addScalacArgs" reports are generated.

scala version 2.11.12

<plugin>
   <groupId>net.alchim31.maven</groupId>
   <artifactId>scala-maven-plugin</artifactId>
   <version>4.5.4</version>
   <executions>
      <execution>
         <id>scala-compile-first</id>
         <phase>process-resources</phase>
         <goals>
            <goal>add-source</goal>
            <goal>compile</goal>
         </goals>
      </execution>
      <execution>
         <id>scala-test-compile</id>
         <phase>process-test-resources</phase>
         <goals>
            <goal>testCompile</goal>
         </goals>
      </execution>
   </executions>
   <configuration>
      <addScalacArgs>-target:jvm-1.8</addScalacArgs>
      <scalaVersion>${scala-version}</scalaVersion>
      <javacGenerateDebugSymbols>true</javacGenerateDebugSymbols>
   </configuration>
</plugin>
@vivekaradshan
Copy link

Any updates on this? We are facing the same issue addScalacArgs is skipping scoverage generation

@vivekaradshan
Copy link

vivekaradshan commented Jun 13, 2022

I tried passing in the below format. It resolved the issue
<configuration>
<args>
<arg>-target:jvm-1.8</arg>
</args>
</configuration>

@jozic
Copy link
Collaborator

jozic commented Oct 28, 2023

README specifies this limitation here
Also, scala-maven-plugin doc also states that addScalacArgcan't be used from pom.
Please send a PR if you think the doc can be improved. Thanks.

@jozic jozic closed this as not planned Won't fix, can't repro, duplicate, stale Oct 28, 2023
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

3 participants