Skip to content

Upgrading

This page lists what to change in your build when you upgrade ReqCover; for the full change list see Releases.

Update the version of all ReqCover dependencies to 0.0.12. Then check:

  • Coverage settings: reqCover.minimumRequiredCoveragePercent must be a number from 0 to 100 and reqCover.failIfBelowMinimum must be true or false. A value such as 100% or yes used to be accepted silently; it now fails the build with an Invalid value error. Fix the value.
  • JUnit 5: works again; you can stay on JUnit 5.
  • XML report readers: the coverage attribute always uses a dot now (50.0), also on machines with a German or similar locale.

No breaking changes. Update the version of all ReqCover dependencies to 0.0.11.

Optional:

  • Maven users: set reqCover.reportsDir so the reports go to target/ instead of build/:

    <systemPropertyVariables>
    <reqCover.reportsDir>${project.build.directory}/reqcover</reqCover.reportsDir>
    </systemPropertyVariables>
  • Cucumber users: add reqcover-engine-cucumber (Maven: reqcover-engine-cucumber-jvm) and register the plugin. See the Cucumber guide.

  • Reporter authors: override report(tracker, reportsDirectory) to honour reqCover.reportsDir. Existing reporters keep working unchanged.

0.0.9 0.0.10
dev.reqcover:reqcover-junit-jupiter dev.reqcover:reqcover-engine-junit-jupiter
Maven: reqcover-junit-jupiter-jvm Maven: reqcover-engine-junit-jupiter-jvm
build.gradle.kts
dependencies {
testImplementation("dev.reqcover:reqcover-engine-junit-jupiter:0.0.10")
}
pom.xml
<dependency>
<groupId>dev.reqcover</groupId>
<artifactId>reqcover-engine-junit-jupiter-jvm</artifactId>
<version>0.0.10</version>
<scope>test</scope>
</dependency>

The singular setting is removed. Rename it to reqCover.requirementsUris (plural); the value can stay as it is.

src/test/resources/junit-platform.properties
reqCover.requirementsUris=requirements.yaml

If the old key is still set, a JUnit build fails with The reqCover.requirementsUri configuration parameter has been removed. Use reqCover.requirementsUris instead. TestNG and Cucumber ignore the old key, so it no longer has any effect there.

JVM system properties now also win over JUnit configuration parameters passed to the launcher, for example Gradle configurationParameter(...) or Surefire configurationParameters (they already won over junit-platform.properties). If you set a reqCover.* key in both places, the system property is used. See Precedence.

A requirements file that is missing, malformed or not in a supported format now fails the build. In 0.0.9 such a run could pass with 100% coverage. If the build fails after the upgrade, check the paths in reqCover.requirementsUris; see Troubleshooting.

ReqCover 0.0.10 and 0.0.11 forced JUnit Platform 6 on projects, so on JUnit 5 test discovery failed with DiscoveryIssueException. From 0.0.12 on, your project’s own JUnit 5 or 6 is used; upgrade to 0.0.12 or later instead of 0.0.10 or 0.0.11.

Parameterized, repeated and @TestFactory tests now cover their requirement only if at least one run passes, and parallel runs no longer lose requirements. Coverage can drop where it was overstated before.