Enabling assertions should take an argument
On the command line, -ea takes an argument (the package). However, the property in the tycho surefire test configuration does not:
https://tycho.eclipseprojects.io/doc/latest/tycho-surefire-plugin/test-mojo.html
@khatchad do you like to propose a PR at best with an integration-test to demonstrate the issue?
I think it's more of an enhancement than an issue. The workaround is as follows:
<properties>
<!-- Enable assertions for the xyz.abc package and its subpackages. -->
<tycho.testArgLine>-ea:xyz.abc...</tycho.testArgLine>
</properties>
I'll have a look.
Looks like there's an existing assertions test. And, here's the corresponding field:
https://github.com/eclipse-tycho/tycho/blob/0fde42d1731d8084ad8997fc9e232ac51f5574da/tycho-surefire/tycho-surefire-plugin/src/main/java/org/eclipse/tycho/surefire/AbstractEclipseTestMojo.java#L220-L227
@laeubi What is the desired API change here? How are configuration parameters that optimally take arguments typically handled in Tycho?
In this case I would simply go for changing boolean -> String parameter, then where it is used we can check if it is true/false --> work as before, else assume it is a package name to be passed as -ea parameter.