What's New > Version 2020.07.a

Improved information and guidance

Release date: Jul 06, 2020

Cover now provides improved information, and guidance, if an incomplete class path is provided, if tests are discarded during test verification, or if initialization fails on Spring projects. In addition, when appropriate, Cover now writes tests which use the @ContextConfiguration annotation instead of @SpringBootTest.


Full Release Notes

Enhancements

  • When appropriate, Cover will now write tests which use the @ContextConfiguration annotation instead of @SpringBootTest. [Ref: TG-12118]

  • CLI: Cover now provides improved information, and guidance, if an incomplete class path is provided. [Ref: TG-12080]

  • CLI: Cover now provides improved information, and guidance, if tests are discarded during test verification. [Ref: TG-11848]

  • CLI: Cover now provides improved information, and guidance, if initialization fails on Spring projects. [Ref: TG-11718]

Resolved Issues

  • IntelliJ Plugin: Resolved an issue where links are not provided in IntelliJ’s event log when existing tests are extended. [Ref: TG-12157]

  • IntelliJ Plugin: Cover no longer leaves temporary files, used for test generation, in /tmp. Files created by execution of the project code may still be present. [Ref: TG-12126]

  • Resolved an issue where Cover’s assertion generation may insert assertions which are invalid and will not compile. [Ref: TG-12092]

  • Resolved an issue where, on some projects, Cover would provide an empty string as an input to a constructor rather than a context-aware string. [Ref: TG-12087]

  • Cover no longer attempts to install Visual C++ Redistributable Runtimes if a suitable version, or newer, is detected. [Ref: TG-12083]

  • IntelliJ Plugin: Resolved an issue where, on some projects, selecting ‘Write Tests’ on a multi-module project, without a test source directory, results in an error containing The file '<filename>' is not under content entry root '<path>'. [Ref: TG-12056]

  • CLI: Resolved an issue where, on some projects, tests are written which pass on their first run but fail on subsequent runs. [Ref: TG-12049]

  • CLI: Resolved an issue where issuing Ctrl+c to terminate Cover during execution on a Gradle project will cause subsequent runs to fail, reporting Creating tests failed. [Ref: TG-12046]

  • CLI: Resolved an issue where, on some projects, Cover’s summary statistics may not add up to the total. [Ref: TG-11935]

  • IntelliJ Plugin: Resolved an issue where a NullPointerException can occur when indexing the same project from more than one IntelliJ instance. [Ref: TG-11861]

Known Issues

  • Wrong reason for not creating essential tests for methods in classes without accessible constructors. [Ref: TG-10794]

  • CLI: Windows: creating config.json by outputting --example-config as file causes exceptions. [Ref: TG-11198]

  • CLI: Analyzing a project that opens lots of files may crash dcover. [Ref: TG-11455]

  • CLI: All tests may be discarded in test verification when using --config. [Ref: TG-11475]

  • CLI: dcover clean --working-directory throws an error if --test-output-dir is not provided. [Ref: TG-11665]

  • CLI: dcover fails to generate tests, reporting java.lang.OutOfMemoryError, when analysing projects which spawn a quantity of threads in excess of the operating system’s process thread limit. [Ref: TG-11680]

  • CLI: dcover clean --failing fails when used with a Gradle project. [Ref: TG-11707]

  • Tests are not generated for methods of Spring controllers that contain an autowired field. [Ref: TG-11835]

  • IntelliJ Plugin: Selecting ‘Write tests’ across multiple modules, in quick succession, can cause the plugin to crash with a NullPointerException. [Ref: TG-12022]

  • CLI: Test verification may fail on a Gradle project due to an incompatibility between Gradle and Cover. If you encounter this issue, run with --skip-test-verification. [Ref: TG-12045]

  • IntelliJ Plugin: Cover installation fails on IntelliJ 2020.1 Community Edition on Red Hat Enterprise Linux. [Ref: TG-12272]

Dependencies for written tests

  • JUnit: 4.7-5.6