Cannot use jacoco JVM args and surefire JVM args together in maven

前端 未结 10 513
深忆病人
深忆病人 2020-11-30 01:48

I am using maven with the jacoco plugin to generate code coverage metrics. I am having some difficulty in configuring the surefire plugin with the java opt

10条回答
  •  失恋的感觉
    2020-11-30 02:19

    Try using

    @{argLine}
    

    instead of

    ${argLine}
    

    (or surefire.argLine in your case)

    It allows surefire to read a property as modified by other plugins instead of reading the one substituted by Maven itself. Then you can set the argLine param to empty in Maven properties:

    
        
    
    

    Which now will not cause any problems. More here: How do I use properties set by other plugins in argLine?

提交回复
热议问题