All pages
Powered by GitBook
Couldn't generate the PDF for 106 pages, generation stopped at 100.
Extend with 50 more pages.
1 of 100

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

2025-12-01

This release writes more efficient test suites by default for both the CLI and IntelliJ plugin, enhances the dcover issues command, and introduces an opt-in caching mechanism to improve CLI performance.


Improved Test Efficiency & Quality

  • Efficient Test Suites by Default: Diffblue Cover now writes more efficient test suites by default in both the CLI and IntelliJ Plugin (for JUnit Jupiter), generating fewer tests without reducing coverage. In the CLI, the --new-diffblue-coverage option has been removed (use --ignore-existing-coverage for maximum tests). In the IntelliJ Plugin, this optimization can be disabled in the settings.

  • JaCoCo Exclusion Recommendations: To help produce more meaningful JaCoCo reports, Cover now identifies auto-generated classes and recommends their exclusion in the CLI output and logs, focusing coverage calculations on manually written code.

CLI Enhancements & Performance

  • dcover issues Summary: The dcover issues command now provides a complete overview by summarizing all issues grouped by type. For a detailed, prioritized list, use the --prompt mode, which respects pagination options like --limit and --skip.

  • Performance Caching: An opt-in caching mechanism is now available for time-consuming environment checks. Using the --use-cache or --cache

IntelliJ Plugin Stability

  • Improved Environment Checks: Resolved an issue in the IntelliJ Plugin where Cover could fail with an internal error during environment checks. This fix improves stability and ensures test creation can proceed more reliably.


Enhancements

  • CLI: Diffblue Cover now helps produce more meaningful JaCoCo coverage reports by identifying auto-generated classes and recommending their exclusion in the CLI output and logs. This aligns with best practices, focusing coverage calculations on manually written code. [Ref: TG-23987]

  • Plugin: For JUnit Jupiter users, Diffblue Cover now writes more efficient test suites by default, generating fewer tests while maintaining coverage. This optimization can be disabled in the plugin settings. [Ref: TG-23922]

  • CLI: The dcover issues command now summarizes all issues grouped by type, providing a complete overview. For a detailed, prioritized list that respects pagination (--limit, --skip

Resolved Issues

  • Plugin: Resolved an issue in the IntelliJ Plugin where Diffblue Cover could fail with an internal error during environment checks. This fix improves stability, preventing rare failures and ensuring test creation can proceed more reliably. [Ref: TG-24016]

Known Issues

  • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

  • Using JDKs other than the supported Open JDK and Oracle JDK may produce unexpected results due to implementation differences. [Ref: TG-19345]

  • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. The recommended workaround is to downgrade to Mockito 4.x. [Ref: TG-19610]

options will improve performance on subsequent runs of commands such as
dcover create
.
), use the
--prompt
mode. [Ref: TG-23920]
  • CLI: Diffblue Cover now writes more efficient test suites by default, generating fewer tests while maintaining coverage. The --new-diffblue-coverage option is removed. For maximum test generation, use the --ignore-existing-coverage option. [Ref: TG-23871]

  • CLI: Diffblue Cover now includes an opt-in caching mechanism for time-consuming environment checks. Using the --use-cache or --cache options improves performance on subsequent runs of commands like dcover create. [Ref: TG-23377]

  • Reports: The total line count metric in Reports only includes Java code. Kotlin code is not included. [Ref: TG-22088]

  • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

  • When test formatting settings are changed, the Test Review feature may incorrectly remove the @ManagedByDiffblue annotation from tests, particularly in cases involving static import formatting changes. [Ref: TG-23750]

  • Plugin: Using the Test Review feature may create tests that have incompatible dependency injection systems. [Ref: TG-23935]

  • 2024-05-01

    This release adds a 'lines of code' quota count to Cover Reports to help monitor usage. Cover CLI and Plugin now write tests for equals(Object) and hashCode() methods with more descriptive names. Additionally, Cover CLI and Plugin have received usability, performance and test writing bug fixes, detailed in the full release notes.

    Enhancements

    • Cover now has an updated version of OpenRewrite used for Refactor. If you're utilizing a local Maven/Gradle mirror, you may need to update it to ensure it supports the necessary versions of the OpenRewrite Maven/Gradle plugin and its dependencies. [Ref: TG-21141]

    • Reports: Cover now provides a 'lines of code' quota count on the Overview tab. [Ref: TG-20696]

    • CLI: Cover now provides improved logging of license verification failures to help diagnose licensing-related issues. [Ref: TG-20576]

    • Cover now provides improved test names for equals(Object) and hashCode() methods, detailing both the test conditions and expected outcomes. [Ref: TG-17284]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to not enforce the --validation-timeout when executing a simple example test during environment checks. [Ref: TG-21207]

    • CLI: Resolved an issue which, in some circumstances, caused Cover to duplicate the 'Run Summary' output. [Ref: TG-21188]

    • Resolved an issue which caused Cover to not write tests when Powermock for Mockito 2 is used. [Ref: TG-21175]

    Known Issues

    • Plugin: Cover Plugin incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Diffblue Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • CLI & Plugin: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2024-07-04

    This release includes improvements to the quality of assertions in unit tests written by Cover and resolves issues within Cover Reports.

    Important Notices

    Removals

    • JUnit 4.7-4.10: Support for JUnit 4.7 through 4.10 has been removed. Please upgrade to JUnit 4.11 or higher.

    Enhancements

    • CLI & Reports: Cover now provides a breakdown of manually written and Diffblue Cover written test coverage during dcover upload. [Ref: TG-21683]

    • Cover now writes tests which assert on the bytes inside InputStreams, InputStreamReaders and BufferedReaders. [Ref: TG-20804]

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to report F009 (Internal error) while writing tests for methods which contain Maps which have classes as values. [Ref: TG-21672]

    • Reports: Resolved an issue which, in some circumstances, caused Cover Reports to show Unexpected Application Error when loading the home page. [Ref: TG-21667]

    • Resolved an issue which caused Cover to report F009

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2023-09-02

    This release provides improvements to assertions, partial test candidates, and Cover Reports dashboards, as well as multi-method selection in Cover Plugin. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: Diffblue Cover now writes tests with improved assertions to check the content of arrays. [Ref: TG-19965]

    • Cover: Diffblue Cover now writes tests with more assertions for objects with a large number of observers. [Ref: TG-19848]

    • Reports: Cover Reports now provides an enhanced Overview dashboard UI. [Ref: TG-19803]

    • Plugin: Cover Plugin now allows you to write tests for multiple methods in the IntelliJ text editor (highlight the methods, right click, select Write Tests). [Ref: TG-19794]

    • Cover: Diffblue Cover now provides improved partial test candidates and no longer retains partial tests if complete tests have been written. [Ref: TG-19569]

    • Reports: Cover Reports now provides enhanced telemetry graphs. [Ref: TG-19202]

    • Cover: Diffblue Cover now provides improved 'R012 JNI sandbox policy violation' messaging and remediation advice. [Ref: TG-18995]

    Resolved Issues

    • Reports: Resolved an issue in Cover Reports which in some circumstances caused the Run dropdown menu to be incorrectly available. [Ref: TG-19832]

    Known Issues

    • Plugin: Cover plugin incorrectly gives the option to write tests for a test file, within the editor, using the menu option. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2024-10-01

    This release introduces the ability to disable Spring Boot dependency injection (@MockBean) in favor of other dependency injection mechanisms, such as Mockito's @InjectMocks and @Mock. To disable Spring Boot dependency injection, uncheck the 'Use Spring Boot to write tests' option in the plugin settings or pass the --no-spring-boot-tests option to the CLI. This feature can be beneficial when the unit test suite does not require loading a Spring context.

    Important Notices

    2025-02-01

    2025-02-01

    This release includes enhancements and resolves issues for the CLI and IntelliJ plugin. Key improvements include resolving an issue where String values could be incorrectly mocked as dependencies, and the introduction of a template DiffblueBuild.yaml file for Ant projects, simplifying setup.

    2025-01-01

    2025-01-01

    This release introduces performance improvements for Cover Reports, improved Test Review diff options and the ability to prevent Cover from writing tests which call specific methods. It also resolves various issues with the CLI and Plugin.

    Important Notices

    2025-10-01

    Enables precise control over test inputs with the new @InTestsUseFactories annotation and enhances test quality with improved javax.servlet tests and broader assertDoesNotThrow assertions. This release also adds Mockito 5.20.0 support and resolves several test generation failures.


    Improved Test Quality & Control

    2024-11-01

    This release reduces the number of overlapping tests written by Cover, improving readability, maintainability and overall test quality. Various CLI and Plugin issues have also been resolved. Full details of these updates can be found in the release notes below.

    This release also introduces early access support for Developer Edition - see the for more details.

    Enhancements

    • Cover now supports JUnit Jupiter 5.11.3. [Ref: TG-22200]

    2024-09-02

    This release introduces Descriptive Test Naming (beta), a new feature that enables Diffblue Cover to write tests with Given-When-Then-style names.

    For details on how to enable Descriptive Test Naming (beta), please refer to the or the .

    Enhancements

    • Cover now attempts to write tests using the yyyymmdd DateTime format. [Ref: TG-22011]

    2024-09-01

    This release introduces Test Review (Beta), a feature that allows editing, analyzing, and managing Diffblue Cover-generated tests before they are added to the codebase. When enabled, tests are held for review, providing an opportunity to refine them before insertion. For details on how to enable Test Review (Beta), please refer to the .

    Enhancements

    • Plugin: Cover now offers the ability to edit and review Diffblue-generated tests before they are added to a codebase through the Test Review (beta) feature. Test Review (beta) can be enabled in the Diffblue Settings. [Ref: TG-21657]

    2024-07-03

    This release further improves the quality of assertions in unit tests written by Cover, adds support for writing tests for Java 22 projects and relaxes the character restrictions on the CLI's --location and --project-name options when uploading to Cover Reports. Full details of these updates can be found in the release notes.

    Enhancements

    • Cover now writes tests with more robust assertions for

    2023-11-03

    In this release, Diffblue Cover now supports writing tests for Java 21 projects - Diffblue now supports LTS Java versions 8, 11, 17, and 21 in production use. Also, the release includes a significant update to the Cover Reports docs topics - https://docs.diffblue.com/features/cover-reports. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: Diffblue Cover now supports writing tests for Java 21 projects. [Ref: TG-20304]

    2024-08-02

    This release enhances the quality of assertions in unit tests written by Cover, improving both readability and overall test quality. Test writing performance has been improved, especially for projects using Apache Flink. Cover Plugin now supports IntelliJ IDEA 2024.2 and has an improved tool panel window shown while writing tests. Cover Pipeline now supports running in any CI/CD environment which uses git version control.

    Important Notices

    2024-08-01

    This release enhances the quality of assertions in unit tests written by Cover, improving both readability and overall test quality. It also introduces plugin support for IntelliJ IDEA 2024.2. Full details of these updates can be found in the release notes below.

    Important Notices

    Deprecations

    2024-06-01

    This release includes enhancements and fixes across Cover CLI, Plugin, and Reports. The Plugin now offers better performance through cached environment checks. Cover Reports has clearer breadcrumb navigation, making project identification easier. Full details of these updates can be found in the release notes.

    Please note that support for JUnit 4.7 through 4.10 is being deprecated and will be removed in a future release.

    Enhancements

    • Cover now supports Mockito 5.11.0. [Ref: TG-21501]

    2023-08-01

    This release adds support for Lombok’s @Builder annotation and enhances Diffblue Cover licensing via proxy servers to support corporate proxies using intermediate intercept. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: Diffblue Cover now provides more detailed output codes and enhanced remediation advice when the analysis service fails to start.

    2024-04-02

    This release enhances the CLI's create and create --exclude commands, introducing Java-like syntax and wildcard capabilities to specify which packages, classes, or methods to write tests for, while preserving backward compatibility.

    Cover Reports now provides different time periods for viewing telemetry data and the ability to view 'Lines of Code' on the 'Coverage Over Time' chart.

    Enhancements

    2023-11-01

    In this release, Diffblue Cover will write tests for all major versions of Java from 8-17. Diffblue only provides support for LTS versions 8, 11, and 17 in production use. Also, the release includes updates for Cover Reports, including the addition of the new --upload option to Cover CLI for uploading reports bundles, and an update to the install location. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    2022-10-02

    Plugin - Improved logging now available

    For our IntelliJ plugin users, additional logging is now available whenever you write either tests or skeleton tests. A timestamped log file is created in addition to the standard logs containing all activity, which makes it significantly easier to find a particular event. The screenshot below shows the contents of the /tmp/diffblue/log directory with the standard user log alongside a new timestamped user log:

    {: width="240" height="150"}

    2024-12-02

    2024-12-02

    This release introduces an easily accessible status bar widget for the Plugin providing quick access to license consumption details. It also resolves various issues with the CLI, Plugin and Reports.

    Important Notices

    2024-03-02

    This release improves test writing for methods utilizing Kafka Consumers and those returning Mono or Flux sequences. Additionally, Cover Reports now shows an overview of project coverage and a list of recently viewed projects. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: Diffblue Cover now writes tests using isA and isNull

    CLI: Resolved an issue which caused Run Summary output to incorrectly display
    ERROR
    and
    WARN
    results at the
    INFO
    log level. [Ref: TG-21167]
  • Plugin: Resolved an issue which caused Cover to show gutter flask icons for Enum classes. [Ref: TG-21161]

  • Plugin: Resolved an issue which, in some circumstances, would cause Cover to request email verification more than once. [Ref: TG-21152]

  • Resolved an issue where Cover would not write tests for methods that take a BiFunction if spring-web was on the classpath but Project Reactor was not. [Ref: TG-20770]

  • CLI & Plugin: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]
  • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • (Internal Error) when writing tests for methods with names which are Java keywords. Cover now reports
    R088
    (Method name is a reserved keyword). [Ref: TG-21642]
    Cover may encounter an
    F009: Internal error
    while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Plugin: Cover Plugin may display tests links which do not work when writing tests for multiple methods at once. To avoid this, write tests at the class level or on single method. [Ref: TG-20050]

  • Plugin: Cover Plugin will get stuck during the 'preparing' phase if the run configurations created by the plugin are used. To avoid this issue, do not use the run configurations created by the plugin. [Ref: TG-20061]

  • Changes to Default Settings
    • Descriptive Test Naming: In a future release, Cover will default to writing tests which use descriptive Given-When-Then-style names. For more details on Descriptive Test Naming (beta), please refer to the IntelliJ Plugin documentation or the Cover CLI documentation.

    Enhancements

    • Cover now supports JUnit Jupiter 5.11.1. [Ref: TG-22087]

    • Cover now writes tests which assert on Iterator objects. [Ref: TG-22079]

    • Cover now supports Maven 3.9.9. [Ref: TG-22039]

    • CLI: Cover now provides the ability to specify which modules to run CLI commands on via the --include-modules option or DIFFBLUE_INCLUDE_MODULES environment variable. [Ref: TG-22019]

    • Cover now provides improved messaging related to interactions with the project's build system. [Ref: TG-21996]

    • Reports: Metric labels have been adjusted to be more consistent and accurate. [Ref: TG-21710]

    • Reports: Improved overview cards, providing new metrics for manual test count, total lines of code, covered and uncovered lines. [Ref: TG-21708]

    • Reports: Updated logo and color scheme. [Ref: TG-21700]

    • Cover now provides an option to disable Spring Boot dependency injection (@MockBean) in favor of other dependency injection mechanisms, such as Mockito's @InjectMocks and @Mock. [Ref: TG-21467]

    • CLI & Reports: Cover now provides improved remediation advice when a JaCoCo report cannot be produced to due non-compiling tests. [Ref: TG-19166]

    Resolved Issues

    • Resolved an issue which caused Cover to produce broken Javadoc links to default constructors with Descriptive Test Naming enabled. [Ref: TG-22012]

    • Resolved an issue which, in some circumstances, caused Cover to write tests which assert on an internal PrintWriter object. [Ref: TG-21959]

    • Resolved an issue which caused Cover to report F009 (Internal Error) when it failed to create a Spring context due to missing Spring beans. [Ref: TG-21931]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    Important Notices

    Updated Test Creation Limits for Diffblue Cover

    As of the 2025.02.01 release, we've updated how test creation limits work for Diffblue Cover to give you more predictable and manageable usage. These changes apply only to Community Edition and Developer Edition. Teams and Enterprise editions are unaffected.

    What's Changed

    • Test creation limits are now based on methods tested, not individual tests written.

    • You will incur consumption for each method for which a new test is successfully produced. This means you have a clearer understanding of your limit usage before clicking 'write tests'.

    • Consumption is calculated based on the number of new methods covered by generated tests, regardless of how many tests are produced for a single method.

    • When Cover Plugin's 'Test Review' feature is enabled, quota consumption will still occur for methods with newly generated tests even if they are not "accepted".

    Monthly Limits

    • Community Edition: 25 methods per month

    • Developer Edition Basic: 100 methods per month

    • Developer Edition Pro: 200 methods per month

    • Developer Edition Ultra: 400 methods per month

    Diffblue Cover is now generally available to individual developers and small teams.

    We've just launched our Developer Edition license. From today, individual developers can leverage the power of AI they can trust for unit test generation and maintenance.

    Enhancements

    • CLI: Cover now provides clearer messages if test validation takes too long. Instead of indicating a failed coverage calculation, it guides users to adjust the TIMEOUT setting in DiffblueBuild.yaml. [Ref: TG-22629]

    • Cover now generates a template DiffblueBuild.yaml file for Ant projects when using dcover build-default-config --ant. The template includes essential configurations and inline customization guidance, simplifying setup. [Ref: TG-22602]

    • Plugin: The "Update Test" functionality now uses the @MethodsUnderTest test annotation for accurately identifying Methods Under Test (MuTs). Please avoid modifying this annotation. [Ref: TG-22462]

    • CLI & Plugin: Cover now counts methods tested instead of tests created. This affects Community Edition, Developer Edition, and Teams Trial users. [Ref: TG-21883]

    • CLI: dcover validate now handles validation errors more precisely. Instead of discarding entire test classes due to issues in a subset of tests (compilation or assertion failures), it discards only the failing tests, preserving the rest. [Ref: TG-20316]

    Resolved Issues

    • CLI: Resolved an issue where Cover incorrectly generated @AfterMethod methods for TestNG, preventing proper reset of mocks and the target object. [Ref: TG-22632]

    • Resolved an issue which could cause Cover to incorrectly mock String values as dependencies, potentially leading to invalid test code such as @MockBean private String string. [Ref: TG-22523]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    Changes to test code
    • Test Method Ordering: In an upcoming release, Cover will adjust test method ordering and imports for inner classes. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code.

    • Test Method Tagging: In an upcoming release, tests created by Cover will be annotated with a MaintainedByDiffblue label. This will cause a one-time churn when recreating test, resulting in larger-than-usual diffs in your test code. This will enable Cover to combine Diffblue tests and manually written tests into the same test classes.

    Requirements

    • JUnit 4: Users of JUnit 4 will soon require the use of the cover-annotations library version 1.3.0+ in order for coverage to be calculated correctly. This will be part of Test Method Tagging.

    Diffblue Cover is now generally available to individual developers and small teams.

    We've just launched our Developer Edition license. From today, individual developers can leverage the power of AI they can trust for unit test generation and maintenance.

    Enhancements

    • Cover now supports Jupiter 5.11.4. [Ref: TG-22497]

    • Reports: Telemetry page performance improvements. [Ref: TG-22415]

    • Plugin: Cover now allows the Test Review window to be expanded/docked for easier test diff reviewing. [Ref: TG-22378]

    • CLI: Cover now allows excluding methods from being called in tests by using the --exclude-method option. [Ref: TG-22235]

    Resolved Issues

    • Plugin: Resolved an issue which prevented the 'What's New' page from loading on Windows following an upgrade. [Ref: TG-22495]

    • Resolved an issue which caused Cover to report R026 while writing tests due to custom base classes not being considered. [Ref: TG-22341]

    • Plugin: Resolved an issue which caused cover to show 'delete test' gutter icons on non-test methods. [Ref: TG-22177]

    • Resolved an issue which caused Cover to write non-compiling tests for overloaded methods with variadic parameters (varargs). [Ref: TG-21835]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    Precise Input Control: Diffblue Cover now supports the @InTestsUseFactories annotation, enabling you to guide test generation by specifying which factory methods should be used to create objects for a given test.

  • Higher Quality Servlet Tests: Cover now generates higher quality tests for projects using javax.servlet. For the best results, add the spring-test dependency to your project, which allows Cover to use Spring's MockHttp classes for test creation.

  • Framework Support & Compatibility

    • Mockito 5.20.0 Support: Diffblue Cover now supports Mockito Core version 5.20.0, ensuring full compatibility for tests generated in projects that use this version of the mocking framework.


    Enhancements

    • Diffblue Cover now supports Mockito Core version 5.20.0, ensuring test compatibility for projects using this version. [Ref: TG-23807]

    • Diffblue Cover now generates higher quality tests for projects using javax.servlet. Adding the spring-test dependency produces more effective tests by using Spring's MockHttp classes to accurately simulate HTTP requests and responses. [Ref: TG-23095]

    • Diffblue Cover now supports the @InTestsUseFactories annotation to provide more precise control over test inputs. This annotation guides test generation by specifying which factory methods Cover must use to create objects for a given test. [Ref: TG-21232]

    Resolved Issues

    • Resolved an issue that caused Cover to report R011 or R081 output codes when writing tests for code using log4j or Mockito. These failures were due to sandbox policy violations during localhost resolution. [Ref: TG-23827]

    • Resolved an issue that limited assertDoesNotThrow test cases. Diffblue Cover now writes these assertions for any validation method, not just those named 'validate', improving test coverage for methods that do not follow a specific naming convention. [Ref: TG-23762]

    • Resolved a test generation failure (F009) that occurred when a method from an instance was referenced multiple times within the method under test. This fix applies to instances created with a parameterized constructor or a factory. [Ref: TG-23416]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. The recommended workaround is to downgrade to Mockito 4.x. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

    • When test formatting settings are changed, the Test Review feature may incorrectly remove the @ManagedByDiffblue annotation from tests, particularly in cases involving static import formatting changes. [Ref: TG-23750]

    File
    and
    Path
    objects by not relying on environment-dependent assertions. [Ref: TG-21590]
  • Cover now more effectively selects optimal assertions when writing tests for getters and setters. [Ref: TG-21589]

  • CLI & Reports: Cover's --location and --project-name options now accept all characters except \, /, ;, and %, which will be automatically removed during upload if present. [Ref: TG-21418]

  • Plugin: Cover now provides a button, in the Diffblue Cover tool window, to easily open user logs, support logs and the log folder. [Ref: TG-21248]

  • Cover now supports writing tests for Java 22 projects. [Ref: TG-21140]

  • Cover now writes tests which provide an input to SimpleDateFormat, resulting in more consistent and portable date formatting. [Ref: TG-20800]

  • Cover now instantiates CharSequence, StringBuffer, StringBuilder, and ByteBuffer objects using a String where applicable, resulting in stronger assertions and improved line coverage when writing tests for some methods. [Ref: TG-20796]

  • Cover now writes tests which use existing implementations of BiFunction and BiPredicate functional interfaces when appropriate. [Ref: TG-20686]

  • Resolved Issues

    • Resolved an issue which caused Cover to report a custom validation command failure when running dcover validate within an IntelliJ IDEA terminal. [Ref: TG-21522]

    • Plugin: Resolved an issue where, in certain circumstances, writing Java tests for Kotlin code caused Cover to create non-compiling tests. [Ref: TG-20759]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • In rare circumstances Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    CLI: Cover CLI now provides enhanced remediation advice for E011 - Failed to run a simple example test. [Ref: TG-19852]

  • Cover: Diffblue Cover now provides improved coverage when writing tests which use double/long/float constant comparisons. [Ref: TG-18581]

  • Plugin: Cover Plugin now creates run configurations when writing skeleton tests. [Ref: TG-17083]

  • Resolved Issues

    • Cover: Diffblue Cover now provides improved formatting for Javadoc comments when writing tests. [Ref: TG-20292]

    • Cover: Resolved an issue which caused Diffblue Cover to not write tests for inner classes containing a dollar sign, when executing a run configuration. [Ref: TG-19819]

    • Plugin: Resolved an issue which caused Cover Plugin to hang if a run configuration was executed during project indexing. [Ref: TG-19708]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    Removals
    • IntelliJ IDEA 2023.3: With the introduction of support for IntelliJ IDEA 2024.2, support for IntelliJ IDEA 2023.3 has been removed in this release.

    Enhancements

    • CI: Commit messages made by Cover Pipeline now include the Diffblue Cover version used to write tests. [Ref: TG-21821]

    • Reports: Reports bundles can now be produced and uploaded to Cover Reports using coverage-reports without needing to run test generation via create. Cumulative test counts will be shown on the overview as a 'Number of Diffblue Tests' card. [Ref: TG-21789]

    • CLI: Diffblue Cover Pipeline now supports running in any CI/CD environment using git version control. [Ref: TG-21788]

    • Cover now writes tests with more concise assertions for StringWriter(). [Ref: TG-21715]

    • Cover now writes tests faster, with up to 10x speed improvements for projects which use Apache Flink. [Ref: TG-21656]

    • Cover now has improved method-under-test analysis, resulting in tests being written with more valuable assertions. [Ref: TG-21608]

    • Plugin: Cover now supports IntelliJ IDEA Community Edition 2024.2 and IntelliJ IDEA Ultimate 2024.2. Support for IntelliJ IDEA 2023.3 has been removed. [Ref: TG-21423]

    • Plugin: Cover's tool panel window has been redesigned. When writing tests, Cover will now display visual cards containing the count of tests created, as well as the count of pending methods under test. [Ref: TG-21289]

    Resolved Issues

    • Resolved an issue which, in some circumstances, could cause F009 (Internal Error) to be reported while writing tests where Spring XML configurations are used. [Ref: TG-21813]

    • Resolved an issue which caused Cover to not provide the most useful and informative Spring error message when encountering R026 (Failed to create Spring context). [Ref: TG-21744]

    • Plugin: Resolved an issue which, in some circumstances, could cause Cover to get stuck at the 'Checking environment' phase. [Ref: TG-21604]

    • CLI & Plugin: Resolved an issue which, in some circumstances, caused Cover to report an incorrect output code and remediation advice, when using an unsupported version of JUnit [Ref: TG-21564]

    • CLI: Resolved an issue where Cover did not detect all the projects with identical names from a Gradle multi-project build. Cover now identifies the Gradle sub-projects by their path. This affects the arguments passed to the --exclude-modules. [Ref: TG-21052]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

  • IntelliJ IDEA 2023.3: With the introduction of support for IntelliJ IDEA 2024.2, support for IntelliJ IDEA 2023.3 will be removed in the next release.

  • Enhancements

    • Plugin: Cover now supports IntelliJ IDEA Community Edition 2024.2 and IntelliJ IDEA Ultimate 2024.2. [Ref: TG-21658]

    • Cover now writes more tests in situations where Spring contexts get dirtied. [Ref: TG-21587]

    • Cover now writes tests which do not redundantly assert on toString() when already asserting on .pattern(). [Ref: TG-20806]

    • Cover now writes tests with improved assertions by using toByteArray when writing tests for methods which use ByteArrayOutputStream. [Ref: TG-20805]

    Resolved Issues

    • Plugin: Resolved an issue which caused Cover to not invalidate the environment check cache after changing the JDK at the module or project level. [Ref: TG-21670]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    Reports: Breadcrumbs are no longer truncated, making it clearer to identify the current project. [Ref: TG-21280]

  • Plugin: Cover now caches environment checks to improve test writing performance. [Ref: TG-21234]

  • Resolved Issues

    • Plugin: Resolved an issue where using 'Restart' in the Diffblue tool panel after adding a dependency with 'Fix Issues' at the package level would cause it to hang on the 'Preparing' phase. [Ref: TG-21382]

    • Resolved an issue which, in some circumstances, caused Cover to report an F009 (Internal Error) while writing tests for methods with functional arguments. [Ref: TG-21335]

    • Resolved an issue which, in some circumstances, caused Cover to write non-compiling tests for methods with multiple functional arguments. [Ref: TG-21334]

    • CLI: Resolved an issue which caused Cover to report Unexpected licensing exception when activating with an invalid offline license activation file. [Ref: TG-21329]

    • CLI: Resolved an issue which caused Cover to report L024: Unexpected licensing exception when attempting to activate a license with a activation start date in the future. [Ref: TG-20957]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

    E020 Failed to start up analysis service
    output code now deprecated. [Ref: TG-19700]
  • Plugin: Cover Plugin now has improved support for licensing via proxy servers. [Ref: TG-19676]

  • Cover: Diffblue Cover now supports Spring Boot tests with @MockBean on the TestNG framework. [Ref: TG-19619]

  • Cover: Diffblue Cover now provides improved coverage when using TestNG with JDBC repositories. [Ref: TG-19607]

  • Cover: Diffblue Cover now supports Lombok's @Builder annotation. [Ref: TG-19398]

  • CLI: Cover CLI now shows the total number of lines of source code, and the number of lines of code covered by "manually written" tests during preflight checks for Maven projects. [Ref: TG-18659]

  • Resolved Issues

    • Cover: Resolved an issue where Diffblue Cover could not write tests because it encountered an infinite loop in the method under test. [Ref: TG-19702]

    • Cover: Resolved an issue which caused Diffblue Cover to suggest incompatible JUnit dependencies. [Ref: TG-19659]

    • Plugin: Resolved an issue where tests in Gradle multi-module projects could be written into the wrong module. [Ref: TG-19606]

    • Cover: Resolved an issue where tests were always written in UTF-8 and not the project's configured character encoding. [Ref: TG-19556]

    • CLI & Reports: Resolved an issue which caused Cover CLI to report an internal server error when uploading a reports bundle created using a JaCoCo Plugin version older than 0.8.2. Cover now requires 0.8.2 or above when creating reports bundles. [Ref: TG-19546]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    Plugin: Cover now supports writing tests for methods which return an enum or have an enum as an input parameter. [Ref: TG-21103]
  • CLI & Plugin: Cover now writes tests for methods that access classes in other Java modules. [Ref: TG-21083]

  • Plugin: Cover now supports IntelliJ IDEA Community Edition 2024.1 and IntelliJ IDEA Ultimate 2024.1. [Ref: TG-20972]

  • Reports: Cover Reports now allows 'Coverage Over Time' to be viewed by 'Lines of Code' or 'Percentage'. [Ref: TG-20749]

  • Reports: Cover Reports now allows selection of different time periods for telemetry graphs. [Ref: TG-20695]

  • CLI: Cover now provides a 'Run Summary' at the end of execution, showing statuses for each invoked subcommand, such as build, clean, and create, with detailed results for each module in multi-module projects. [Ref: TG-20502]

  • CLI: Cover now supports wildcard and Java-like syntax for including or excluding classes to write tests for when using dcover create and dcover create --exclude. [Ref: TG-18037]

  • Resolved Issues

    • CLI & Plugin: Resolved an issue which caused Cover to write tests with unused getter calls. [Ref: TG-21139]

    • CLI: Resolved an issue which caused Cover to not warn, during preflight, about incompatibility between Spring Core and javax.servlet when using javax.servlet 2.3, 2.4 or 2.5. [Ref: TG-21131]

    • CLI: Resolved an issue which caused Cover to report Failed to find git executable while using dcover upload without git available on the path. [Ref: TG-21101]

    • Plugin: Resolved an issue which, in some circumstances, caused Cover to report Diffblue Cover was unable to start its analysis service [...] while identifying Spring XML configuration files. [Ref: TG-21097]

    • Reports: Resolved an issue which caused Cover Reports to show Unexpected Application Error if all projects are removed. [Ref: TG-21075]

    • Reports: Resolved a cosmetic issue which could cause table header sorting indicators to not represent the current sorting order. [Ref: TG-21056]

    • Reports: Resolved a cosmetic issue which caused table headers to become misaligned after using the sorting options. [Ref: TG-21055]

    • CLI: Resolved an issue which, in some circumstances, prevented preflight from providing a list of existing non-Diffblue tests which failed to run. [Ref: TG-19884]

    • Plugin: Resolved an issue which, in some circumstances, caused tests to be written with incorrect formatting. All tests written by Cover now match the project's formatting rules. [Ref: TG-18153]

    Known Issues

    • Plugin: Cover Plugin incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Diffblue Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • CLI & Plugin: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • CLI & Plugin: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

    CLI & Reports: Report bundles can now be uploaded using the new --upload option from Cover CLI. Note that the --report option will be deprecated in a future release. [Ref: TG-20124]
  • Cover: Diffblue Cover now attempts to write tests for non-LTS and LTS Java versions (18, 19, 20, 21) if strict mode is not used. [Ref: TG-20049]

  • Plugin: Cover Plugin now provides an improved experience when writing tests for Java 17 Records. [Ref: TG-19891]

  • Cover: Diffblue Cover no longer warns about junit-vintage unless the --coverage-reports option is used. [Ref: TG-19770]

  • Resolved Issues

    • Reports: By default, Cover Reports will now be installed to a folder with no release number. Future upgrades will therefore overwrite the current install. [Ref: TG-20235]

    • CLI: Resolved an issue where in some circumstances running dcover clean may result in a NullPointerException. [Ref: TG-20174]

    • CLI: Resolved an issue where if --maven and --gradle are supplied at the same time, Cover CLI would display an incorrect error message. Cover now reports a clear message which states that these options are mutually exclusive, and to specify only one. [Ref: TG-20082]

    • Plugin: Resolved an issue where Cover Plugin could write tests for methods outside of the selection for multi-module projects. [Ref: TG-19744]

    • Plugin: Resolved an issue where in certain circumstances test links in Cover Plugin would not work correctly. [Ref: TG-18908]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    Changes to test code
    • Test Method Ordering: In an upcoming release, Cover will adjust test method ordering and imports for inner classes. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code.

    Diffblue Cover is now generally available to individual developers and small teams.

    We've just launched our Developer Edition license. From today, individual developers can leverage the power of AI they can trust for unit test generation and maintenance.

    Enhancements

    • Plugin: Cover now provides a status bar widget which, when clicked, displays an overview of current license consumption and details. [Ref: TG-22127]

    Resolved Issues

    • Resolved an issue which, in some circustances, caused Cover to incorrectly insert // Assert that nothing has changed comments into tests. [Ref: TG-22437]

    • Plugin: Resolved an issue which could, in certain circumstances, display an error after clicking "Fix issue" for a small heap size in the Environment Checks window. [Ref: TG-22400]

    • CLI & Reports: Resolved an issue which caused cumulativeDiffblueTestCount and cumulativeManualTestCount to be incorrectly counted for TestNG projects. [Ref: TG-22333]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    argument matchers as part of verify statements, replacing the use of
    any
    . This does not affect argument matchers for primitives, Strings and enums which use
    eq
    . [Ref: TG-20821]
  • Reports: Cover Reports now provides a project coverage summary table on the Overview tab. [Ref: TG-20694]

  • Cover: Diffblue Cover now writes tests for methods which use a Kafka Consumer by using a MockConsumer. [Ref: TG-20637]

  • Cover: Diffblue Cover now writes tests which use Project Reactor's StepVerifier for methods that return Mono and Flux sequences. [Ref: TG-20270]

  • Reports: Cover Reports now provides a list of recently viewed projects in the main navigation menu. [Ref: TG-19630]

  • Resolved Issues

    • Reports: Resolved an issue, in the administrator view, which prevented moving a project group to the root of the hierarchy. [Ref: TG-21015]

    • Plugin: Resolved a cosmetic issue which caused a scroll bar to appear on the 'Community Edition license created' screen when IntelliJ's zoom was set higher than 100%. [Ref: TG-20942]

    Known Issues

    • Plugin: Cover Plugin incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover: Diffblue Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

    • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

    Cover no longer writes redundant tests which only differ by mocking. [Ref: TG-21634]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to report Built when running dcover build even if the build failed. [Ref: TG-22202]

    • Resolved an issue which caused Cover to write tests, which require a Jackson ObjectMapper, using a new ObjectMapper() which has no optional modules configured. Cover now discovers existing instances or configures one with all available modules. [Ref: TG-22150]

    • CLI: Resolved an issue which, in some circumstances, caused Cover to report Unresolved compilation problem. [Ref: TG-22141]

    • Plugin: Resolved an issue which caused IntelliJ to report an error after clicking 'Accept All' in the test review panel while writing tests. [Ref: TG-21938]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    pricing page
  • Cover now offers the ability to write tests with Given-When-Then-style names via Descriptive Test Naming (beta). Descriptive Test Naming (beta) can be enabled in the Diffblue IntelliJ Plugin Settings or by passing --descriptive-test-names to Cover CLI. [Ref: TG-21872]

  • Cover now supports full customization of build system commands. This allows Cover to write tests for projects with more complex build structures or requirements. Cover can be configured via a DiffblueBuild.yaml file. [Ref: TG-21551]

  • Resolved Issues

    • Plugin: Resolved an issue which, in some circumstances, caused test writing to be delayed during the preparation phase. [Ref: TG-21903]

    • Cover + Reports: Resolved an issue which, in some circumstances with mismatched versions, caused large quantities of log messages to appear in log files. [Ref: TG-21752]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    IntelliJ Plugin documentation
    Cover CLI documentation

    CLI: Cover now provides improved remediation advice when encountering E022 (Diffblue Cover was not able to discover the path to the JUnit Jupiter Launcher). [Ref: TG-21637]

  • Cover now writes tests that assert on the contents of Properties objects. [Ref: TG-20888]

  • Resolved Issues

    • Resolved an issue which, in some circumstances, prevented tests being written for methods which take Class objects with nested generics. [Ref: TG-21847]

    • Resolved an issue which, in some circumstances, caused tests written for Thread extension classes to be removed during verification. [Ref: TG-21584]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    documentation
    Mockito versions

    In this release, we have standardized the Mockito versions supported by Diffblue Cover. This, and other useful information, is shown in our Datasheet:

    | Java Version | Supported Mockito Versions |

    | --- | --- |

    | 17 | 4.1.0 - 4.7.0 |

    | 11 | 2.22.0 - 4.7.0 |

    | 8 | 1.9.5 - 4.7.0 |

    ​​​​​

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    2025-04-02

    2025-04-02

    This release focuses on enhanced test generation for Spring Data JPA, improved object instantiation during test creation, and fixes to test addition & processing.

    • Test Generation & Support: Test generation now supports Spring Data JPA repository interfaces utilizing composite primary keys (via @IdClass and @EmbeddedId annotations).

    • Object Instantiation: Factory methods found in the test classpath are prioritized during object instantiation, leading to more accurate and reliable tests.

    • Resolved Issues: An issue where existing tests were incorrectly removed during additions has been resolved (affecting static method access with different Mockito styles). Processing efficiency is improved by avoiding unnecessary testing of auto-generated code from Protobuf, gRPC, and Lombok.

    • Compatibility: JUnit Jupiter 5.12.1 is now supported.

    Important Notices

    Deprecations

    • IntelliJ IDEA 2024.2: Cover 2025.04.02 is the final release supporting IntelliJ IDEA 2024.2. Subsequent Cover releases (starting from version 2025.05.01) will require IntelliJ IDEA 2024.3 or 2025.1.

    Enhancements

    • CLI & Plugin: Cover now recognizes composite keys in repository code, supporting both @IdClass and @EmbeddedId annotations. This enables test generation for Spring Data JPA repository interfaces utilizing composite primary keys. [Ref: TG-22983]

    • CLI & Plugin: Diffblue Cover now provides improved support for java.util.Map methods like putIfAbsent, putAll, and compute. This enables the generation of more tests for methods utilizing these specific map operations. [Ref: TG-22856]

    Resolved Issues

    • CLI & Plugin: Resolved an issue where Cover may incorrectly remove existing tests when adding new ones. This occurred when tests accessed static methods using different Mockito import styles. [Ref: TG-22693]

    • CLI & Plugin: Resolved an issue where Cover would unnecessarily attempt to test auto-generated code written by Protobuf, gRPC, and Lombok. This prevents unnecessary processing and improves the efficiency of test generation. [Ref: TG-22388]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2024-05-02

    This release provides enhancements that can increase the number of tests written via the CLI. Test writing has been improved for projects using Quarkus. Support for projects using Gradle 8.6.x and 8.7.x has been added. Additionally, the Cover CLI and Plugin have received usability, performance, and test writing bug fixes, detailed in the full release notes.

    Enhancements

    • Cover now issues a warning when libraries with limited support are identified on the classpath. [Ref: TG-21311]

    • Cover now supports Gradle 8.6.x and 8.7.x. [Ref: TG-21307]

    • Plugin: Cover now provides a sidebar action to restart test creation via the Diffblue Tool Panel. [Ref: TG-21249]

    • Plugin: Improved test writing performance. [Ref: TG-21237]

    • Cover now detects the Quarkus framework and attempts to write tests for code which uses it. [Ref: TG-21171]

    • Cover now writes tests which use inputs from the static final fields found in code under test. [Ref: TG-20643]

    • Cover now, in some circumstances, produces more tests by removing only the failing tests during validation, rather than removing the entire test class. [Ref: TG-19071]

    Resolved Issues

    • Resolved an issue which caused Cover to not write tests if spring-web-test and spring-boot were on the classpath but spring-boot-test was not. [Ref: TG-21215]

    • CLI & Reports: Resolved an issue which caused Cover to produce reports with zero coverage because the --class-name-template option was not available with the coverage-reports command. [Ref: TG-21214]

    Known Issues

    • Plugin: After adding a dependency with 'Fix Issues' at the package level, using 'Restart' in the Diffblue tool panel can cause it to hang on the 'Preparing' phase. Use run configurations to restart test creation for the package. [Ref: TG-21382]

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    2025-05-02

    2025-05-02

    This release enhances test generation for Spring controllers and Strings with validation annotations, introduces a new CLI test management command, and resolves issues with JUnit 5 test retention and Gradle coverage reporting.

    • Test Generation & Quality:

      • More precise mock parameters for Spring controller tests, improving coverage and Spring-specific scenarios.

      • Improved inputs for String types with Java Beans Validation, JPA @Column, or Hibernate @Length annotations, yielding more suitable inputs and tests.

      • Simplified factory method specifications in DiffblueRules.yaml (name and parameters), removing need for verbose descriptors.

      • Fix for JUnit 5 @DisplayName issue; whole test classes no longer discarded on single method failure, improving test retention.

    • CLI Enhancements & User Control:

      • New dcover remove CLI command for project-wide deletion of generated tests.

    • Reports:

      • Fix for dcover coverage-reports showing 0% for Gradle projects with no manual tests; Cover-generated test coverage now correctly shown.

    Important Notices

    Changes to test code

    • Test formatting: In a future release, Cover will switch the default test formatting style to google-java-format. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code. If you prefer a different style, an alternative formatter configured in your build system will override this new default.

    Enhancements

    • CLI: Diffblue Cover now writes tests for Spring controllers by creating mock parameters with greater precision. This results in more comprehensive test coverage and better generation of Spring-specific test scenarios. [Ref: TG-23011]

    • Diffblue Cover now creates tests with improved inputs for Strings governed by Java Beans Validation, JPA's @Column, or Hibernate's @Length annotations. This results in more suitable test inputs, increasing the number of tests produced. [Ref: TG-23010]

    • CLI: Diffblue Cover now enables project-wide deletion of its generated unit tests via the new

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to discard whole JUnit 5 test classes that utilized @DisplayName annotations if any single test method failed. Users now retain more passing tests as validation correctly targets only individual failing tests. [Ref: TG-23156]

    • CLI & Reports: Resolved an issue where dcover coverage-reports would incorrectly show 0% coverage for Gradle projects with no manual tests. Coverage from Diffblue Cover-generated tests is now correctly shown in CLI output and Cover Reports. [Ref: TG-23138]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2023-12-01

    This release includes a number of enhancements to Diffblue Cover’s test writing capabilities, plus updates to Cover Reports dashboards and Cover Plugin actions and settings. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • CLI: Cover CLI now allows a full license quota to be consumed in a single run. [Ref: TG-20476]

    • Cover: General Diffblue Cover test verification improvements which may yield some additional tests for your projects. [Ref: TG-20440]

    • Plugin: Cover Plugin now allows you to specify a test directory location in settings. [Ref: TG-20365]

    • Reports: Items with zero coverage are now hidden by default in the Coverage Over Time graph. [Ref: TG-20355]

    • Reports: Cover Reports now provides the Coverage Over Time graph as a stacked area graph. [Ref: TG-20351]

    • Plugin: Test methods can now be deleted in Cover Plugin using the new Delete gutter icon. [Ref: TG-20288]

    • CLI: Cover CLI now iterates across all modules of a multi-module project on Create, Clean, and Validate commands. [Ref: TG-20101]

    • Cover: Diffblue Cover is now able to automatically call the Java Spring Formatter when writing tests for Gradle. [Ref: TG-13002]

    Resolved Issues

    • Cover: Resolved an issue which caused Diffblue Cover to not write tests for projects which were incorrectly identified as Android projects. [Ref: TG-20491]

    • CLI: Resolved an issue which caused Cover CLI to return a non-zero exit code when encountering E032 during test validation. [Ref: TG-20360]

    • Cover: Diffblue Cover now places assertions about the size of collections and maps, before assertions that check content. [Ref: TG-20258]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2024-11-02

    2024-11-02

    In this release, Cover has been optimized to improve test quality by reducing the number of assertions written while maintaining test coverage. This results in cleaner, more maintainable, and more readable tests. It also resolves various issues with the CLI, Plugins and Reports. Full details of these updates can be found in the release notes below.

    Important Notices

    Deprecations

    • IntelliJ IDEA 2024.1: Cover 2024.11.02 is the last release that supports IntelliJ IDEA 2024.1. Starting with Cover 2024.12.01, only IntelliJ IDEA 2024.2 and 2024.3 will be supported.

    Diffblue Cover is now generally available to individual developers and small teams.

    We've our Developer Edition license. From today, individual developers can leverage the power of AI they can trust for unit test generation and maintenance.

    Enhancements

    • Cover now supports Mockito 5.14.2. [Ref: TG-22159]

    • Cover is now more selective in the assertions it writes in tests and tries to avoid writing more than 10 assertions per test. [Ref: TG-22147]

    • Reports: Cover now provides extra information via ⓘ icons to explain what code is counted towards quota usage. [Ref: TG-22146]

    • Reports: Cover now allows the Cover Reports server URL to be specified via an environment variable DIFFBLUE_COVER_REPORTS_UPLOAD_URL

    Resolved Issues

    • Resolved an issue which, in some circumstances, could cause Cover to fail to write tests because of wildcards in collection types. [Ref: TG-22161]

    • Reports: Resolved an issue which could cause quota usage to be incorrectly reported when running dcover coverage-reports followed by dcover upload. [Ref: TG-22099]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    2024-02-01

    In this release, Diffblue Cover now supports writing tests for methods which use Kafka, and Cover Reports continues to receive enhancements, now allowing you to view total coverage across all of your projects. Also of note, Cover Plugin Community Edition now requires product verification (via a simple email registration) – you’ll be prompted in IntelliJ on install/upgrade. See the full Release Notes below for details of all enhancements and resolved issues covered by this release. One final note, looking forward to the next release (2024.02.02), the syntax for the --mock, --mock-static, --mock-construction, and --exclude arguments in Cover CLI will be changing (multiple values must be provided as a comma separated list) – as well as changing how you use these options on the command line, you may also need to consider potential changes to your argument files, scripts, pipelines, etc. For example: Previous format: dcover create --mock com.diffblue.Foo com.diffblue.Bar New format: dcover create --mock=com.diffblue.Foo,com.diffblue.Bar

    Enhancements

    • CLI: The capabilities of the --mock-static option in Cover CLI have been enhanced, including support for Spring Controllers. [Ref: TG-20723]

    • Plugin: To prevent accidental deletion of test classes in IntelliJ, the Delete Tests gutter icon has been removed (for test classes). [Ref: TG-20691]

    • Cover: Diffblue Cover now supports writing tests for methods which use a Kafka Producer. [Ref: TG-20638]

    Resolved Issues

    • Cover: Resolved an issue which under some circumstances caused Diffblue Cover to write tests with unnecessary casts. [Ref: TG-20720]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Diffblue Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2023-02-01

    Important Java support notice

    Diffblue Cover supports the latest Critical Patch Updates for Java 8, 11 & 17. It has come to our attention that Java 8 versions prior to and including Java 8 Update 271 cause unexpected behaviour in the Diffblue Cover IntelliJ plugin. Please ensure that you are using the latest update for Java 8, 11 or 17.

    Cover is now more likely to populate collections and arrays with unique objects

    Where Diffblue Cover previously wrote tests with the same object parameters; now unique objects are more likely to be created such that the tests appear more realistic and are able to catch a wider range of regressions.

    Enhancements

    • Cover is now more likely to populate collections and arrays with unique objects. [Ref: TG-18523]

    • CLI: Mitigated an issue where output codes R024 and R025 were seen on projects with large classpaths. [Ref: TG-18412]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to fail to detect and write tests for projects using Gradle 7.6. [Ref: TG-18548]

    • CLI: Resolved an issue which caused Cover to provide redundant recommendations when running from a parent module without classes. Now only E005 (Parent module without classes) and remediation advice is provided. [Ref: TG-18520]

    • Reports: Resolved an issue which, in some circumstances, would cause uploading of a run to fail. [Ref: TG-18438]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading the Coverage Reports tab. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2023-07-03

    This release adds support for IntelliJ IDEA 2023.2, Spring Core 6, Spring Boot 3, Java 17 Records and relaxes restrictions when sandboxing is disabled. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Getting more tests by configuring Diffblue Sandboxing

    Diffblue Cover writes human-like unit tests by running your code thousands of times as it searches for the best tests that achieve maximum coverage and regression detection. By default, your code is run inside a sandbox which blocks calls with potentially disruptive side-effects such as network, file system or system changes. However, this can also limit the number of tests Diffblue can write. Disabling the sandbox will allow Cover to run all of your code regardless of side-effects thus maximising coverage. Disabling sandboxing must be done with caution as your code may behave in ways you do not expect (e.g. file system modifications). In this release the disable sandboxing option has been extended. If you want to disable sandboxing, we suggest you read .

    Enhancements

    • Cover: Diffblue Cover Refactor now only applies code styling to the methods added by Cover. [Ref: TG-19572]

    • Cover: Diffblue Cover now supports TestNG with Mockito >= 2.7.0. [Ref: TG-19525]

    • Cover: Disabling Diffblue Cover's sandboxing is now more permissive, allowing tests to be written using sun.misc.Unsafe (and sun.misc.*), JMX (Java Management Extensions) and writing to arbitrary files. [Ref: TG-19476]

    Resolved Issues

    • Cover: Resolved an issue which caused Cover to report Command could not be completed due to an unexpected error: java.lang.AssertionError: expected value for fact SELECTED_BUILD_SYSTEM. while using an unsupported Java version. [Ref: TG-19623]

    • Reports: Resolved an issue which caused Cover to, in some circumstances, misreport method information in classes that extend or implement generic types. [Ref: TG-19539]

    • Plugin: Resolved an issue which caused Cover to not provide a meaningful error message when a time-limited build has expired. [Ref: TG-19516]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration [Ref: TG-18282]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2024-03-01

    This release deprecates the --project option for Cover CLI (reports bundles uploads). Cover Reports 'Coverage Over Time' graphs have been enhanced, including providing coverage details for project groups. Additionally, Cover's Spring Reactive Controller test writing performance has been improved. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • CLI & Reports: The Cover CLI --project option has been deprecated. Project names for Cover Reports are now automatically calculated based on the project configuration. [Ref: TG-21010]

    • Cover: Improved performance of Spring Reactive Controller test writing. [Ref: TG-20911]

    • Reports: The Coverage Over Time graph in Cover Reports now provides a timeframe selector. [Ref: TG-20772]

    • CLI: Cover CLI now supports writing tests for an entire multi-module project, without the need to create tests for each module separately. [Ref: TG-20709]

    • Reports: Coverage Over Time graphs are now available for project groups from the Cover Reports Home page. [Ref: TG-20649]

    • Cover: Diffblue Cover now provides partial Spring tests if Cover fails to write a complete Spring test. [Ref: TG-19589]

    • Pipeline: Cover Pipeline now creates and updates .gitignore files within .diffblue directories so that git ignores the contents. [Ref: TG-12872]

    Resolved Issues

    • Cover: Improvement for Cover upload command - Automatic detection of parent project name within modules [Ref: TG-21014]

    • Cover: Resolved an issue which caused Cover to attempt to mock inaccessible protected and package-private constructors or methods. [Ref: TG-20969]

    • Cover: Resolved an issue which under some circumstances caused Cover to encounter an internal error related to byte arrays. [Ref: TG-20968]

    • Cover: Resolved an issue which under some circumstances caused Cover to assign values to final fields in unit tests. [Ref: TG-19786]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Diffblue Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2024-12-01

    2024-12-01

    This release introduces support for IntelliJ IDEA 2024.3 and removes support for 2024.1. It also resolves various issues with the CLI, Plugin and Reports.

    Important Notices

    Deprecations

    • IntelliJ IDEA 2024.1: Support for IntelliJ IDEA 2024.1 ended with Cover 2024.11.02. Starting with Cover 2024.12.01, only IntelliJ IDEA versions 2024.2 and 2024.3 are supported.

    Changes to test code

    • Test Method Ordering: In an upcoming release, Cover will adjust test method ordering and imports for inner classes. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code.

    Diffblue Cover is now generally available to individual developers and small teams.

    We've our Developer Edition license. From today, individual developers can leverage the power of AI they can trust for unit test generation and maintenance.

    Enhancements

    • Refactor: Diffblue Cover is now able to automatically fix issues with Surefire plugin configuration [Ref: TG-22370]

    • Cover now supports Gradle 8.11.x. [Ref: TG-22305]

    • Plugin: Cover now displays a progress dialog after clicking 'Accept All' when the Test Review beta feature is enabled, showing the progress of inserting tests into the codebase. [Ref: TG-22244]

    • Plugin: Cover now supports IntelliJ IDEA Community Edition 2024.3 and IntelliJ IDEA Ultimate 2024.3. [Ref: TG-21975]

    Resolved Issues

    • Reports: Resolved an issue which caused performance problems, for some deployments, while loading Telemetry graphs. Graphs are now split across tabs to improve page load times. [Ref: TG-22414]

    • CLI: Resolved an issue which, in some circumstances, could cause dcover fix-build or dcover refactor to report FAILURE: Build failed with an exception. on a Gradle project. [Ref: TG-22374]

    • CLI: Resolved an issue which caused Cover to report Recipe validation error in [...]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2023-08-02

    This release adds a new “strict” option (forces the strict definition of all project environment options set by you) and also adds support for Spring Core 6.0.11 and Spring Boot 3.1.2, as well as support for TestNG on Spring 5 projects. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: Resolved an issue which caused Diffblue Cover to fail under a Turkish locale. [Ref: TG-19865]

    • Reports: General UI layout of the Coverage Details page has been improved. [Ref: TG-19811]

    • Cover: Diffblue Cover now supports Spring Core 6.0.11 and Spring Boot 3.1.2. [Ref: TG-19777]

    • CLI: A new --strict option has been added to Cover CLI (dcover create --strict). This forces the strict definition of all project environment options set by you - Cover will not attempt to make an automated selection. [Ref: TG-19769]

    • Cover: Diffblue Cover will now automatically select a test framework if more than one are defined in your project (unless --testing-framework or --strict are used). [Ref: TG-19490]

    • Cover: Diffblue Cover now supports TestNG on Spring 5 projects. [Ref: TG-19473]

    Resolved Issues

    • Plugin: Resolved an issue which caused Cover Plugin to reset the Sandboxing setting to "Enabled" after restarting IntelliJ. [Ref: TG-19880]

    • Reports: Improved the reliability of uploading reports. [Ref: TG-19864]

    • Cover: Resolved an issue which caused Cover to report F009 while creating objects that have public non-static non-final fields. [Ref: TG-19827]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    2024-06-02

    This release includes enhancements and fixes across Cover CLI, CI, Plugin, and Reports. The Plugin now ensures that sufficient JVM heap memory is configured for optimal test writing performance. Cover Reports has received performance enhancements to reduce load times on the Coverage Details tab. CI users can now provide offline license files through an environment variable. Full details of these updates can be found in the release notes.

    Please note that support for JUnit versions 4.7 through 4.10 is now deprecated. Cover will provide a warning and recommend upgrading your JUnit version if these versions are used for writing tests. The ability to write tests using JUnit 4.7 through 4.10 will be removed in a future release.

    Enhancements

    • CI & CLI: Cover is now able to accept an offline license file in CI environments via the new DIFFBLUE_OFFLINE_LICENSE_ACTIVATION_FILE_CONTENTS environment variable. [Ref: TG-21469]

    • Plugin: Cover's Environment Checks now ensure that IntelliJ is configured with sufficient JVM heap memory for writing tests. A 'Fix Issue' button is provided to easily update the heap memory size to the recommended value. [Ref: TG-21435]

    • Cover now displays an 'unsupported version' warning if JUnit 4.7-4.10 is in use and provides a recommendation to upgrade to a more recent version of JUnit 4. Future releases will require a more recent version of JUnit 4 (or 5) to write tests. [Ref: TG-21432]

    • Reports: The Coverage Details tab now loads faster. Additionally, the Coverage Details tab is also no longer accessible from Project Groups. [Ref: TG-21390]

    Resolved Issues

    • Resolved an issue which caused Cover to write exception tests for trivial exceptions such as ArithmeticException or NegativeArrayIndexException. [Ref: TG-21502]

    • Resolved an issue which, in some circumstances, caused Cover to write tests with redundant chains of getters in the assert section. [Ref: TG-21245]

    • Resolved an issue which, in some circumstances, caused Cover to write assertions which compare the result of an observer to a corresponding field. [Ref: TG-21244]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2022-08-03

    IntelliJ plugin: disabling the sandboxing policy

    By default, Cover runs with the Java sandbox turned on because we do not want to cause any undesired behavior on the system environment with such scenarios as: removing files on disk, initiating network traffic or making live database calls. Furthermore, these operations can also cause non-deterministic behavior. We attempt to mock out this I/O, but there are situations where we can’t and in these situations we may not produce a test.

    Turning off the sandbox when you are running in a safe environment could allow Cover to get more coverage for this code, thus allowing you to look at refining mocking controls and other behavior. Please use this option with caution! There is now a new option in the IntelliJ plugin to disable sandboxing. By default it is enabled, as is shown below:

    {: width="550" height="170"} More information is available in our docs:

    CLI: additional dependency recommendation

    Cover CLI has added an extra dependency recommendation when the specified test framework is not on the classpath. This ensures you receive more tests and greater coverage! {: width="250" height="108"}

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • CLI: Cover now recommends a specific dependency when the specified test framework is not on the classpath. [Ref: TG-17656]

    • CLI: Cover now skips build system detection when there is no build configuration file. [Ref: TG-17655]

    • IntelliJ Plugin: Cover's sandbox environment is now configurable via the plugin settings. [Ref: TG-17586]

    Resolved Issues

    • IntelliJ Plugin: Resolved an issue where tests using assertThrows or assertDoesNotThrow (and JUnit 4 equivalents) were not de-duplicated. [Ref: TG-17607]

    • IntelliJ Plugin: Resolved an issue which, in some circumstances, could cause Cover to hang whilst attempting to write tests for an invalid module. [Ref: TG-17582]

    • IntelliJ Plugin: Resolved some cosmetic inconsistencies in the plugin settings. [Ref: TG-17431]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from root module with --working-directory. [Ref: TG-16876]

    2025-04-01

    This release of Diffblue Cover focuses on enhancing test generation for modern Java frameworks, improving command-line interface (CLI) efficiency and configuration options, and increasing plugin usability.

    • Framework Support & Test Generation: Added test generation for Guice AbstractModules and uses @MockitoBean for spring-test 6.2.0 or newer. New fields are now inserted alphabetically.

    • CLI Efficiency & Configuration: The CLI now supports targeted restarts via --resume-from-module and allows constant field values (e.g., enums) in DiffblueRules.yml.

    • Plugin Usability: Resolved an issue causing potential loss of edits during Test Review in the Plugin.

    Enhancements

    • CLI & Plugin: When writing Spring Boot tests, Diffblue Cover now defaults to @MockitoBean if spring-test version 6.2.0 or newer is detected in the project. [Ref: TG-22890]

    • CLI: Diffblue Cover now supports targeted restarts with the --resume-from-module option. This allows for more efficient test generation by starting from a specific module. [Ref: TG-22889]

    • Plugin: Resolved an issue where Diffblue Cover’s Test Review feature could lose edits. This ensures that changes made to tests are maintained throughout the review process for a given method. [Ref: TG-22844]

    Resolved Issues

    • CLI & Plugin: Resolved an issue which caused Diffblue Cover to write assertions for Mockito generated classes. This prevents compilation errors and test removal. [Ref: TG-22884]

    • CLI: Resolved an issue where Cover generated duplicate and non-descriptive tests for Jersey 2 code. The fix restores the generation of informative test names and Javadoc comments, enhancing test understanding and debugging. [Ref: TG-22878]

    • CLI: Resolved an incorrect recommendation for Cover Annotations on Gradle projects. Cover now recommends compileOnly AND testImplementation for the correct dependency configuration. [Ref: TG-22877]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2025-01-02

    2025-01-02

    This release improves the Plugin's Test Review functionality, adds a MaintainedByDiffblue annotation for tests written by Cover and provides improved guidance to help avoid Spring context initialization failures. It also resolves various issues with the CLI and Plugin.

    Important Notices

    Changes to test code

    • Test Method Ordering: In this release, Cover adjusts test method ordering and imports for inner classes. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code.

    • Test Method Tagging: In this release, tests created by Cover will be annotated with a MaintainedByDiffblue label. This will cause a one-time churn when recreating tests, resulting in larger-than-usual diffs in your test code. This will enable Cover to combine Diffblue tests and manually written tests into the same test classes in a future release.

    Diffblue Cover is now generally available to individual developers and small teams.

    We've our Developer Edition license. From today, individual developers can leverage the power of AI they can trust for unit test generation and maintenance.

    Enhancements

    • Cover now shows a warning if PowerMock is detected in the project under test, as Cover currently has limited support for it. [Ref: TG-22527]

    • Cover now provides guidance around classes to mock statically, with a DiffblueBase class, to help avoid Spring context initialization failures. [Ref: TG-22342]

    • Cover now writes tests with a MaintainedByDiffblue annotation if the cover-annotations library is available. [Ref: TG-21448]

    Resolved Issues

    • CLI: Resolved an issue which, in some circumstances, caused Cover to show F009: Internal error while running dcover create --preflight. [Ref: TG-22438]

    • Plugin: Resolved an issue in Test Review which, in some circumstances, could cause Cover to report an incorrect number of tests to be reviewed for a class. [Ref: TG-22081]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2022-11-01

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • Cover now uses static mocking when the method under test creates temporary files without deleting them. [Ref: TG-17368]

    Resolved Issues

    • Resolved an issue which caused Cover to produce spurious warnings about inconsistent JDK 8 and Spring Core/Spring Boot versions. [Ref: TG-18055]

    • Resolved an issue which caused Cover to report Error: unknown, rather than citing the cause of the problem, while writing tests. [Ref: TG-17692]

    2023-09-01

    This release adds support for Spring 6 with TestNG and includes a code signing certificate update. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • CLI: Cover CLI now includes an option to exclude very large class files (--max-class-length). This can be useful where third party code conversion tools have generated large class files which are not idiomatic of developer written code. [Ref: TG-19923]

    • Cover: Diffblue Cover now writes assertions for arrays mutated by System.arraycopy. [Ref: TG-19844]

    • CLI: Multiple telemetry endpoints can now be configured for Cover CLI, including your own Mixpanel instance. [Ref: TG-19703]

    • Cover: Diffblue Cover now supports Spring 6 with TestNG. [Ref: TG-19587]

    Resolved Issues

    • Updated code signing certificate to remove expired parent certificate in chain. As the chain of trust has changed you may need to revalidate the authenticity of Diffblue Cover. [Ref: TG-19996]

    • Cover: Resolved an issue which caused Diffblue Cover to halt with "unexpected error: null" when using the --patch-only option with corrupt class files in the classpath. [Ref: TG-19970]

    • Plugin: Resolved an issue which, in some circumstances, caused Cover Plugin for IntelliJ to fail to write tests and log PatchFailedException: Patch engine could not apply delta [Ref: TG-19905]

    Known Issues

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    2023-10-02

    This release provides a simplified, Docker-free, Cover Reports installation, including a Windows installer. Diffblue Cover will now write assertions for tests in a more consistent and predictable order - this may lead to notable test code changes due to new assertion ordering. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Reports: Cover Reports UI enhancement. Method coverage will now be displayed when only one class is selected (Coverage Details tab). [Ref: TG-19841]

    • Reports: Cover Reports can now be installed via the Windows Installer. [Ref: TG-19643]

    • Cover: Diffblue Cover now writes tests for methods that have Java Stream as input argument or as return value. [Ref: TG-19570]

    • Reports: Cover Reports can now be installed from a zip archive and removes the need for Docker. [Ref: TG-19465]

    Resolved Issues

    • Plugin: Resolved an issue which caused Cover Plugin to continue writing skeleton tests after the Stop button was clicked. [Ref: TG-20149]

    • Cover: Resolved an issue which caused Diffblue Cover to report an F004 output code due to the presence of non-UTF-8 characters. [Ref: TG-20107]

    • Reports: Resolved an issue which slowed the initial Cover Reports bundle upload. [Ref: TG-20077]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2025-08-01

    This release provides full support for IntelliJ 2025.2. Performance and stability are also improved. Additionally, test generation is enhanced for greater coverage of collections, code using final classes, and complex validation logic.

    IDE & Framework Support

    • IntelliJ 2025.2 Support: Diffblue Cover is now fully compatible with the IntelliJ 2025.2 platform.

    2025-08-02

    This release introduces enhanced support for custom Spring annotations and improves performance in Spring projects. Test quality is also strengthened with stronger assertions, improved readability, and better handling of builder patterns.


    Spring Framework Support

    • Custom Annotation Detection: Diffblue Cover now detects and handles custom Spring annotations that are defined using Spring meta-annotations. A new environment variable, DIFFBLUE_AUTOWIRED_ALTERNATIVE

    2025-11-01

    This release enhances Spring support with performance improvements and more effective controller tests, expands LLM String Generation (Beta) with selective annotation control, and improves CLI command reliability.


    Spring Framework Support

    • Performance Improvements: Diffblue Cover now provides significant performance improvements for projects with large Spring entities.

    2025-09-02

    This release introduces support for OSGi and experimental support for Java 24 and 25, improves CLI performance for multi-module Maven projects, and enhances test quality by refining disabled class and test annotation handling.


    New Framework & Language Support

    • OSGi Support: Diffblue Cover now generates tests for OSGi code. To enhance test coverage, Cover automatically uses the org.osgi.service.component.annotations

    2025-02-02

    This release of Cover enhances flexibility, security, and reliability with several key improvements:

    • Ant Build System Support: Cover CLI now supports Ant projects. .

    • Excluding Trivial Methods: A new CLI option allows users to exclude trivial methods from test generation.

    • SSO Integration for Cover Reports: Enterprise users can now integrate with existing SSO providers for authentication, eliminating the need for a proxy server. .

    2025-07-02

    This release focuses on improving test quality, command-line interface (CLI) functionality, and overall stability. Key enhancements include cleaner test generation that adheres to coding standards, more robust and configurable CLI options, plus performance and dependency-handling improvements.

    • Enhanced Test Quality & Readability

      • Cleaner Mock Assertions: Generated tests now feature simplified Mockito verify() calls, avoiding redundant eq() matchers to improve readability and prevent SonarQube code smells.

    2025-10-02

    This release introduces the new dcover issues (Beta) command that helps resolve problems that block test generation, and enhances test quality via an optional LLM integration (Beta) for domain-specific string generation. It also improves test coverage for Java servlets and boosts performance for multi-module Maven projects.


    New dcover issues (Beta) Command & LLM Integration (Beta)

    2025-03-01

    This release of Cover focuses on improving test generation and plugin user experience:

    • Improved Enum Handling: Cover now writes tests with better branch coverage when comparing enums by name.

    • Conflict Detection & Remediation: Cover identifies and warns about potential conflicts between PowerMock and Mockito artefacts, offering remediation advice to ensure optimal test generation.

    • Enhanced Test Review: The Test Review feature is enabled by default, allowing for manual acceptance of generated tests before integration into your codebase. Navigating tests for review is simplified with a list of method-under-test.

    2022-06-01

    Diffblue Cover Enhancements

    Skeleton tests are now available in Diffblue Cover IntelliJ plugin! There are two ways of creating skeleton tests:

    • Directly, by selecting Write Skeleton Tests when right-clicking on {: width="21" height="22"} or a method name. Diffblue Cover creates a single skeleton test for the method, and does not analyse your code.

    2022-04-02

    Support for IntelliJ IDEA 2022.1

    Diffblue is delighted to announce that we now support IntelliJ IDEA 2022.1.

    We now support IntelliJ IDEA 2022.1 and IntelliJ IDEA 2021.3 only. Please upgrade from IntelliJ IDEA 2021.2 so you can get the maximum benefit from Diffblue Cover.

    2022-03-02

    IntelliJ Plugin - automatic update to memory settings

    The Diffblue Cover IntelliJ plugin requires 2GB of memory to run effectively. If you do not have enough memory available, Diffblue Cover now automatically adjusts your memory setting. You can undo this change (but please note that your IDE may be unstable without sufficient memory).

    2025-03-02

    This release of Cover focuses on enhanced reporting capabilities, improved test generation logic, and usability enhancements to the plugin and CLI.

    • Reports API: Cover Reports now features a REST API for accessing coverage data, enabling integration with existing tools. See the for more details.

    • Jersey Support: Cover now supports writing tests for code which uses the Jersey RESTful Web Services library, expanding test generation capabilities to a wider range of applications.

    • Test Generation Logic

    2024-04-01

    This release introduces support for Spring WebFlux, a popular framework for reactive programming in Java. Diffblue Cover can now write tests for reactive-stack Spring web projects. Tests are written following Spring's best practices, using WebTestClient, applying the @WebFluxTest annotation to auto-configure the Spring WebFlux infrastructure, and asserting on reactive stream objects (Mono and Flux).

    Enhancements

    2022-05-01

    Enhanced messaging for Diffblue Cover Reports

    Diffblue Cover Reports, our tool providing data visualizations, has been updated to tell you when your report upload has been successful, and provide a link directly to that report. This applies to both uploading an existing report, and to creating and then uploading a new report. Please see for our documentation on using Diffblue Cover Reports.

    2024-07-01

    This release enhances the quality of assertions in unit tests written by Cover, improving both readability and overall test quality. Full details of these updates can be found in the release notes.

    Important Notices

    Upgrade Considerations

    2023-07-01

    This release adds support for Jakarta EE Dependency Injection and enhances baseline test coverage capabilities for Cover Reports. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • CLI & Plugin: Diffblue Cover now supports writing tests for Jakarta EE Dependency Injection for Java EE 8/Jakarta EE 8 and Jakarta EE 9. Note: Diffblue Cover does not use Jakarta EE application context for tests, all injected dependencies will be mocked. [Ref: TG-19392]

    2023-06-02

    This release includes enhancements to error reporting and code styling. See the Release Notes below for details of all product updates and enhancements in this release.

    Enhancements

    • Refactor: Diffblue Cover Refactor now produces patch files that match the code style of the project. [Ref: TG-19215]

    2024-10-02

    This release enhances the quality of assertions in unit tests written by Cover, improving both readability and overall test quality. Descriptive Test Naming is now enabled by default. Full details of these updates can be found in the release notes below.

    Important Notices

    • Descriptive Test Naming: Cover now, by default, writes tests which use descriptive Given-When-Then-style names. For more details on Descriptive Test Naming, please refer to the or the .

    2022-12-02

    IntelliJ IDEA 2022.3 support

    Diffblue Cover now supports IntelliJ IDEA 2022.3 (Community and Ultimate). In keeping with our policy of supporting the current and previous release, Diffblue Cover now supports IntelliJ IDEA 2022.3 and 2022.2. Support for IntelliJ IDEA 2022.1 has been removed as of Diffblue Cover 2022.12.01.

    2022-10-01

    Enhancements to the Diffblue Cover log files

    As previously announced, we now have two types of log files:

    • User log files contain details necessary to understand and remedy common configuration and build issues.

    2024-01-01

    This release provides a range of updates and enhancements. See the full Release Notes below for details.

    Enhancements

    • Reports: Cover Reports will no longer display data for code excluded through a JaCoCo configuration. [Ref: TG-20445]

    2022-07-02

    Update to Diffblue Cover's handing of NullPointerExceptions

    Diffblue Cover now handles NullPointerExceptions despite try / catch blocks.

    (Try blocks contains a set of statements where an exception can occur. A catch block will be used to handle any exceptions that occur as a result of the try

    Cover now supports JUnit Jupiter 5.12.1 [Ref: TG-22750]

  • CLI & Plugin: Cover now prioritizes factory methods found in the test classpath when creating new objects for tests. Factory methods in the main classpath can still be used but have lower priority. [Ref: TG-22214]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • When using Gradle, Junit 5 tests produced with the @DisplayName annotation may cause all the Diffblue tests to be removed from the class in validation [Ref: TG-22784]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

  • Plugin: Resolved an issue which, in some circumstances, caused the IntelliJ IDE to freeze for a short period of time after clicking 'Write Tests'. [Ref: TG-20949]
  • CLI: Resolved an issue which, when calling dcover create --help, caused Cover to display a usage message for dcover, rather than dcover create [Ref: TG-20543]

  • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]
  • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • dcover remove
    command. This function is particularly useful for cleaning up tests after a trial or when changing test file organization. [Ref: TG-22923]
  • Diffblue Cover now uses simplified factory method specifications in DiffblueRules.yaml for guiding test generation, identifying methods by name and parameters. Providing the full, verbose descriptor is no longer necessary, simplifying the configuration. [Ref: TG-22492]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    Plugin: Cover Plugin Community Edition now requires product verification to continue use after the initial trial period. Users will be prompted on install/upgrade. [Ref: TG-20628]
  • Cover: Diffblue Cover license server connection has been improved. [Ref: TG-20616]

  • Cover: Diffblue Cover now uses eq() when creating verify statements for methods with String or primitive arguments. This replaces the use of any(). [Ref: TG-20608]

  • Cover: Diffblue Cover now provides improved test writing capabilities for code involving complicated generics constructions. [Ref: TG-20516]

  • Reports: Cover Reports now provides total coverage statistics across all uploaded projects. [Ref: TG-19090]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]
  • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

  • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]
  • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

  • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • Reports: Resolved an issue which in some circumstances caused Cover Reports to display an incorrect Latest Run. [Ref: TG-19824]
  • Cover: Resolved an issue which in some circumstances caused Cover to report an R008 (Failed to instantiate class under test) output code instead of R081 (Exception in arrange section). [Ref: TG-19815]

  • Cover: Resolved an issue where Cover was not writing assertions for Duration standard library class objects. [Ref: TG-19752]

  • CLI: Resolved an issue that caused preflight checks to recommend unsuitable dependencies for JUnit, Mockito, and Spring Boot test. [Ref: TG-19669]

  • Resolved an issue which, in some circumstances, caused Cover to not write an assertion for trivial methods returning collections. [Ref: TG-20233]

    In rare circumstances Cover may encounter an
    F009: Internal error
    while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]
  • Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • CLI & Plugin: Diffblue Cover now inserts new fields alphabetically by name within generated test classes. Previously, new fields were appended to the end. This improves test class organization. [Ref: TG-22761]

  • CLI: Diffblue Cover now supports constant field values in DiffblueRules.yml. This new "field rule type" allows specifying static final fields, including enum constants, as custom inputs. [Ref: TG-22745]

  • CLI & Plugin: Diffblue Cover now generates unit tests for code that utilizes Guice AbstractModules. This enables test writing for projects employing this specific Guice dependency injection pattern. [Ref: TG-22156]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • When using Gradle, Junit 5 tests produced with the @DisplayName annotation may cause all the Diffblue tests to be removed from the class in validation [Ref: TG-22784]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

  • Plugin: Resolved an issue which, in some circumstances, caused Cover Plugin for IntelliJ to fail to write tests and log Syntax error on token "package", import expected [Ref: TG-19904]

  • Cover: Resolved an issue that previously prevented Diffblue Cover from writing tests for VERY large classes. [Ref: TG-19845]

  • Cover: Resolved an issue which caused Diffblue Cover to exit with an error (E068) rather than generate a warning when classes defined in DiffblueRules.yml could not be found. [Ref: TG-19685]

  • Cover: Resolved an issue which caused Diffblue Cover to not discover all Spring profiles for a project. [Ref: TG-19662]

  • Cover: Diffblue Cover Plugin cannot write tests for methods which use Java 17 Records. [Ref: TG-19937]

    Plugin: Resolved an issue which in some circumstances caused run configurations created by Cover Plugin to "hang" during the preparation phase. [Ref: TG-20061]
  • Reports: Cover Reports will now display a notification banner when no test data is available. [Ref: TG-20035]

  • Cover: Diffblue Cover now provides assertions in a more consistent, predictable order. First use on prior projects where Diffblue Cover was used might lead to notable test code changes due to new assertion ordering. [Ref: TG-19962]

  • Reports: Resolved an issue in Cover Reports where classes in newer runs could still be partially visible when switching to an older run. [Ref: TG-19959]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Plugin: Cover Plugin may display tests links which do not work whilst writing tests. Links in existing tests continue to work. [Ref: TG-20050]

  • Immutables Library: Resolved an issue to ensure that Diffblue Cover now correctly writes tests for methods that use objects from the 'immutables' library.

    Performance & Stability

    • Performance with Threads: Corrected a performance issue by ensuring user-created Java threads and Timers are properly shut down during analysis, preventing resource leaks and improving speed.

    • CLI Memory Checks: The CLI now checks for sufficient JVM heap space and provides a clear warning if memory is insufficient, preventing silent failures.

    • CLI Test Validation: Resolved an issue in Gradle projects using JUnit 5 where test validation could incorrectly remove entire test classes. Validation is now more precise and only removes failing tests as intended.

    Improved Test Generation & Coverage

    • Collection & Map Fields: Test coverage is improved for methods that modify collection and map fields, such as those using add() or put() to populate data structures.

    • Final Classes: Diffblue Cover now writes tests for code that interacts with final classes by automatically generating the necessary mocks.

    • Validation Methods: Test writing for void validation methods has been enhanced. Cover now writes tests for the successful execution path in addition to the existing exception-throwing path.

    Important Notices

    • Removal of IntelliJ 2024.3 Support: Support for the IntelliJ 2024.3 platform has ended. To use Diffblue Cover plugin version 2025.08.01 onwards, users must upgrade their IDE to IntelliJ version 2025.1 or 2025.2.

    • IntelliJ Plugin: Removal of Support for JUnit 5.0-5.2: Following the deprecation in 2025.07.02, support for JUnit 5.0.x, 5.1.x, and 5.2.x has now been removed from the IntelliJ plugin. To ensure compatibility with this release and future versions, projects using these older versions must be upgraded to 5.3.0 or higher. This change does not affect projects using JUnit 4 or TestNG, nor does it impact the Diffblue Cover CLI.

    Forthcoming Changes

    • Improved Test Readability: In an upcoming release, Cover will instantiate data-holding classes (e.g., JPA entities) directly instead of using mocks where possible. While this produces higher quality tests, please be aware that existing tests for affected classes will change, leading to noticeable changes in your test suite upon update.

    Enhancements

    • CLI: To prevent silent failures from low memory, Diffblue Cover now checks for sufficient JVM heap space earlier. Users now receive a clear warning with the required minimum value if memory is insufficient, improving diagnostic feedback. [Ref: TG-23607]

    • Diffblue Cover now generates tests with improved coverage for methods that modify collection and map fields. This enhances test creation for classes that use methods like add() or put() to populate internal data structures. [Ref: TG-23534]

    • Plugin: Diffblue Cover now provides full support for the IntelliJ 2025.2 platform, ensuring compatibility with the latest IDE features. Support for IntelliJ 2024.3 has been discontinued; an upgrade to 2025.1 or 2025.2 is required for plugin use. [Ref: TG-22565] Docs

    • Diffblue Cover now writes tests for code interacting with final classes by generating the necessary mocks, increasing the scope of testable code. [Ref: TG-22046]

    Resolved Issues

    • Resolved an issue where Diffblue Cover would not use the generated builder for classes annotated with @Immutable.Value from the 'immutables' library. Diffblue Cover now correctly writes tests for methods that use Immutable objects. [Ref: TG-23586]

    • Resolved an issue where Diffblue Cover would only write tests for void validation methods that throw exceptions. Diffblue Cover now also writes tests for the successful execution path of these methods, ensuring validation logic is more thoroughly tested. [Ref: TG-23584]

    • CLI: Resolved an issue where Diffblue Cover could exit prematurely or incorrectly remove entire test classes during test validation in Gradle projects using JUnit 5. Validation is now more precise, removing only failing tests as intended. [Ref: TG-23410]

    • Resolved a performance issue during test generation for code that creates Java threads or Timers. Diffblue Cover now correctly shuts down these user-created threads, preventing resource leaks and improving analysis speed. [Ref: TG-23384]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. To avoid this, use an earlier version of Mockito. Downgrading to Mockito 4.x is the recommended workaround. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

    • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

    dependency when it is available in the project.
  • Java 24 & 25 Support: This release provides experimental support for writing tests for applications built with Java 24 and Java 25. Full production support continues for Java versions 8, 11, 17, and 21.

  • Performance & Usability

    • Faster CLI Performance: Test creation using the CLI is now significantly faster for Maven projects, especially multi-module projects. When a prefix entry point is used, Cover now also performs automatic module selection, removing the need for the --include-modules argument.

    • IntelliJ Plugin Fix: Resolved an issue in the IntelliJ Plugin where the 'Update test' gutter icon could fail to start a test update operation.

    Improved Test Quality & Management

    • Disabled Test Class Handling: When merging tests, Diffblue Cover now prevents adding new tests to disabled test classes. This change avoids generating tests that would not run and instead reports an output code (R089) for the affected class.

    • Test Review Annotation: Resolved an issue in the Test Review feature where formatting-only edits caused Diffblue Cover to remove the @ManagedByDiffblue annotation. This ensures that tests remain managed by Cover unless substantive code changes are made.


    Important Notices

    Prerequisite: Project Compilation

    Due to recent build system optimizations, building your project remains an essential prerequisite for running Diffblue Cover. A compiled project is required for Cover to analyze code and generate tests successfully.

    For detailed instructions, see the documentation for building a Maven project and a Gradle project.


    Enhancements

    • CLI: Diffblue Cover now provides significant speed improvements for multi-module projects when a prefix entry point is used. Module selection is now automatic in this scenario, removing the need to specify the --include-modules CLI argument. [Ref: TG-23781]

    • Diffblue Cover no longer adds new tests to disabled test classes when merging tests. Instead, it reports an error (R089) for the affected class. [Ref: TG-23744]

    • CLI: Diffblue Cover now runs significantly faster when creating tests for Maven projects. Users with multi-module projects will see the most noticeable performance improvements when using CLI commands like dcover create. [Ref: TG-23714]

    • Diffblue Cover now supports test generation for OSGi applications and automatically uses the org.osgi.service.component.annotations dependency, when available, to improve test coverage. [Ref: TG-23699]

    • Diffblue Cover now provides experimental test writing support for applications built with Java 24 and Java 25. Full support continues for Java versions 8, 11, 17, and 21. [Ref: TG-22920]

    Resolved Issues

    • Plugin: Resolved an issue in the IntelliJ Plugin where the 'Update test' gutter icon could fail to start a test update operation in certain edge cases. [Ref: TG-23748]

    • Resolved an issue in the Test Review feature where formatting-only edits caused Diffblue Cover to remove the @ManagedByDiffblue annotation. This ensures that tests remain managed by Diffblue Cover unless substantive code changes are made by the user. [Ref: TG-23738]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. The recommended workaround is to downgrade to Mockito 4.x. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

    • When test formatting settings are changed, the Test Review feature may incorrectly remove the @ManagedByDiffblue annotation from tests, particularly in cases involving static import formatting changes. [Ref: TG-23750]

  • IntelliJ IDEA Support Expansion: Cover now supports IntelliJ IDEA Community Edition 2025.1 EAP.

  • Important Notices

    CLI: Deprecation of Build System Customization Options

    As of the 2025.02.02 release, the following CLI options have been marked as deprecated:

    • --build-system-configuration

    • --ignore-stylechecks

    • --jacoco-command-diffblue

    • --jacoco-command-manual

    • --jacoco-xml-test-report

    • --preflight-test-command

    • --preflight-test-timeout

    • --validation-timeout

    • --validation-command

    Migrating to a DiffblueBuild.yaml file is recommended for build system integration. See the configuration guide for more details.

    Enhancements

    • Plugin: Cover now supports IntelliJ IDEA Community Edition 2025.1 and IntelliJ IDEA Ultimate 2025.1 EAP. [Ref: TG-22574]

    • Plugin: Cover now displays a list of test methods in the Test Review panel. This allows for easier navigation through tests requiring review, grouped by method-under-test. The list will not appear if descriptive test names are disabled. [Ref: TG-22376]

    • Reports: Tests tagged with MaintainedByDiffblue, in any test files, now count towards the 'Diffblue coverage' statistic shown in Cover Reports. [Ref: TG-21447]

    • Plugin: Cover's Test Review feature is now enabled by default. Tests must be accepted manually before appearing in your codebase. Test Review can be disabled via the plugin settings dialog. [Ref: TG-21297]

    • CLI & Plugin: Diffblue Cover now writes tests with improved branch coverage for code comparing enums by name. [Ref: TG-20568]

    Resolved Issues

    • Resolved an issue which caused Cover to recommend incorrect cover-annotations dependency scope: it now recommends provided (Maven) or compileOnly (Gradle). [Ref: TG-22749]

    • CLI & Plugin: Cover now provides a warning (E154) and remediation advice if PowerMock and Mockito artefacts conflict. Conflicting artefacts can cause Cover to write fewer tests. [Ref: TG-21209]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover now writes tests using the eq() argument matcher for both boxed primitives (e.g., Integer, Long) and unboxed primitives (e.g., int, long) in Mockito verify() statements. [Ref: TG-21084]

  • CLI: Cover now shows the coverage given by manual (non-Diffblue) and Diffblue tests when running coverage-reports command or create with --coverage-reports option. [Ref: TG-21081]

  • CLI & Reports: Cover CLI now supports overriding the project name and location of reports within the Reports organizational structure using the --location and --project-name options. [Ref: TG-21019]

  • Cover now checks compatibility between the versions of the javax.servlet (or jakarta.servlet) API and the Spring Core framework being used. If incompatible versions are found, Cover will report E107 (Incompatible Spring dependency). [Ref: TG-20958]

  • Plugin: Cover's License Details window now shows the email address used to verify the active Community Edition license. [Ref: TG-20940]

  • Cover now writes tests which assert on responses from Reactive controllers using expectStatus, expectHeader and expectBody. [Ref: TG-20853]

  • Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to report spring-boot-starter-webflux as a missing dependency despite the project not containing Reactive controllers. [Ref: TG-21129]

    • Reports: Resolved an issue which, in some circumstances, caused tables to duplicate rows after changing the sorting order via column headings. [Ref: TG-21068]

    • Reports: Resolved an issue which, in some circumstances, caused <root> to be shown in the recent projects list [Ref: TG-21061]

    • Reports: Resolved an issue which, in some circumstances, caused an error to be displayed after navigating to the home screen while the coverage details tab is open. [Ref: TG-21060]

    • Reports: Resolved an issue which caused deleted projects to be visible in the recent projects list. [Ref: TG-21025]

    • CLI: Cover's environment summary output now reports Warning, rather than Success, for the 'Test Validation' row when Test Validation has been disabled by the user. [Ref: TG-20857]

    • Resolved an issue which caused Cover to, in some circumstances, discard tests written for methods which spawn threads. Cover now reports R011 (Sandboxing policy violation) when encountering methods which provoke sandboxing policy violations in a thread. [Ref: TG-20525]

    Known Issues

    • Plugin: Cover Plugin incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover: Diffblue Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • Test Code Changes: Improvements in how Cover selects and writes assertions may result in significant changes to existing tests.

  • Cover Reports requires Java 17: Cover Reports now requires Java 17 due to an upgrade to Spring Boot 3 and Spring 6. Ensure your environment is updated accordingly.

  • Deprecations

    • JUnit 4.7-4.10: Deprecated in a previous release. Please upgrade to JUnit 4.11 or higher to avoid future compatibility issues. Support for JUnit 4.7-4.10 will be removed in a future release.

    Removals

    • CLI --project option: Deprecated in a previous release and removed in this release. Please use --project-name and --location options instead. For more details, refer to the Generate and upload reports bundles documentation.

    Enhancements

    • Cover now produces assertions for base class getters when writing tests for simple constructors. [Ref: TG-21562]

    • Cover now provides more detailed information and remediation advice when the internal analyzer process fails to start up. [Ref: TG-21341]

    • Cover now makes better decisions about which inputs to assert on. [Ref: TG-21246]

    • CLI: Cover's dcover build command now shows build progress when building multiple modules. [Ref: TG-21198]

    • Cover now writes tests with more concise assertions for StringBuffer, StringBuilder, URL, URI and UUID types. [Ref: TG-20803]

    • Cover now writes tests which reuse existing objects for method references, avoiding the creation of new objects. [Ref: TG-20690]

    • Cover now writes tests that reference Consumer and Supplier types. [Ref: TG-20685]

    Resolved Issues

    • Resolved an issue which caused Cover to write tests with unused statements inside StepVerifier lambdas. [Ref: TG-21565]

    • CLI: Resolved an issue which, in some circumstances, prevented Cover from identifying modules in a multi-module Maven project when the root module was not a parent of the other modules. [Ref: TG-21544]

    • Reports: Updated to Spring Boot 3 and Spring 6 to remove a vulnerability. Cover Reports now requires an environment with Java 17. [Ref: TG-20973]

    • Resolved an issue which, in some circumstances, caused Cover to assert on the size of a changed collection, rather than the contents. Cover now uses assertSame in these scenarios. [Ref: TG-20234]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • In rare circumstances Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

    Reports: Cover Reports can now visualize test coverage of projects without needing to write tests via dcover create first. [Ref: TG-18569]

    Resolved Issues

    • CLI & Plugin: Resolved an issue which caused Diffblue Cover to report R026: Failed to create Spring context if the Scala standard library is in use. [Ref: TG-19448]

    • CLI: Resolved an issue which caused Diffblue Cover to report F009: Internal error when providing an invalid Cover Reports server location. Diffblue Cover now reports E138: Unable to convert path to URL. [Ref: TG-19400]

    • Reports: Resolved a minor issue with the page navigation on the Projects page. [Ref: TG-19375]

    • Optimize: Resolved an issue which caused Diffblue Cover to log a NullPointerException when using a patch which contains a file path which cannot be found. Diffblue Cover now reports E124: Referenced file in patch file not found. [Ref: TG-19373]

    • CLI & Plugin: Improved E013: Compatible launcher not found output code messaging (JUnit Jupiter Launcher and JUnit Jupiter Engine version compatibility). [Ref: TG-19338]

    • Cover: Improved L024: Unexpected licensing exception output code messaging (licensing server connection). [Ref: TG-19280]

    • CLI & Plugin: Introduced a recommendation to avoid JUnit 4.11 and below when using JUnit Vintage Engine. Also recommend to avoid JUnit Vintage Engine when JUnit 5 is not present. [Ref: TG-19220]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration [Ref: TG-18282]

    CLI: Diffblue Cover's environment checks now provide a warning if the Jakarta project under test, using JUnit 5, is missing the mockito-junit-jupiter dependency. [Ref: TG-19112]

  • CLI: Diffblue Cover now reports an ERROR if --mock-static is used to write tests for a project without the mockito-inline dependency. [Ref: TG-18398]

  • CLI & Plugin: Diffblue Cover can now use the Mockito framework to test projects using Jakarta Context Dependency Injection (CDI). [Ref: TG-19110]

  • CLI & Plugin: Diffblue Cover's environment checks now ensure that suitable junit-jupiter-engine, junit-jupiter-api and junit-vintage-engine dependencies are present when required. [Ref: TG-19336]

  • CLI & Reports: Diffblue Cover now provides additional guidance and remediation advice when executing dcover create --coverage-reports on a Gradle project without useJunitPlatform() in the build.gradle file. [Ref: TG-19178]

  • Resolved Issues

    • CLI: Resolved an issue which caused Diffblue Cover to disable test verification when --skip-test-validation was specified. [Ref: TG-19217]

    • CLI & Plugin: Resolved an issue which caused Diffblue Cover to write tests using mocking for POJO-like interfaces where a suitable implementation was available. [Ref: TG-19161]

    • CLI & Plugin: Resolved an issue which, in some circumstances, caused Diffblue Cover to write unused when .. thenReturn mocks which could cause an UnnecessaryStubbingException. [Ref: TG-19113]

    • CLI & Plugin: Resolved an issue which could cause Diffblue Cover to report an incorrect version of junit-vintage-engine detected in the user's environment. [Ref: TG-19335]

    • CLI & Plugin: Fixed an issue where Diffblue Cover could not use MockitoJUnitRunner in tests with Mockito 2.22.0+. Also fixed an issue where Diffblue Cover would attempt to use MockitoExtension when it was not on the classpath which resulted in fewer tests. [Ref: TG-19111]

    • CLI & Reports: Resolved an issue which caused Diffblue Cover CLI to report E098 while uploading a reports bundle containing inconsistencies. Diffblue Cover now uploads the bundle successfully and logs the inconsistency. [Ref: TG-19326]

    • Reports: Resolved an issue which, in some circumstances, caused Diffblue Cover to incorrectly report lines which are excluded by Diffblue Cover and those that are not covered. Upgrade to 2023.06.02 and upload a new reports bundle to correct any previously inaccurate counts. [Ref: TG-19363]

    • Reports: Resolved an issue which caused Diffblue Cover to sort dates incorrectly on telemetry dashboards. [Ref: TG-19189]

    • Optimize: Resolved an issue where executing dcover optimize --patch-file=patch.file may result in unexpected, unhandled exceptions in Windows. [Ref: TG-19348]

    Known Issues

    • CLI & Plugin: Diffblue Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    Cover: Cover now attempts to find methods in the tested class as Predicate/Function parameters for the tested method. If none are found, it reverts to using mocked values. [Ref: TG-20318]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover CLI to report E014 - No build system found when using --classpath without Maven or Gradle present. [Ref: TG-20674]

    • CLI: Resolved an issue which under some circumstances caused Cover CLI to display the incorrect upload URL when uploading reports bundles. [Ref: TG-20439]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

    . [Ref: TG-22054]
  • Cover now provides EAP support for IntelliJ IDEA 2024.3. [Ref: TG-21974]

  • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]
  • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • just launched
  • Cover: Diffblue Cover now provides more granular output codes and messaging to help resolve issues with licenses. [Ref: TG-19463]

  • Cover: Diffblue Cover now supports writing tests for Spring 6 controllers, validators and repositories, in addition to entities and components. [Ref: TG-19368]

  • Cover: Diffblue Cover CLI can now add missing project dependencies, automatically, by using dcover fix-build after running dcover create --preflight. [Ref: TG-19317]

  • IntelliJ Plugin: Cover now supports IntelliJ IDEA Community Edition 2023.2 and IntelliJ IDEA Ultimate 2023.2. [Ref: TG-19196]

  • Cover: Diffblue Cover now uses the canonical constructor for inputs that are records. [Ref: TG-18142]

  • Cover: Diffblue Cover can now write tests for methods which use Java 17 Records. [Ref: TG-17133]

  • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Cover may, in some circumstances, write tests which provoke W002: Test compiled, but did not pass, while using TestNG with Spring 4. [Ref: TG-19619]

  • this article
    while attempting to run
    dcover fix-build
    . [Ref: TG-22358]
  • Resolved an issue which prevented Cover from writing assertions for methods that statically returned object while returning a boolean at runtime. [Ref: TG-22325]

  • Resolved an issue which could cause test validation to fail when a particular combination of Maven plugins were present. [Ref: TG-22299]

  • Resolved an issue which, in some circumstances, caused Cover to report F009 (Internal Error) while writing tests for code involving an ObjectMapper and Jackson Databind < 2.2.0. [Ref: TG-22296]

  • Resolved an issue which, in some circumstances, for some project configurations, could cause environment checks to report an inaccurate JaCoCo coverage. [Ref: TG-22219]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • just launched

    Plugin: Cover's Test Review feature now provides a warning if unreviewed tests will be lost when closing the Test Review panel. [Ref: TG-21295]

    Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • just launched
  • Spring Controller Improvements: Test generation now produces more concise annotations and better handles @ControllerAdvice classes.

  • Bug Fixes: This release resolves issues related to:

    • Gradle compilation parsing

    • Automatic Spotless formatting

    • Module path errors in multi-module projects

  • Important Notices

    Test Review Plugin: Enabled by Default (from 2025.03.01)

    Starting with the next release, the Test Review feature in the IntelliJ Plugin will be enabled by default.

    • Tests must be accepted manually before appearing in your codebase.

    • You can edit or reject tests as needed.

    • If you haven’t tried it yet, enable it now from the IntelliJ Plugin's Diffblue Settings menu.

    Read the Test Review documentation.

    CLI: Deprecation of Build System Customization Options

    As of this release, the following CLI options have been deprecated:

    • --build-system-configuration

    • --ignore-stylechecks

    • --jacoco-command-diffblue

    • --jacoco-command-manual

    • --jacoco-xml-test-report

    • --preflight-test-command

    • --preflight-test-timeout

    • --validation-timeout

    • --validation-command

    Migrating to a DiffblueBuild.yaml file is recommended for build system integration. See the configuration guide for more details.

    Enhancements

    • CLI: Cover now includes an --exclude-trivial-methods flag for CLI users to opt-out of testing trivial methods like getters and setters. This provides more control over test generation, helping avoid unnecessary tests for simple methods. [Ref: TG-22709]

    • CLI: Build system customization options (e.g., --build-system-configuration) are now deprecated. Configure Cover using a DiffblueBuild.yaml file for improved build system integration. [Ref: TG-22640]

    • CLI: Cover now supports projects which use Ant build systems. [Ref: TG-22631]

    • CLI: Diffblue now offers Ant build system tasks via our public Maven repository, simplifying integration for Ant projects by enabling the use of a Maven dependency instead of specifying an absolute JAR file path. [Ref: TG-22611]

    • CLI: Cover's environment and test creation summaries in log files now include the project module name, improving clarity and searchability. [Ref: TG-22581]

    • Cover now generates @MethodsUnderTests annotations more concisely using available imports, enhancing test code readability and simplifying maintainability. [Ref: TG-22558]

    • Reports: Enterprise users can now integrate their existing SSO providers, such as Keycloak, for secure authentication and role-based access control. This enhances data security, streamlines user management, and ensures compliance with enterprise policies. [Ref: TG-22509]

    • Cover now more accurately identifies essential mock dependencies in Spring applications, resulting in tests with reduced unused mocking and improved readability. [Ref: TG-22411]

    • Cover now generates better tests for Spring Controllers. Cover considers @ControllerAdvice classes when writing tests, leading to more complete and accurate results for applications using Spring's exception handling. [Ref: TG-20569]

    Resolved Issues

    • Resolved an issue which caused Cover to incorrectly parse compilation failures on Gradle projects when using Java 17.0.14+ and newer versions. [Ref: TG-22677]

    • Resolved an issue where Cover did not automatically apply Spotless, when available, for test code formatting in Gradle builds. [Ref: TG-22658]

    • Resolved an issue where Cover failed to run on certain multi-module Gradle projects due to module path errors. This caused Failed to run a simple example test (E011) warnings during execution. [Ref: TG-22592]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    Learn more
    Learn more
    : Cover now includes tests created without dependency injection when they demonstrably increase code coverage. It also prioritizes constructor usage over setters for more natural test code.
  • Plugin UI: Cover now features a redesigned tool panel for the test preparation phase. The updated interface provides clearer insights into preparation steps, including error detection and licensing checks.

  • Important Notices

    CLI: Deprecation of Legacy Cover Reports Authentication Parameters

    As of the 2025.03.02 release, the following authentication options have been marked as deprecated:

    • reports.requiredusername

    • reports.requiredpassword

    Migrating to the new authentication parameters is required to avoid disruption to reporting pipelines. Use reports.users.upload.username and reports.users.upload.password instead.

    Enhancements

    • Reports: Cover Reports now uses reports.users.upload.username & reports.users.upload.password for upload authentication. Existing reports.requiredusername & reports.requiredpassword will be removed in a future release. [Ref: TG-22917]

    • CLI: Cover now logs details when @InTestsMock and similar mocking advice is applied or cannot be applied. Logs include reasons such as missing frameworks or incompatible class types. [Ref: TG-22846]

    • CLI: Cover’s test generation process now includes tests created without dependency injection. These tests are added only when they demonstrably increase code coverage compared to dependency injection-based tests. [Ref: TG-22842]

    • Plugin: Diffblue Cover now includes an 'Activate License' option in the Status Bar widget and on the 'Diffblue Cover License' details screen. This provides easier access to change license keys. [Ref: TG-22841]

    • Cover now supports Mockito 5.16.0. [Ref: TG-22836]

    • Plugin: Diffblue Cover now features a redesigned tool panel for the test preparation phase. The updated interface provides clearer insights into preparation steps, including error detection and licensing checks. [Ref: TG-22776]

    • Reports: Cover Reports now features a REST API for accessing coverage data. System administrators can leverage this API to integrate Reports with existing tools. [Ref: TG-22699]

    • CLI: Cover now removes MaintainedByDiffblue tests failing validation. Previously, only tests in DiffblueTest classes could be removed during validation. Now failing tagged tests in classes that match the --class-name-template will also be removed. [Ref: TG-22604]

    • Cover now supports writing tests for code which uses the Jersey RESTful Web Services library. [Ref: TG-22322]

    • CLI & Plugin: Cover now prioritizes constructor usage over setters when generating tests. This results in more natural and representative test code. [Ref: TG-18736]

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to write tests with when() Mockito stubs which were never used. [Ref: TG-22852]

    • Resolved an issue which, in some circumstances, caused Cover to report Cover Annotations as 'Not Detected' during environment checks. [Ref: TG-22840]

    • Reports: Resolved an issue which, in some circumstances, could have caused an inconsistent Diffblue test count due to unexpected surefire report files. [Ref: TG-22740]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • When using Gradle, Junit 5 tests produced with the @DisplayName annotation may cause all the Diffblue tests to be removed from the class in validation [Ref: TG-22784]

    • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

    • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

    export API documentation

    Changes to test code: With Descriptive Test Naming enabled by default, and improved grouping of related tests, updating to this version is likely to cause a larger than usual diff in your test code.

    Enhancements

    • Cover now supports Junit Jupiter 5.11.2 [Ref: TG-22109]

    • CLI: Cover now outputs the default Maven or Gradle configuration to DiffblueBuild.yaml by running dcover build-default-config --maven or dcover build-default-config --gradle. [Ref: TG-22095]

    • Cover: Improved String and char input descriptions for test method names and Javadoc. [Ref: TG-22083]

    • Cover CLI & Plugin: Descriptive Test Naming is now enabled by default. Descriptive Test Naming can be disabled via the plugin settings or by using the --no-descriptive-test-names CLI option. [Ref: TG-22014]

    • Improved Cover's ability to obtain objects using builders, specifically feign.Response objects with feign.Response.Builder, leading to better test coverage. [Ref: TG-22010]

    • Cover now selects the most relevant assertions by comparing all tests written for a method under test. [Ref: TG-21627]

    • Cover now avoids writing tests which pass null values into @Nonnull annotated method parameters. [Ref: TG-21387]

    • Plugin: Cover's test creation settings can now be reset to default via the 'Restore Defaults' button in the plugin settings panel. [Ref: TG-20577]

    Resolved Issues

    • Resolved an issue which caused Cover to report DETECTED_LIBRARY_VERSIONS: SemverException: Invalid version, during environment checks, also causing subsequent environment checks to fail. [Ref: TG-22140]

    • Reports: Resolved an issue which caused Cover to show empty coverage bars for multi-module projects in the project table. [Ref: TG-22072]

    • Resolved an issue which caused Cover to inconsistently identify tests targeting the same method(s). Cover now has improved grouping of related tests. [Ref: TG-21989]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use an earlier version of Mockito. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    IntelliJ Plugin documentation
    Cover CLI documentation

    Reports: Resolved an issue which caused Cover to not provide appropriate remediation advice when a JaCoCo report is missing expected contents. [Ref: TG-18370]

      // Arrange
      Owner owner = new Owner();
      owner.setAddress("42 Main St");
      owner.setCity("Oxford");
      owner.setFirstName("Jane");
      owner.setId(1);
      owner.setLastName("Doe");
      owner.setTelephone("6625550144");
    
      Owner owner1 = new Owner();
      owner1.setAddress("17 High St");
      owner1.setCity("London");
      owner1.setFirstName("John");
      owner1.setId(2);
      owner1.setLastName("Smith");
      owner1.setTelephone("8605550118");
    IntelliJ Plugin: Cover now avoids adding duplicate simple assertions to existing tests when ‘Write Tests’ is executed on the same method/class/package multiple times. [Ref: TG-17541]
  • Cover test creation performance has been improved, reducing time required to write tests. [Ref: TG-17491]

  • Working with code R011
    click here
    here
    this video
    , allows you to replace the
    @Autowired
    annotation with a specified custom alternative in your generated tests.
  • Improved Performance: To prevent performance issues during test creation, Cover now mocks Spring's ApplicationContext when it falls back to creating non-Spring tests within a Spring project.


  • Improved Test Quality & Strength

    • Stronger SQL Tests: Cover now writes stronger tests for code that uses java.sql.ResultSet by creating assertions on column values. It also prioritizes user-defined factories annotated with @InterestingTestFactory to increase test coverage.

    • Builder Pattern Support: An issue has been resolved that prevented Cover from writing tests for classes using the builder pattern. Tests for these classes are now generated successfully, including assertions on the state set by setters.

    • Enhanced Test Readability: To produce cleaner and more maintainable tests, Cover now avoids unnecessarily mocking objects, such as entities, when it can create an instance directly.


    Configuration & Integration

    • New Test Filters: To resolve an issue that could cause the Maven Spotless plugin to fail, DiffblueBuild.yaml v2.2 introduces new test filters for file and class matching (DIFFBLUE_TEST_*_PATTERN), which support both glob and regex formats. Existing REGEX filters remain supported for backward compatibility. For more details, see our documentation.


    Important Notices

    Upcoming Improvement to Test Readability

    In an upcoming release, Cover will improve which methods are inlined, in particular in fluent-style method call chains such as builders. While this produces higher quality tests, please be aware that existing tests for affected classes will change, leading to noticeable changes in your test suite upon update.

    Deprecation of Inlining Options

    The inlining options (CLI: --act-into-assert, --arrange-into-act-assert, --inline-constants , --inline-constructors; Plugin: 'Test Style' dropdown and checkboxes 2-6 in the ‘Test Formatting’ panel) are now deprecated and will not have any effect on the code output. They will be removed in an upcoming Cover release. Please ensure these options are not used in any automated scripts.

    Upcoming Breaking Change in DiffblueBuild.yaml

    This only applies to projects that have a DiffblueBuild.yaml file. To speed up Diffblue Cover CLI, a new phase will be introduced in DiffblueBuild.yaml in an upcoming release. Instructions will be provided on how to update your DiffblueBuild.yaml file before updating the CLI (e.g. in CI/CD).

    Enhancements

    • Diffblue Cover now writes stronger tests for code using java.sql.ResultSet by creating assertions on column values. It also prioritizes user-defined factories annotated with @InterestingTestFactory, increasing test coverage and custom mocking capabilities. [Ref: TG-23665]

    • Diffblue Cover now mocks Spring's ApplicationContext when it falls back to creating non-Spring tests in a Spring environment. This change avoids instantiating a full ApplicationContext, which could previously cause performance issues during test creation. [Ref: TG-23628]

    • Diffblue Cover now detects and handles Spring-derived custom annotations, i.e. the annotation is in turn annotated with its corresponding Spring annotation. A new environment variable, DIFFBLUE_AUTOWIRED_ALTERNATIVE, allows for selecting the custom annotation to be used in the test output. If not specified, Diffblue Cover continues to use @Autowired in the generated tests. [Ref: TG-23328]

    Resolved Issues

    • Resolved an issue where Diffblue Cover would encounter an internal error and fail to write tests for methods with certain complex conditions. Test generation for this code is now unblocked. [Ref: TG-23667]

    • Resolved an issue that prevented Diffblue Cover from writing tests for classes using the builder pattern, particularly when assertions were needed on the state set by setters. Tests for these builder classes are now generated successfully. [Ref: TG-23565]

    • Resolved a Windows-specific issue where Diffblue Cover was unable to generate tests for some methods, resulting in an F009 internal error. This prevents failures that produced the message "An operation was attempted on something that is not a socket". [Ref: TG-23550]

    • Resolved an issue that could cause the Maven Spotless plugin to fail. DiffblueBuild.yaml v2.2 introduces new test filters for file and class matching (DIFFBLUE_TEST_*_PATTERN), supporting both glob and regex formats. Existing REGEX filters are still supported for backward compatibility. [Ref: TG-23390]

    • Resolved an issue where Diffblue Cover would generate tests with unnecessary mocks for instantiable objects. Tests for code using patterns like entity objects are now more readable and contain fewer mock setups. [Ref: TG-21664]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. To avoid this, use an earlier version of Mockito. Downgrading to Mockito 4.x is the recommended workaround. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

    • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

    Enhanced Controller Tests: Cover now generates more effective tests for controller methods that have HttpRequest and HttpSession parameters.

    LLM String Generation for Test Inputs (Beta)

    • Selective Control: Introduces the @InTestsUseLLM annotation, enabling selective use of LLM-generated string inputs for specific methods, classes, or packages. This allows users to balance test generation speed and API costs by applying realistic string generation only where most needed. Requires cover-annotations library v1.8.0+ and an active LLM Configuration (Beta). For more information, see the LLM Input Annotations documentation.

    • Anthropic Models: Resolved an issue that prevented using Anthropic models with the LLM String Generation for Test Inputs beta feature.

    CLI Enhancements & Stability

    • dcover fix-build Reliability: Resolved an issue where the dcover fix-build command could unreliably update pom.xml files. The command now modifies Maven project configurations with improved reliability.

    • dcover validate Command: Resolved an issue where the dcover validate command could remove valid fields, imports, or entire test classes. The command now correctly identifies and removes only individual failing tests.

    Test Generation & Quality

    • Google Protobuf Support: Resolved a security sandbox policy violation that prevented Cover from writing tests for code using Google Protobuf. Test generation now proceeds successfully in this scenario.

    • JUnit Annotation Compatibility: Resolved an issue that could cause Cover to generate tests with incompatible @RunWith and @ExtendWith annotations, ensuring all generated tests have a valid configuration.

    IntelliJ Plugin

    • Plugin Stability: Resolved a rare issue that could cause an 'Internal Error' after Environment Detection, preventing some users from writing tests. Users in affected environments can now successfully write tests.


    Important Notices

    Upcoming End of Support for IntelliJ 2025.1

    This release is the final release that supports IntelliJ 2025.1. In line with our policy of supporting the two most recent major versions, support for 2025.1 will be discontinued in an upcoming release.

    To continue receiving Diffblue Cover updates and support, users on IntelliJ 2025.1 are advised to upgrade to IntelliJ 2025.2 or newer.


    Enhancements

    • Diffblue Cover now generates more effective tests for Spring MVC controller methods that use HttpRequest and HttpSession parameters, improving test coverage for web controllers. [Ref: TG-23940]

    • Diffblue Cover now writes tests more quickly for projects containing Spring entities with a large number of fields, resulting in improved overall performance during test generation. [Ref: TG-23839]

    • Diffblue Cover now supports the @InTestsUseLLM annotation, enabling selective use of LLM-generated string inputs for specific methods, classes, or packages. This allows users to balance test generation speed and API costs by applying realistic string generation only where most needed. This feature requires cover-annotations library v1.8.0+ and an active LLM Configuration (Beta). [Ref: TG-23811]

    Resolved Issues

    • Resolved an issue where a security sandbox policy violation would prevent Diffblue Cover from writing tests for code using Google Protobuf. Test generation will now proceed for methods that previously triggered an R011 output code in this scenario. [Ref: TG-23902]

    • Resolved an issue which prevented the use of Anthropic / Claude models for the LLM String Generation for Test Inputs beta feature. Diffblue Cover can now correctly connect to this provider to generate realistic string values in tests. [Ref: TG-23892]

    • Plugin: Resolved a rare issue that caused an 'Internal Error' after Environment Detection due to a class path resolution problem, which prevented some users from writing tests. [Ref: TG-23890]

    • CLI: Resolved an issue that caused the dcover fix-build command to unreliably update pom.xml files. The command now reliably modifies Maven project configurations to resolve testability blockers. [Ref: TG-23392]

    • Resolved an issue that could cause Diffblue Cover to generate tests with incompatible @RunWith and @ExtendWith annotations. All generated tests now have compatible annotation configurations. [Ref: TG-23378]

    • Resolved an issue where the dcover validate command could incorrectly remove valid fields, imports, or entire test classes. The command now correctly identifies and removes only individual failing tests. [Ref: TG-23151]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Using JDKs other than the supported Open JDK and Oracle JDK may produce unexpected results due to implementation differences. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. The recommended workaround is to downgrade to Mockito 4.x. [Ref: TG-19610]

    • Reports: The total line count metric in Reports only includes Java code. Kotlin code is not included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

    • When test formatting settings are changed, the Test Review feature may incorrectly remove the @ManagedByDiffblue annotation from tests, particularly in cases involving static import formatting changes. [Ref: TG-23750]

    • Plugin: Using the Test Review feature may create tests that have incompatible dependency injection systems. [Ref: TG-23935]

    Improved Static Field Assertions: Assertions for static fields now consistently use direct static access (e.g., MyClass.MY_FIELD), ensuring generated tests follow recommended Java coding standards.

  • Improved CLI Functionality & Stability

    • Expanded Argument File Support: All CLI commands now support .args files, and a common.args file can be used to specify arguments that apply across all commands for simpler configuration.

    • Robust Classpath Validation: The CLI now validates each classpath entry, allowing test generation to proceed successfully even if some entries are invalid.

    • Resolved Dependency Conflicts: An issue with Jackson library conflicts that could cause build failures in Maven, Gradle, and Ant has been resolved, improving stability and support for older environments.

  • Performance & Usability

    • Improved Performance: Cover now runs faster and uses less memory by optimizing its analysis process. This may result in small changes to generated tests without impacting overall code coverage.

  • Important Notices

    Deprecations

    • Deprecation of support for JUnit 5.0-5.2 in the IntelliJ Plugin: With this release (2025.07.02), support for JUnit versions 5.2 and below is deprecated and will be removed in the next release (2025.08.01). To ensure continued compatibility, users must upgrade projects using JUnit 5.0.x, 5.1.x, or 5.2.x to version 5.3.0 or higher. This change does not affect projects using JUnit 4 or TestNG, nor does it impact the Diffblue Cover CLI.

    Enhancements

    • Diffblue Cover now consistently generates assertions for static fields using direct static access (e.g., MyClass.MY_FIELD) instead of instance access. This ensures generated tests adhere to recommended Java coding standards. [Ref: TG-23533]

    • Diffblue Cover now operates with improved efficiency in memory and speed by optimizing its analysis process. This may result in minor changes to generated tests without reducing overall code coverage. [Ref: TG-23492]

    • Diffblue Cover now generates cleaner, more readable tests by simplifying Mockito verify() calls. This avoids redundant eq() matchers, improving maintainability and preventing SonarQube code smell warnings. [Ref: TG-23329]

    • CLI: Diffblue Cover now extends support for argument files (.args) to all CLI commands. Additionally, a common.args file can now be used to specify arguments that apply to all commands, simplifying configuration. [Ref: TG-23036]

    Resolved Issues

    • CLI: Resolved an issue where invalid entries in the classpath, such as non-JAR files, could cause test generation to fail. Diffblue Cover now validates each classpath entry, ensuring only valid JAR files and directories are used. [Ref: TG-23506]

    • CLI: Resolved an issue where dependency conflicts with the Jackson library could cause build failures in Maven, Gradle, and Ant projects. Diffblue Cover now shades this dependency, improving stability and enabling support for older environments like Gradle 6.8.3. [Ref: TG-23272]

    • Plugin: Resolved an issue where Diffblue Cover would fail to parse the @MethodUnderTest annotation if its value was split across multiple lines by code formatters. This ensures tests with formatted annotations are correctly recognized in the IntelliJ plugin. [Ref: TG-23168]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. To avoid this, use an earlier version of Mockito. Downgrading to Mockito 4.x is the recommended workaround. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

    • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

    New dcover issues Command (Beta): Diffblue Cover now provides the new dcover issues command, which analyzes test creation output to consolidate issues and provide context-specific LLM consumable prompts for resolving problems that block test generation. For more details, see our documentation.

  • Domain-Specific Test Inputs (Beta): Cover can now use an optional LLM integration (Beta) to generate more domain-specific string inputs for tests. This feature results in higher-quality tests with more semantically appropriate inputs. For more details, see our documentation.

  • Improved Test Quality & Coverage

    • Enhanced Servlet Test Coverage: Cover now generates tests with improved coverage for applications using Java servlets by more effectively analyzing methods that use servlet request and response objects.

    Performance & Stability

    • Faster Refactoring for Maven Projects: The dcover refactor command now runs more efficiently for multi-module Maven projects by executing a key build step once for the entire project instead of for each module, significantly reducing completion time.

    • Custom Build Configuration Support: Resolved an issue that could cause Cover to fail with a project structure error (E016) when using a custom build configuration.

    • Gradle Multi-Release JAR Support: An issue has been resolved that caused analysis failures in Gradle projects containing multi-release JAR artifacts, allowing tests to be written successfully.


    Enhancements

    • Diffblue Cover now provides the new dcover issues (Beta) command. This command analyzes output from dcover create to consolidate issues and provide context-specific LLM consumable prompts for resolving problems that block test generation. [Ref: TG-23862] Docs

    • Diffblue Cover now generates tests with improved coverage for applications using Java servlets by more effectively analyzing methods that use servlet request and response objects. [Ref: TG-23817]

    • Diffblue Cover can now generate more domain specific string inputs for tests using its optional LLM integration (Beta). Configuring and enabling this feature allows Cover to write tests with more semantically and domain appropriate test inputs, resulting in better quality tests. Please note that enabling this feature may cause Diffblue Cover to take significantly longer to write tests. [Ref: TG-23770]

    • The dcover refactor command now runs more efficiently for multi-module Maven projects. A key build step is now executed once for the entire project instead of for each module, significantly reducing the command's completion time. [Ref: TG-23760]

    Resolved Issues

    • CLI: Resolved an issue that caused Diffblue Cover to fail with an E016 (Failed to determine project structure) error when using a custom build configuration. [Ref: TG-23882]

    • Resolved an issue where Diffblue Cover could select non-optimal string values for method parameters when no other data sources were available. This improves the quality and relevance of the generated unit tests in these specific scenarios. [Ref: TG-23844]

    • Resolved an issue that caused analysis failures in Gradle projects containing multi-release JAR artifacts, preventing tests from being written. [Ref: TG-23837]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Using JDKs other than the supported Open JDK and Oracle JDK may produce unexpected results due to implementation differences. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. The recommended workaround is to downgrade to Mockito 4.x. [Ref: TG-19610]

    • Reports: The total line count metric in Reports only includes Java code. Kotlin code is not included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

    • When test formatting settings are changed, the Test Review feature may incorrectly remove the @ManagedByDiffblue annotation from tests, particularly in cases involving static import formatting changes. [Ref: TG-23750]

    Indirectly, via the usual “Write Tests” request. Diffblue Cover analyses the method and related classes to write tests. If Diffblue Cover is unable to write complete tests (or partial tests if this option is enabled), it falls back to offering a single skeleton test for the method instead. This means that Diffblue Cover always creates at least one test for each of your methods.

    For further information, and an example of a skeleton test, please see our documentation at: https://docs.diffblue.com/knowledge-base/intellij/skeleton-tests/

    This release, we also:

    • Provide additional information when a class fails to load due to a static initialization failure

    • No longer create tests for default constructors in utility classes, thus avoiding the situation where there are no fields that could be asserted on.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • CLI: Cover's installer now removes previous installation entries whilst upgrading to a newer version. [Ref: TG-17155]

    • Cover now has improved output code reporting, correctly identifying more R006s (Static initializer failed), some of which which were previously reported as R005 (Unable to load class). [Ref: TG-17097]

    • CLI: Cover now provides a coverage-reports option to allow coverage reports to be generated without writing tests. [Ref: TG-17091]

    • Cover now has improved handling of implicit default constructors of static utility classes. [Ref: TG-16609]

    Resolved Issues

    • Resolved an issue which caused Cover to report an F009 (Internal Error) with Act steps must be contained in the steps. [Ref: TG-17105]

    • Resolved an issue which, in some circumstances, caused Cover to report an F009 (Internal Error) with NoClassDefFoundError after attempting to temporarily disable logging in the code for which tests were being written. [Ref: TG-17104]

    • Resolved an issue which caused Cover to write tests which assert on loopback and private network IP addresses. [Ref: TG-11594]

    • IntelliJ Plugin: Resolved an issue which, in some circumstances, caused Cover to write @DataJpaTests with missing properties setup. [Ref: TG-17175]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from the root module with --working-directory. [Ref: TG-16876]

    Gradle minimum version now 4.9+

    Our support for Gradle has moved to a minimum version of 4.9+, please upgrade your version if necessary.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • IntelliJ Plugin: Cover now supports offline license activation for Enterprise licenses. [Ref: TG-16794]

    • IntelliJ Plugin: Cover now supports IntelliJ IDEA Community Edition 2022.1 and IntelliJ IDEA Ultimate 2022.1. [Ref: TG-16521]

    Resolved Issues

    • Resolved an issue which caused Cover to not write tests for Java 17 projects using Gradle and Gradle projects with subprojects defined. [Ref: TG-16878]

    • Resolved an issue which caused Cover to not get an instance of a singleton stored in a private field of an inner class. [Ref: TG-16857]

    • Resolved an issue which caused Cover to not find appropriate Strings to satisfy a reference equality. [Ref: TG-16856]

    • IntelliJ Plugin: Resolved an issue which caused the 'offline license guide' link, on the 'View License Information' window, to link to a non-existent page. [Ref: TG-16818]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    IntelliJ Plugin - suppressing warnings from SonarQube

    Diffblue Cover writes tests that can be reported as “code smells” by SonarQube. By default, an option has been enabled in the Diffblue Cover IntelliJ plugin to add @SuppressWarnings to the start of each test, thus reducing the reported “code smells” in the SonarQube output. For more information, please see our documentation.

    Support for Java 17 COMING SOON!

    We have been working hard behind the scenes to get ready to support Java 17, and the work is nearly complete. We will have a full update next release!

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Cover now has improved handling for broken .class files. [Ref: TG-16730]

    • Cover can now write tests which use singleton instance getters as inputs. [Ref: TG-16675]

    • Cover can now write tests which use inputs which extend Map, including org.apache.commons.chain.Command implementations. [Ref: TG-16673]

    • CLI: Cover now provides improved guidance when issues are encountered whilst writing tests for projects which have both Gradle and Maven build systems present. [Ref: TG-16619]

    • IntelliJ Plugin: Cover now automatically adjusts IntelliJ IDEA's 'maximum heap size' to ensure optimal test-writing performance. [Ref: TG-16671]

    • IntelliJ Plugin: Cover no longer writes tests which use mocks if Mockito is not on the classpath. Such tests would previously have caused compilation warnings in IntelliJ IDEA. [Ref: TG-16769]

    • IntelliJ Plugin: Cover now supports adding @SuppressWarning annotations to tests it writes when the option is enabled in the plugin settings. [Ref: TG-16618]

    • IntelliJ Plugin: Cover now creates more descriptive run configuration names when tests are written for multiple items. [Ref: TG-16552]

    Resolved Issues

    • Resolved an issue which, in some circumstances, would cause F009 (Internal error) to be reported when applying mocks. [Ref: TG-14987]

    • Resolved an issue which caused F009 (Internal Error) comments to appear in tests written for Spring projects with XML configurations containing abstract beans. [Ref: TG-16735]

    • Resolved an issue which, in some circumstances, would cause R005 (Unable to load class) to be reported for classes that are actually present on the classpath and can be loaded. [Ref: TG-16711]

    • CLI: Resolved an issue which, when no manual tests are present, caused dcover create --coverage-reports to abort rather than creating a coverage report for the tests written by Cover. [Ref: TG-16739]

    • IntelliJ Plugin: Resolved an issue which, in some circumstances, could provoke an internal error while creating report.json. [Ref: TG-16554]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    Updated Javadoc links

    Following on from our previous update, providing a link to the method under test in the Javadoc of the test methods, we have now improved the Javadoc links for interfaces and combined tests.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Cover now includes an improved Javadoc for tests it has written. [Ref: TG-16865]

    • CLI: Cover now provides additional logging when providing custom test inputs via DiffblueRules.yml, including Properties instances. [Ref: TG-16957]

    • CLI: Cover now provides improved messaging whilst uploading test creation reports, via the upload and create options, to Cover Reports. [Ref: TG-16746]

    • IntelliJ Plugin: Cover now creates at least one test for all testable methods. See the for more details. [Ref: TG-16583]

    Resolved Issues

    • Resolved an issue which caused non-compiling tests to be written due to mocks using wildcard generics. [Ref: TG-16852]

    • Resolved an issue which, in some circumstances, caused insufficient remediation advice to be available when incomplete tests were written by Cover (due to the failure to create a Spring context). [Ref: TG-16804]

    • CLI: Resolved an issue which prevented absolute paths being handled correctly whilst providing custom test inputs via DiffblueRules.yml. [Ref: TG-16973]

    • IntelliJ Plugin: Resolved an issue which caused a spurious Unsupported Java Language Version warning to be logged whilst using some versions of Java 17. [Ref: TG-16956]

    • IntelliJ Plugin: Resolved an issue which caused 'Registered to' field to show null null <null> on the 'Diffblue Cover License' window whilst using a Community Edition license. [Ref: TG-16953]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    here
    New Diffblue Cover features

    Four new features - Reports, Optimize, Refactor and Replay - have been added in this release of Diffblue Cover. In addition to autonomously writing and maintaining entire unit test suites without developer intervention, Cover Enterprise Edition now enables you to:

    • Automatically refactor Java code to improve testability

    • Slash the time and cost to run tests in Continuous Integration

    • Understand test coverage and code risk across your organization

    • Automatically shift complex functional tests left into unit test suites

    Read this blog post or watch this short YouTube playlist to learn more about the new features. Then if you're interested in how the power of Enterprise Edition could help your team, get in touch via our website.

    {: width="908" height="251"}

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Reports: Improved responsiveness and usability of charts on the 'Output Codes' tab. [Ref: TG-18322]

    • Reports: Class/Package name widgets, on the 'Overview' tab, have been replaced with a pie chart showing 'coverage sources'. [Ref: TG-17390]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    Support log files contain extra debug information, which will enable our technical support team to efficiently respond to queries.

    This release, we have added additional information into the user log files to make them easier to understand. We have added in the command line options that the user has entered, and also added explanatory execution phase prefixes, such as [Creating]{: .language-plaintext} and [Validating]{: .language-plaintext}.

    For both the user and the support log files, we now also only log the classpath once, for ease of reading.

    Meet us at Devoxx in Belgium October 10th - 14th

    Diffblue are delighted to be sponsoring Devoxx Belgium 2022.{: target="_blank" rel="noopener"} Our team can’t wait to talk about AI for Code with the Java development community.

    Full What's New information available from within the IntelliJ plugin

    Convenient access to the full 'What's New' and release notes has been added to the IntelliJ plug-in menu, allowing you to keep informed of new features and enhancements as we continue to add them.

    {: width="162" height="203"}

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Cover now includes command line options, read from @config.txt files, in the user log file. [Ref: TG-17805]

    • Cover now includes execution phase prefixes, such as [Creating] and [Validating] in the user log file to make log files easier to read. [Ref: TG-17722]

    • Cover now logs the class path to the user and support log files only once, with each entry displayed on a separate line. [Ref: TG-17721]

    • Cover now hides irrelevant stack trace frames from the user log file to make log files easier to read. [Ref: TG-17720]

    • Cover now writes tests containing assertions for arrays mutated by the method under test. [Ref: TG-17551]

    Resolved Issues

    • Resolved an issue which would cause Cover to not detect the correct JUnit Jupiter version on Gradle projects. [Ref: TG-17838]

    • Resolved an issue which, in some circumstances, would cause Cover to write non-deterministic tests by asserting false equivalences between different date/calendar instances. [Ref: TG-17754]

    • Resolved an issue which, in some circumstances, caused Cover to incorrectly report R002 (Missing observers) when writing tests. [Ref: TG-16612]

    block. A
    try
    block is always followed by a
    catch
    block and there can be multiple
    catch
    blocks.)

    This update means more tests and greater coverage!

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Cover now detects class loading issues (R005/R006) early and logs them in a more succinct and readable way. [Ref: TG-17351]

    • Cover now handles NullPointerExceptions found in catch blocks the same as ones which are thrown. [Ref: TG-15203]

    • Cover now has an improved log message for MethodGroup failure reasons. [Ref: TG-17422]

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to not write a Spring test when mockito-inline is included in the project's dependencies. [Ref: TG-17282]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from root module with --working-directory. [Ref: TG-16876]

    this video

    2025-06-04

    This release introduces google-java-format as the new default code formatter, expands test coverage for generic classes and complex code structures, and delivers significant performance and stability improvements for the IntelliJ plugin.

    • Default Formatter & Test Management:

      • Code Formatter: Diffblue Cover now uses google-java-format as its default formatter for generated tests, ensuring consistent, modern styling out-of-the-box. This may cause a one-time formatting change in existing test files.

      • Test Annotations: Cover now annotates the tests and helper methods it creates with @ManagedByDiffblue, allowing it to safely update them in future runs. This provides greater flexibility and clearer attribution.

    • Expanded Test Coverage:

      • Generics & Mocks: Test generation has been enhanced for generic classes and now provides more appropriate return values for mocks, increasing method coverage in complex scenarios.

      • Core Engine: Resolved multiple issues that previously blocked test creation, including those related to Java 9+ module restrictions, inaccessible parent classes, and certain Spring Controller status codes.

    • IDE & Tooling Stability:

      • IntelliJ Plugin: Resolved critical issues that could cause test writing to stall or the IDE to become unresponsive, significantly improving performance and reliability.

      • TestNG: Fixed an issue to ensure setup and teardown methods are correctly applied when manual TestNG tests are in the same file as Diffblue tests.

    Important Notices

    Changes to test code

    • Test formatting: In this release (2025.06.03), Cover has switched the default test formatting style to google-java-format. This change will cause a one-time reformatting of existing test files, resulting in larger-than-usual diffs. If you would prefer not to use the new default and avoid this reformatting, you can configure an alternative formatter in your build system, which will override this setting.

    • Test tagging and ownership annotations: In this release (2025.06.03), Cover has replaced @Tag("MaintainedByDiffblue") with the new @ManagedByDiffblue and @Tag("ContributionFromDiffblue") annotations. This change will cause a one-time update to existing Diffblue tests. To take ownership of a test and prevent it from being overwritten, remove its

    Deprecations

    • Cover Reports authentication properties: The deprecated reports.requiredusername and reports.requiredpassword properties (and their corresponding REPORTS_REQUIREDUSERNAME/PASSWORD environment variables) have been removed in the 2025.06.03 release. Please migrate to the new reports.users.upload.username and reports.users.upload.password properties (or the REPORTS_USERS_UPLOAD_USERNAME and REPORTS_USERS_UPLOAD_PASSWORD environment variables) to prevent upload failures.

    Enhancements

    • Diffblue Cover now generates more tests for generic classes. This improvement helps achieve fuller method coverage in scenarios where different generic types are needed. [Ref: TG-23312]

    • Diffblue Cover now writes tests using DiffblueRules factories and @InTestsMock without requiring manual parameter configuration. The necessary parameters for the factory methods are now automatically generated, streamlining advanced test creation. [Ref: TG-23236]

    • Diffblue Cover now uses google-java-format as its default code formatter for generated tests. This may cause one-time formatting changes in projects without a specified formatter. An alternative formatter can be configured in the build system to override this. [Ref: TG-23125]

    Resolved Issues

    • CLI: Resolved an issue where Diffblue Cover would crash when running dcover validate on Java 17 or later. This was caused by missing module exports required by the formatter, which are now correctly provided for all dcover commands. [Ref: TG-23455]

    • Plugin: Resolved an issue that caused test writing to stall during environment checks within the IntelliJ plugin. This was triggered by projects with additional classpath entries, for example from Spring AOT, and has now been corrected. [Ref: TG-23383]

    • Resolved an issue that could prevent test generation. Diffblue Cover now correctly handles scenarios where a method uses a class that extends another class which is inaccessible from the package under test, preventing compilation errors and increasing test output. [Ref: TG-23363]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2025-05-01

    2025-05-01

    This release enhances test generation, particularly for code performing object comparisons and handling Optional types. It also offers new controls for limiting the number of assertions per test and delivers compatibility updates.

    • Test Generation & Quality: Improved test generation for code which performs object comparisons and for Optional types, plus consistent annotation sorting.

    • CLI Enhancements & User Control: New CLI options for setting assertion limits per test and listing all project modules.

    • Plugin Improvements: Improved plugin UX for test maintenance during class creation and refactoring.

    • Compatibility: Support for Gradle 8.14, JUnit Jupiter 5.12.2, and IntelliJ 2025.1.

    Important Notices

    Changes to test code

    • Test formatting: In a future release, Cover will switch the default test formatting style to google-java-format. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code. If you prefer a different style, an alternative formatter configured in your build system will override this new default.

    Deprecations

    • IntelliJ IDEA 2024.2: As of Cover 2025.05.01, IntelliJ IDEA 2024.2 is no longer supported. Cover requires IntelliJ IDEA 2024.3 or 2025.1.

    Enhancements

    • Cover now supports Gradle 8.14. [Ref: TG-23102]

    • Cover now supports JUnit Jupiter 5.12.2. [Ref: TG-23080]

    • Plugin: Improved user experience of test maintenance features when creating or refactoring classes. [Ref: TG-22994]

    • Diffblue Cover now writes more effective tests for methods utilizing Objects.equals(Object,Object). This improves test coverage for scenarios involving equality checks between objects. [Ref: TG-22948]

    Resolved Issues

    • CLI & Plugin: Resolved an issue that, in some instances, caused Diffblue Cover to include unneeded @MockBean annotations and org.mockito.Mock imports in Spring tests. [Ref: TG-22932]

    • CLI: Resolved an issue that caused Diffblue Cover to halt with an F009 error when a Jacoco destination variable was unresolved. The tool now attempts to utilize a default destination instead. [Ref: TG-22903]

    • CLI: Resolved an issue where Cover's validation process, for Gradle and JUnit 5 projects, could mistakenly delete whole test classes if a @DisplayName differed from the method name. Validation now accurately targets only the individual failing test. [Ref: TG-22784]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2025-07-01

    This release of Diffblue Cover enhances test generation for complex scenarios, particularly around error handling and mocking. This version also improves overall stability, strengthens the test generation sandbox, and introduces official support for Gradle 8.14.3.

    • Enhanced Test Generation & Mocking:

      • Exception Handling: Diffblue Cover now writes more comprehensive tests for exception handling, with new support for methods containing catch blocks and for methods that call superclass methods which throw exceptions.

      • Mocking: Mocking behavior is now more predictable and reliable. This is due to a higher priority being given to the @InTestMock annotation and a fix for an issue that prevented test creation for some methods involving verify mock assertions.

    • Improved Stability & Sandboxing:

      • Stability: Overall stability has been improved by resolving several internal errors (F009) that could interrupt test creation.

      • Sandboxing: The robustness of the sandbox has been enhanced to better prevent the execution of potentially harmful code during test generation.

    • Distribution & Compatibility:

      • Distribution: All release artifacts, including the CLI and plugins, are now published directly to the Diffblue Maven repository for easier download and integration.

      • Compatibility: Official support has been added for projects built using Gradle 8.14.3.

    Enhancements

    • Diffblue Cover now officially supports Gradle version 8.14.3. This update ensures compatibility and allows Diffblue Cover to correctly write tests for projects built with the latest Gradle release. [Ref: TG-23473]

    • Diffblue now publish release artifacts, including the CLI, plugin, and Cover Reports, to the Diffblue Maven repository for direct download and integration. [Ref: TG-23290]

    • Diffblue Cover now writes tests using DiffblueRules factories and @InTestsMock; the necessary parameters for the factory methods can now be omitted and will be automatically generated, streamlining advanced test creation. [Ref: TG-23236]

    Resolved Issues

    • Resolved an issue that prevented test generation for some methods involving mocks. Diffblue Cover now successfully writes tests for these cases, which will include the relevant verify mock assertions. [Ref: TG-23449]

    • Resolved an issue where Diffblue Cover would encounter an 'IllegalStateException: Recording is already in progress' error, leading to an F009 failure. Test generation will now continue successfully in these scenarios. [Ref: TG-23409]

    • Resolved an issue where the security manager sandbox could fail to prevent certain dangerous operations during test generation. Diffblue Cover's sandbox is now more robust, better preventing the execution of potentially harmful code while writing tests. [Ref: TG-23373]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2025-06-03

    Important Notice:

    If you are using Java 17 or later, Diffblue Cover 2025.06.03 may crash when running dcover validate due to missing module exports required by the formatter.

    This issue has been resolved in 2025.06.04.

    We recommend upgrading to the latest release for improved stability.

    This release introduces google-java-format as the new default code formatter, expands test coverage for generic classes and complex code structures, and delivers significant performance and stability improvements for the IntelliJ plugin.

    • Default Formatter & Test Management:

      • Code Formatter: Diffblue Cover now uses google-java-format as its default formatter for generated tests, ensuring consistent, modern styling out-of-the-box. This may cause a one-time formatting change in existing test files.

      • Test Annotations: Cover now annotates the tests and helper methods it creates with @ManagedByDiffblue, allowing it to safely update them in future runs. This provides greater flexibility and clearer attribution.

    • Expanded Test Coverage:

      • Generics & Mocks: Test generation has been enhanced for generic classes and now provides more appropriate return values for mocks, increasing method coverage in complex scenarios.

      • Core Engine: Resolved multiple issues that previously blocked test creation, including those related to Java 9+ module restrictions, inaccessible parent classes, and certain Spring Controller status codes.

    • IDE & Tooling Stability:

      • IntelliJ Plugin: Resolved critical issues that could cause test writing to stall or the IDE to become unresponsive, significantly improving performance and reliability.

      • TestNG: Fixed an issue to ensure setup and teardown methods are correctly applied when manual TestNG tests are in the same file as Diffblue tests.

    Important Notices

    Changes to test code

    • Test formatting: In this release (2025.06.03), Cover has switched the default test formatting style to google-java-format. This change will cause a one-time reformatting of existing test files, resulting in larger-than-usual diffs. If you would prefer not to use the new default and avoid this reformatting, you can configure an alternative formatter in your build system, which will override this setting.

    • Test tagging and ownership annotations: In this release (2025.06.03), Cover has replaced @Tag("MaintainedByDiffblue") with the new @ManagedByDiffblue and @Tag("ContributionFromDiffblue") annotations. This change will cause a one-time update to existing Diffblue tests. To take ownership of a test and prevent it from being overwritten, remove its

    Deprecations

    • Cover Reports authentication properties: The deprecated reports.requiredusername and reports.requiredpassword properties (and their corresponding REPORTS_REQUIREDUSERNAME/PASSWORD environment variables) have been removed in the 2025.06.03 release. Please migrate to the new reports.users.upload.username and reports.users.upload.password properties (or the REPORTS_USERS_UPLOAD_USERNAME and REPORTS_USERS_UPLOAD_PASSWORD environment variables) to prevent upload failures.

    Enhancements

    • Diffblue Cover now generates more tests for generic classes. This improvement helps achieve fuller method coverage in scenarios where different generic types are needed. [Ref: TG-23312]

    • Diffblue Cover now writes tests using DiffblueRules factories and @InTestsMock without requiring manual parameter configuration. The necessary parameters for the factory methods are now automatically generated, streamlining advanced test creation. [Ref: TG-23236]

    • Diffblue Cover now uses google-java-format as its default code formatter for generated tests. This may cause one-time formatting changes in projects without a specified formatter. An alternative formatter can be configured in the build system to override this. [Ref: TG-23125]

    Resolved Issues

    • Plugin: Resolved an issue that caused test writing to stall during environment checks within the IntelliJ plugin. This was triggered by projects with additional classpath entries, for example from Spring AOT, and has now been corrected. [Ref: TG-23383]

    • Resolved an issue that could prevent test generation. Diffblue Cover now correctly handles scenarios where a method uses a class that extends another class which is inaccessible from the package under test, preventing compilation errors and increasing test output. [Ref: TG-23363]

    • Resolved an issue where manual TestNG tests could fail when placed in the same file as tests written by Diffblue Cover. This was caused by setup and teardown methods not being correctly applied to manual tests, which is now fixed. [Ref: TG-23348]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • CLI & Plugin: Cover may write tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2025-06-02

    2025-06-02

    This release enhances how Diffblue Cover writes tests by adding new mock configuration controls to handle more complex scenarios, and by improving its resilience to project configuration issues.

    • Mock Configuration & Control:

      • Mocks: Cover now provides greater control over generated mocks using new @InTestsMock attributes. You can direct Cover to generate mocks that throw specific exceptions (throwException) or create custom return values from an object factory (returnValueFactory).

    • Core Engine & Tooling Stability:

      • Core Engine: Addressed R005 and F009 errors that could prevent Cover from writing tests in projects with missing parent dependencies or corrupt .jar files.

      • CLI & Plugin: Improved stability by resolving a CLI issue with the --new-jacoco-coverage command and fixing a performance issue in the IntelliJ plugin that could cause the UI to become unresponsive.

    Important Notices

    Changes to test code

    • Test formatting: In the 2025.06.03 release, Cover will switch the default test formatting style to google-java-format. This change will cause a one-time reformatting of existing test files, resulting in larger-than-usual diffs. An alternative formatter configured in your build system will override this new default.

    • Test tagging and ownership annotations: In the 2025.06.03 release, Cover will replace @Tag("MaintainedByDiffblue") with the new @ManagedByDiffblue and @Tag("ContributionFromDiffblue") annotations. This will cause a one-time update to existing Diffblue tests. To take ownership of a test and prevent it from being overwritten, remove its @ManagedByDiffblue

    Deprecations

    • Cover Reports authentication properties: The deprecated reports.requiredusername and reports.requiredpassword properties (and their corresponding REPORTS_REQUIREDUSERNAME/PASSWORD environment variables) will be removed in the 2025.06.03 release. Please migrate to the new reports.users.upload.username and reports.users.upload.password properties (or the REPORTS_USERS_UPLOAD_USERNAME and REPORTS_USERS_UPLOAD_PASSWORD environment variables) to prevent upload failures after the update.

    Removed Features

    • --existing-coverage option: The CLI option --existing-coverage for the dcover create command has been removed as of this release (2025.06.02). To write tests that target only new coverage, use the --new-jacoco-coverage option.

    Enhancements

    • Diffblue Cover now includes improved error handling for missing dependencies on the classpath. This enhancement prevents test generation from failing when a parent class cannot be found, significantly reducing R005 errors. [Ref: TG-23232]

    • Diffblue Cover now offers two ways to configure thrown exceptions from mocks using @InTestsMock. Specify an exception directly by its Class with the throwException attribute, or by a factory method with throwExceptionFactory. [Ref: TG-23051]

    Resolved Issues

    • CLI: Resolved an issue where Diffblue Cover could behave unreliably when using --new-jacoco-coverage with missing coverage data. Cover now warns users if JaCoCo .exec files are empty and provides a reason for keeping newly generated tests. [Ref: TG-23297]

    • Resolved an issue where Diffblue Cover would report an F009 (Internal Error) when encountering a Java InternalError. This fix correctly handles InternalError ensuring tests are written for previously affected methods. [Ref: TG-23265]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2025-06-01

    2025-06-01

    This release improves test generation, particularly for java.util.Optional and mock configurations. It also brings new CLI options for preflight checks and targeted JaCoCo coverage, alongside several key fixes and a new configuration warning.

    • Test Generation & Quality:

      • New attributes for @InTestsMock allow specifying return values in mocked methods, yielding more domain-specific mock behaviors.

      • Improved test generation for java.util.Optional by better considering isPresent status, leading to more robust tests and coverage.

      • Fix for Mockito any() calls with bounded generic parameters now correctly uses wildcards, improving test compilation and coverage.

    • CLI Enhancements & User Control:

      • New --new-jacoco-coverage option for dcover create solely writes tests that contribute new JaCoCo coverage, helping manage test volume.

      • Fix for environment summary not accurately reporting test validation status when disabled by an E022 error.

    • Configuration & Plugin Usability:

      • New warning for configured test output directories not matching src/test/java, helping identify misconfigurations early.

      • Plugin fix: Unchecking "Override test directory" now correctly clears prior settings, and re-checking defaults to src/main/java.

    Important Notices

    Changes to test code

    • Test formatting: In a future release, Cover will switch the default test formatting style to google-java-format. This will cause a one-time churn, resulting in larger-than-usual diffs in your test code. If you prefer a different style, an alternative formatter configured in your build system will override this new default.

    Deprecated Features

    • --existing-coverage option: The CLI option --existing-coverage for the dcover create command is deprecated as of release 2025.06.01 and is scheduled for removal in release 2025.06.02. This option was originally designed to use a JaCoCo file to guide test creation towards uncovered lines. To provide a more effective and streamlined experience for this functionality, it is being replaced. Users aiming to write tests focused on new coverage should now use the new --new-jacoco-coverage option, introduced in release 2025.06.01, which offers an enhanced and more direct approach.

    Enhancements

    • CLI: Diffblue Cover now displays a concise summary of environment checks if dcover remove is invoked with the --preflight option. This offers users a quick overview of prerequisites for the remove command. [Ref: TG-23186]

    • CLI: Diffblue Cover now features the --new-jacoco-coverage option for the create command, allowing it to solely write tests that contribute new JaCoCo coverage. This helps manage the volume of tests by adding only those that expand coverage. [Ref: TG-23149]

    Resolved Issues

    • Plugin: Resolved an issue where Diffblue Cover would use a previous override test directory value even if the "Override test directory" checkbox was unchecked. Unchecking now clears the prior setting, and re-checking defaults to "src/main/java". [Ref: TG-23191]

    • Resolved an issue where Diffblue Cover sometimes wrote Mockito any() calls using an explicit object type instead of a wildcard for bounded generic parameters. This allows more generated unit tests to compile successfully, improving test coverage. [Ref: TG-23185]

    • CLI: Resolved an issue where Diffblue Cover's environment summary did not properly reflect that test validation was disabled by an E022 error (JUnit Jupiter Launcher not found). This status is now accurately reported. [Ref: TG-21636]

    Known Issues

    • Plugin: Cover incorrectly provides a menu option to write tests for a test file. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    2025-11-02

    This release introduces support for JUnit 6 on Java 17+ and compatibility with IntelliJ 2025.3 EAP. The dcover issues command is also enhanced with a more scannable output and paging, and overall CLI memory usage is reduced.


    Framework & IDE Support

    • JUnit 6 Support: Diffblue Cover now writes tests compatible with JUnit 6 for projects using Java 17 and higher. For projects on Java versions 8 through 16, Cover continues to generate tests using the JUnit 5 framework.

    • IntelliJ 2025.3 EAP Compatibility: The Diffblue Cover IntelliJ plugin is now compatible with the IntelliJ 2025.3 Early Access Program (EAP), ensuring seamless test generation in the newest pre-release IDE versions.

    Command-Line Interface (CLI) Enhancements

    • dcover issues Usability: The dcover issues command is now more scannable, using bold headings and method counts for a compact view. The command also supports paging via a new --skip option, which can be combined with --limit to navigate the issue list. The --details option has been removed; use --prompts for detailed information.

    • Reduced Memory Usage: Cover now uses less memory when writing tests via the CLI. The memory footprint remains stable throughout test generation, improving performance and stability for large projects.

    Enterprise Reporting

    • Usage Tracking in Cover Reports: For enterprise deployments, Cover Reports can now track command line and plugin usage. Enable this feature by setting the telemetry.collect.username property in the telemetry.properties file to record the user's git identity.

    Stability & Security

    • Enhanced Sandbox Security: Resolved a rare issue where file writes could escape the sandbox during test generation on Java 8 through 24, enhancing the stability and security of the test generation process.


    Important Notices

    Upcoming Change to Test Generation

    From release 2025.12.01, Cover will optimize its test output to provide the same level of Diffblue Coverage by removing tests that provide redundant coverage within the same test class. This means Cover will produce fewer tests while maintaining the same level of Diffblue Coverage, reducing code bloat and maintenance overhead. This feature will be enabled by default.

    In addition, a new CLI option, --ignore-existing-coverage, will be introduced. You can use this option to disable the new behavior for a single run.

    Upcoming End of Support for IntelliJ 2025.1

    This release is the final release that supports IntelliJ 2025.1. In line with our policy of supporting the two most recent major versions, support for 2025.1 will be discontinued in an upcoming release.

    To continue receiving Diffblue Cover updates and support, users on IntelliJ 2025.1 are advised to upgrade to IntelliJ 2025.2 or newer.


    Enhancements

    • Diffblue Cover now supports paging for the dcover issues command. A new --skip option has been added, which can be combined with the existing --limit option to display a specific 'page' of the prioritized issue list. [Ref: TG-23962]

    • CLI: Diffblue Cover now provides a more scannable dcover issues output. Bold headings and method counts replace full method lists for a compact view. The --details option is removed; use --prompts for detailed information and LLM-ready prompts. [Ref: TG-23917]

    Resolved Issues

    • CLI: Resolved an issue that caused unnecessary console messages about synthetic or generated methods. The output from Diffblue Cover is now less verbose, no longer including entries for methods that are not candidates for test creation. [Ref: TG-23936]

    • Resolved an issue where, in rare cases, file writes could escape the sandbox during test generation on Java 8 to Java 24. This enhances the overall stability and security of the test generation process. [Ref: TG-23909]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Using JDKs other than the supported Open JDK and Oracle JDK may produce unexpected results due to implementation differences. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. The recommended workaround is to downgrade to Mockito 4.x. [Ref: TG-19610]

    2023-04-01

    Diffblue Cover CLI writes the same tests as the Diffblue Cover IntelliJ Plugin just at a larger scale. Cover CLI can:

    • write tests for your whole Java project in one go

    • run locally on a laptop or on a server in CI

    • integrate into any CI pipeline to write and maintain your unit tests automatically

    Cover CLI comes with the to ensure that your project is configured correctly for Cover CLI to undertake this mammoth task of writing thousands of unit tests, and to then analyse your coverage and report this to the analytics platform.

    In this release, Cover CLI Preflight will also check your existing tests are passing and their coverage; this is important to ensure that your coverage analytics are calculated correctly; and hey, who doesn't want to make sure their unit tests are passing?

    Enhancements

    • Cover now runs existing tests as part of the Preflight checks. This can be disabled by passing --without-tests. See the for more details. [Ref: TG-18651]

    • Cover now writes Spring Repository tests which are more likely to use distinct data items rather than duplicating them. [Ref: TG-18905]

    • Updated SnakeYAML dependency in Cover Reports and Cover IntelliJ Plugin. [Ref: TG-18891]

    Resolved Issues

    • Resolved an issue which caused Cover to attempt to write tests for projects using Spring Core 6 or Spring Boot 3, which are not currently supported. Cover now outputs a recommendation to use Spring Core 5 or Spring Boot 2. [Ref: TG-18868]

    • IntelliJ Plugin: Resolved an issue which caused Cover to show 'Fix issue' button(s) for issues which were not fixable. [Ref: TG-18812]

    • IntelliJ Plugin: Resolved an issue which caused Cover to misclassify dependency libraries on the classpath as code to be tested. [Ref: TG-18800]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading the Coverage Reports tab. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2022-08-02

    IntelliJ 2022.2 support

    Diffblue is excited to announce that we now support the brand new IntelliJ 2022.2 release - IntelliJ IDEA Community Edition 2022.2 and IntelliJ IDEA Ultimate 2022.2 In keeping with our policy of supporting the current and the previous releases, we now support IntelliJ 2022.2 and IntelliJ 2022.1.

    Mockito static mocking

    In this release, we introduce support for Mockito static mocking using the new `–mock-static` option. This feature enables the mocking of static methods of the specified classes in created tests using `Mockito.mockStatic`. To use this feature, you must have Mockito 3.4.0 or above. Full documentation is provided here:

    New CLI environment variables option

    You can now set environment variables in Cover using the --environment option. For full details please see our user manual:

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • IntelliJ Plugin: Cover now supports IntelliJ IDEA Community Edition 2022.2 and IntelliJ IDEA Ultimate 2022.2. [Ref: TG-17517]

    • IntelliJ Plugin: Cover now avoids writing duplicate tests when 'Write Tests' executed on the same method/class/package. [Ref: TG-17504]

    • IntelliJ Plugin: Cover now displays and updates the 'Write Test' flask gutter icons quicker. [Ref: TG-17461]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to exit with an error (Command could not be completed [...]: Maven application directory was not specified) when Maven was not installed. [Ref: TG-17632]

    • IntelliJ Plugin: Resolved an issue which caused Cover to not use IntelliJ IDEA's proxy authentication settings. [Ref: TG-17339]

    • CLI: Resolved an issue which caused Cover to be unable to resolve subprojects in a Gradle multi-module project. [Ref: TG-17544]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from root module with --working-directory. [Ref: TG-16876]

    2023-03-01

    Diffblue Cover IntelliJ Plugin can now fix common missing and mismatched dependency issues with one click

    Java projects can contain many different versions of dependencies; some of which are dependent on each other. Ensuring that all of the environmental conditions are compatible is a time consuming job; and if left incorrect can lead to spurious behaviours in your application. Furthermore, to successfully write unit tests, Cover requires tests dependencies to be available at the correct versions.

    In this release we have redesigned the Project Environment Health Check to clearly show plugin dependency issues in your project (such as mismatched versions of Spring dependencies) and in many cases automatically fix the issue for you by adding or upgrading dependencies. If Cover finds any issues it will clearly indicate with a X or ! next to the dependency and provide you with a "Fix issue..." button. If multiple issues are detected Cover will provide a "Fix all issues..." button to fix all of the issues that it has found.

    {: width="600"}

    Enhancements

    • Cover now provides a clearer message when invalid syntax is used to define a factory rule for customizing test inputs using in DiffblueRules.yml. [Ref: TG-18745]

    • Cover now reports R033 (Missing Spring properties), with information to help resolve the problem, when a Spring context can't be built due to @Value annotation evaluation issues. [Ref: TG-18405]

    • IntelliJ Plugin: Cover now provides a 'Project Environment Health Check' panel which identifies issues which may prevent tests from being written. [Ref: TG-14859]

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to create time-sensitive assertions which pass on the day the test was written, but fail afterwards. [Ref: TG-18709]

    • Resolved an issue which, depending on javac compile options, could cause Cover to incorrectly treat some methods as trivial. [Ref: TG-18695]

    • Resolved various issues in the Spring-related environment checks to cover more incompatibilities and to give better recommendations. [Ref: TG-18052]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading the Coverage Reports tab. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2023-12-02

    In this release, Cover Plugin now supports IntelliJ IDEA 2023.3, and Cover Reports has received further UI enhancements. Also of note, Diffblue Cover will now, by default, name tests after the whole unit under test, not just the first method, which may result in test name changes for existing projects. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: By default, Diffblue Cover will now name tests after the whole unit under test, not just the first method. Test naming remains configurable in Cover CLI and Cover Plugin. Note that this update may result in test name changes for existing projects. [Ref: TG-20559]

    • Cover: Diffblue Cover now has an option to disable the use of Spring for dependency injection in tests (--no-spring-tests in Cover CLI, Spring options in Cover Plugin Settings in IntelliJ). [Ref: TG-20480]

    • Plugin: Cover Plugin now provides a new "Standard" option for Test Formatting in Settings. This aligns the settings with the options available within Cover CLI. [Ref: TG-20479]

    • Cover: Diffblue Cover now shows the active Spring profiles in the Environment Summary / Environment Checks and Cover CLI will no longer issue a warning when the default profile is active. [Ref: TG-20457]

    • CLI & Reports: Diffblue Cover now errors if the provided version of JaCoCo is not supported (<0.8.3) while using the coverage-reports option on Gradle projects. If this affects your projects, you may wish to regenerate your reports bundles. [Ref: TG-20444]

    • Reports: Cover Reports now allows individual runs and associated data to be deleted. [Ref: TG-20354]

    • Reports: Cover Reports now allows projects and associated data (runs) to be deleted. [Ref: TG-20353]

    • Reports: Cover Reports now includes additional output codes within Advisories on the Coverage Detail tab. [Ref: TG-20352]

    • Plugin: Cover Plugin now updates existing Diffblue tests if they already exist for the method. [Ref: TG-20289]

    • Cover: Diffblue Cover can now write WebFlux partial tests for reactive controllers. [Ref: TG-20269]

    • Plugin: Cover Plugin now supports IntelliJ IDEA Community Edition 2023.3 and IntelliJ IDEA Ultimate 2023.3. [Ref: TG-20135]

    Resolved Issues

    • CLI: Resolved an issue which under certain circumstances would incorrectly report E115 - Incorrect JaCoCo coverage reported during environment checks. [Ref: TG-20497]

    • Cover: Resolved an issue which caused Diffblue Cover to report E022 (not able to discover the path to the JUnit Jupiter Launcher) when stdout is redirected. [Ref: TG-20395]

    • Cover: Resolved an issue which caused Diffblue Cover to incorrectly report a potential firewall issue when connecting with the Analyzer Service. [Ref: TG-20283]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2022-05-02

    Skeleton Tests now available in the Diffblue Cover IntelliJ plugin

    Skeleton tests are intended as a helpful starting point for users to write their own tests. They simply consist of a call to the method under test, with all variables initialized to null or zero, and TODO comments reminding the user to populate the “arrange” section and write some assertions.

    There are two ways of creating skeleton tests in the Diffblue Cover IntelliJ plugin:

    • Directly, by selecting Write Skeleton Tests when right-clicking on {: width="21" height="22"} or a method name. Diffblue Cover creates a single skeleton test for the method, and does not analyse your code.

    • Indirectly, via the usual "Write Tests" request. Diffblue Cover analyses the method and related classes to write tests. If Diffblue Cover is unable to write complete tests (or partial tests if this option is enabled), it falls back to offering a single skeleton test for the method instead. This means that Diffblue Cover always creates at least one test for all your methods.

    {: width="735" height="451"}

    For further information, and an example of a skeleton test, please see our documentation at:

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • CLI: Cover is now installable on Windows via a GUI or unattended installer. [Ref: TG-16791]

    • CLI: Cover now provides a --keep-partial-tests option which delivers incomplete tests in situations where Cover was not able to produce a full test. See the (CLI User Manual)[/knowledge-base/cli/] for more details. [Ref: TG-17109]

    • Cover now provides improved guidance if R026 (Failed to create Spring context) is encountered whilst writing tests. [Ref: TG-17038]

    Resolved Issues

    • Resolved an issue which, for projects configured with license-maven-plugin (and spotless-maven-plugin), caused Cover to report E084 (JaCoCo command failed). [Ref: TG-16970]

    • Resolved an issue which caused Cover to incorrectly include a Diffblue Cover was unable to write a Spring test comment when a Spring test had been written. [Ref: TG-16958]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • IntelliJ Plugin: If all partial tests are disabled via the plugin settings, or 'Write Skeleton Tests' is used, Cover may write @DataJpaTests with missing properties setup. [Ref: TG-17175]

    2023-05-01

    Tests for methods using ZonedDateTime

    Diffblue Cover now has the ability to write complete unit tests, with meaningful assertions, for methods which use the ZonedDateTime class, as shown in the example below.

    The test shown above initializes a Time object with a ZonedDateTime set to January 1, 1970 at midnight in UTC. It then calls the addAnHour method with a ZonedDateTime object set to the same date and time, but with a UTC offset of zero.

    This test asserts that the result of addAnHour has a time zone of UTC, and that its local date is the same as the original date. It also asserts that the local time of the result is one hour after midnight.

    Diffblue licensing service status page

    We are pleased to announce the launch of . This new resource provides users with real-time updates on the status of our licensing services. With this service, users can quickly and easily check the status of Diffblue's licensing service and receive updates on any service disruptions or maintenance periods.

    Enhancements

    • Cover now writes tests with meaningful assertions for methods which use ZonedDateTime. [Ref: TG-18406]

    • IntelliJ Plugin: Improved logging and remediation advice for situations where attempts to license Cover fail due to insufficient directory permissions. [Ref: TG-19015]

    Resolved Issues

    • Reports: Resolved an issue which, in some circumstances, would prevent Cover from uploading reports to a Cover Reports instance, reporting an ERROR containing Message: could not execute statement; SQL [n/a]; constraint [run_coverage_pkey];. [Ref: TG-19096]

    • IntelliJ Plugin: Resolved an issue which caused Cover to report an AlreadyDisposedException if a module was renamed shortly after clicking 'Write Tests'. [Ref: TG-19017]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2023-04-02

    Cover Reports, Diffblue's offering to provide a variety of ways to visualise an application based on information derived from Diffblue Cover, now allows restricting reports uploading to users/clients with a configured username and password. By default, Diffblue Cover will allow any user to upload files to Cover Reports. However, you may want to limit access so that only certain users can upload files.

    For example, you may choose to enable authentication if you only want your CI processes to upload data for a project, so that data is comparable and uploaded with a consistent timespan.

    See the Authenticating Cover Reports Uploads documentation for more details.

    Enhancements

    • Reports: Cover now supports restricting uploading of reports to users with a configured username and password. See the for more details. [Ref: TG-18859]

    • Cover now provides a stack trace when it encounters R012 (JNI sandbox policy violation) to help identify the reason tests could not be written. [Ref: TG-18729]

    • Cover now uses improved inputs while writing tests for methods with complex logic containing Collections and Lists. [Ref: TG-18673]

    • CLI: Cover now provides snippets of code to be added to POM files without ERROR and WARN line prefixes to make copy and pasting easier. [Ref: TG-16741]

    • IntelliJ Plugin: Cover now reports more project checks in the Project Environment Health Check panel. [Ref: TG-18790]

    • IntelliJ Plugin: Cover now supports automated fixing of projects with a missing junit-jupiter-engine dependency via the Project Environment Health Check panel. [Ref: TG-18904]

    Resolved Issues

    • Resolved an issue which caused Cover to fail to parse test results with a custom Gradle validation task. [Ref: TG-18984]

    • Resolved an issue which, in some circumstances, caused Cover to not write tests for setters with an Object argument setting an int. [Ref: TG-18965]

    • Resolved an issue which, in some circumstances, caused Cover to not write tests for some methods due to problems with resolving generic types. [Ref: TG-18654]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading the Coverage Reports tab. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2022-04-01

    Diffblue Cover now supports Java 17!

    We have been working hard behind the scenes to get ready to support Java 17, and are delighted to announce that this work is now complete! Diffblue Cover can now be used with Java 8, Java 11 (but please note not version 11.0.7) and Java 17.

    Diffblue Cover and Mockito

    Diffblue Cover now gives a warning if you are using a version of Mockito that is not supported by the JVM. It also suggests an updated version of Mockito to use, to ensure you get the best outcome and number of tests written.

    Support for IntelliJ IDEA 2022.1 - COMING SOON!

    We are expecting the release of IntelliJ IDEA 2022.1 any day now, and will be able to support this very shortly. Please look out for the next release!

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • Cover now supports writing tests for projects using Java 17. Support for Java 17-specific features, like records and sealed classes, will come in a future release. [Ref: TG-16352]

    • Cover now supports Apple M1 CPUs. [Ref: TG-16543]

    • Cover now supports a properties rule, which can be specified in DiffblueRules.yml, to populate a Properties instance from a file or classpath resource. . [Ref: TG-16683]

    Resolved Issues

    • IntelliJ Plugin: Resolved an issue which, in some circumstances, caused the "It looks like you haven't used Diffblue Cover [...]" survey to be shown too often. [Ref: TG-16721]

    • IntelliJ Plugin: Resolved an issue which caused the plugin settings scrollbar to not be at the top of the window when opened. [Ref: TG-16692]

    • Resolved an issue which, in certain circumstances, would provoke an F009 (Internal error) and fail to write a test for a method when generating large intermediate lists. [Ref: TG-16678]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • Cover may fail to write tests for Gradle projects using Java 17, and fails to create coverage reports when using Gradle on Java 17. [Ref: TG-16878]

    2024-02-02

    This release includes a number of syntax and argument changes in Cover CLI as detailed below. Also, Diffblue Cover now supports Mockito 5.10.x, and also supports writing tests for Kafka Producers in a Spring Context. See the full Release Notes below for details of all enhancements and resolved issues covered by this release. One final note, if you're a frequent user of our docs site, you'll notice some significant updates to our topic structure to help improve your learning experience.

    Enhancements

    • Reports: Cover Reports now allows projects to be managed, migrated and moved between groups, enabling flexible organization of data. [Ref: TG-20953]

    • CLI: The --disable-mock-inputs, --existing-coverage, --max-class-length, --merge, --skip-if-service-out-of-resources, and --skip-validation arguments have been hidden in Cover CLI. These remain valid but may be removed in future releases. [Ref: TG-20910]

    • CLI: The --output-comments and --spring-configuration arguments have been added to Cover CLI and are also documented in the Commands & Arguments topic. [Ref: TG-20883]

    • Cover: Diffblue Cover now supports Mockito 5.10.0. [Ref: TG-20842]

    • Plugin: SSO options are now available for verifying Cover Plugin Community Edition. [Ref: TG-20757]

    • Cover: A performance improvement has been applied to Diffblue Cover for the processing of XML project configuration files. [Ref: TG-20747]

    • Cover: Diffblue Cover now writes tests which use arguments of Jackson annotated types for methods which serialize objects using ObjectMapper.writeValueAsString [Ref: TG-20728]

    • Cover: Diffblue Cover now writes tests which use improved JSON strings as input arguments for methods which deserialize strings using ObjectMapper.readValue [Ref: TG-20717]

    • Cover: Diffblue Cover now supports writing tests for Kafka Producers in a Spring Context. [Ref: TG-20687]

    • Cover: Cover CLI now automatically detects the project name from the build system and uses this for Cover Reports. Cover CLI's --project option has been deprecated. [Ref: TG-20673]

    • CLI: The syntax for --mock, --mock-static, --mock-construction, and --exclude has changed - multiple values must be provided as a comma-separated list. This command line change may also impact your argument files, scripts, pipelines, etc. [Ref: TG-19173]

    Resolved Issues

    • Reports: Resolved a minor navigation issue in Cover Reports which required a double-click to select the Map tab. [Ref: TG-20867]

    • CLI: Resolved an issue which, under some circumstances, caused Cover CLI to fail with E011: Failed to run a simple example test when Cover Optimize is enabled. [Ref: TG-20505]

    • Cover: Resolved an issue which under some circumstances caused Diffblue Cover to write tests for modules that only contain test code. [Ref: TG-20443]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Diffblue Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2024-01-02

    In this release, Diffblue Cover is now available as a project integration within GitLab (Cover Pipeline for GitLab) and Cover now provides support for Kotlin projects. Also, Telemetry configuration has been updated and Cover Plugin now provides test maintenance options to simplify updating or removing Diffblue tests. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Pipeline: Diffblue Cover is now available as a project integration directly within GitLab (Cover Pipeline for GitLab) - see here. [Ref: TG-20676]

    • Cover: Diffblue Cover now provides improved test writing capabilities for methods which use anyMatch(). [Ref: TG-20646]

    • Plugin: Teams and Enterprise users can now easily raise a Diffblue support request via a button which has been added to the Cover Plugin Tool window. [Ref: TG-20626]

    • Cover: Telemetry is now enabled by default. It can be configured using environment variables and/or a telemetry.properties file on the client machine (where Diffblue Cover is being used). [Ref: TG-20596]

    • CLI & Reports: When generating or uploading reports bundles, if the --name argument is omitted, the name will now default to the latest commit hash when used within Git. [Ref: TG-20594]

    • Plugin: In Cover Plugin, you can now update existing tests for methods and classes from the test source files. Associated gutter icons and menu options have been added. [Ref: TG-20404]

    • Cover: Diffblue Cover can now write Java unit tests for Kotlin projects. [Ref: TG-19066]

    Resolved Issues

    • Reduce Flaky F009 due to concurrent modification exception [Ref: TG-20446]

    • Refactor: Resolved an issue which in some circumstances caused Cover Refactor to not use its recommended dependency versions during refactoring. [Ref: TG-19896]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2023-06-01

    This release enhances the utilization of mocks for more efficient test writing, improves compatibility checks, and provides Gradle project support in Cover Refactor. See the full Release Notes below for details.

    Enhancements

    • Cover: Diffblue Cover now attempts to write tests which utilize mocks in the arrange section instead of writing lengthy arrange sections. This provides improvements in both efficiency and readability of the tests generated by Cover. [Ref: TG-19094]

    • CLI: Cover's environment checks now ensure that the specified junit-vintage-engine and JUnit versions are compatible. [Ref: TG-19170]

    • CLI: Cover Refactor now supports Gradle and Java 17 projects. See the documentation for usage information. [Ref: TG-18156]

    • Reports: Cover now removes the demo project once a reports bundle has been uploaded. [Ref: TG-19027]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to incorrectly report Java 17.x.x not supported by refactoring when executing dcover refactor on a project while using Java 17. [Ref: TG-19278]

    • CLI: Resolved an issue which caused Cover to incorrectly report the number of lines of code covered by the tests written during the run, leading to inaccurate logging on the console. [Ref: TG-19199]

    • CLI: Resolved an issue which, in some circumstances, caused Cover to incorrectly report R013

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2023-11-02

    In this release, Diffblue Cover now supports writing tests for Java 21 projects - Diffblue now supports LTS Java versions 8, 11, 17, and 21 in production use. Also, the release includes a significant update to the Cover Reports docs topics - https://docs.diffblue.com/features/cover-reports. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Cover: Diffblue Cover now supports writing tests for Java 21 projects. [Ref: TG-20304]

    • CLI: Cover CLI now provides enhanced remediation advice for E011 - Failed to run a simple example test. [Ref: TG-19852]

    • Cover: Diffblue Cover now provides improved coverage when writing tests which use double/long/float constant comparisons. [Ref: TG-18581]

    • Plugin: Cover Plugin now creates run configurations when writing skeleton tests. [Ref: TG-17083]

    Resolved Issues

    • Cover: Diffblue Cover now provides improved formatting for Javadoc comments when writing tests. [Ref: TG-20292]

    • Cover: Resolved an issue which caused Diffblue Cover to not write tests for inner classes containing a dollar sign, when executing a run configuration. [Ref: TG-19819]

    • Plugin: Resolved an issue which caused Cover Plugin to hang if a run configuration was executed during project indexing. [Ref: TG-19708]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2022-09-02

    Results of ongoing efforts to speed up test writing with our IntelliJ

    Plug-in

    We are delighted to report the results of our ongoing efforts to accelerate the writing of tests. Thanks to incremental improvements over the last few releases, Cover today completes the 'write tests' stage 50% faster (on average against our internal benchmarks). Allowing our customers to write tests even faster.

    {: width="250" height="128"}

    Removal of on-disk index writing

    In our constant quest for speed, we have optimized away the need for producing an on-disk index when writing tests. This results in a further time saving on test writing equivalent to 1 second per module.

    Streamlined console output

    Harnessing the enhanced log file functionality released previously (in 2022.09.01) we have taken the opportunity to reduce the amount of non-actionable information reported in the CLI console and tool panel. This results in clearer, more targeted output allowing users to produce tests even more efficiently.

    Full information continues to be written to the support log files should detailed analysis be required.

    Full what's new information available from within the IntelliJ plug-in

    Convenient access to the full 'What's New' and release notes has been added to the IntelliJ plug-in menu, allowing you to keep informed of new features and enhancements as we continue to add them.

    {: width="162" height="203"}

    Meet the Diffblue team at Devoxx in October

    Diffblue are delighted to be sponsoring {: target="_blank" rel="noopener"} Our team can't wait to talk about AI for Code with the Java development community.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • Cover now writes tests for Spring Controller methods with @RequestBody Map<> arguments. [Ref: TG-17068]

    • CLI: Cover's deprecated dcover clean --failing subcommand has been removed and dcover validate should be used instead. [Ref: TG-17790]

    • CLI: Cover now provides a 'duration' at the end of execution. Timestamp prefixes have been removed from console output. [Ref: TG-17714]

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to report R013 while writing tests for methods which inherit annotations. [Ref: TG-17686]

    • Resolved an issue which prevented Cover creating Map implementation inputs that meet constraints outside of the class under test. [Ref: TG-17212]

    2023-10-01

    In this release, Diffblue Cover will now write tests and provide community support for non-LTS Java versions (9, 10, 12-16) - note that Diffblue only supports LTS versions 8,11, and 17 in production use. Also, the release includes an update to Cover Plugin changing the default name of test classes from ${CLASS_NAME}Test to ${CLASS_NAME}DiffblueTest. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Reports: Cover Reports now has a simplified docker build to remove redundant components. To update Cover Reports, see the . [Ref: TG-19467]

    • Pipeline: Cover Pipeline now enables the Cover CLI --batch option by default when the environment variable CI=true is set. [Ref: TG-20088]

    • Plugin: By default, tests written by Cover Plugin will now be suffixed with *DiffblueTest. [Ref: TG-20060]

    • Cover: Diffblue Cover can now write tests using the BigDecimal(String) constructor which improves assertions. [Ref: TG-20006]

    • Plugin: UI improvement. Cover Plugin now provides a Cancel button during test creation. [Ref: TG-19795]

    • Cover: Diffblue Cover now attempts to write tests for non-LTS Java versions (9, 10, 12-16) if strict mode is not used. [Ref: TG-19761]

    • Cover: Diffblue Cover no longer writes tests for Java 17 auto-generated Record methods. [Ref: TG-18143]

    Resolved Issues

    • Reports: Resolved an issue which in some circumstances caused Cover Reports to incorrectly display links in the Safari browser. [Ref: TG-19835]

    • Plugin: Resolved an issue where Cover Plugin run configuration templates were not retained. [Ref: TG-19749]

    Known Issues

    • Plugin: Cover Plugin incorrectly gives the option to write tests for a test file using the menu option, while in the IDE editor. [Ref: TG-17163]

    • Cover: Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Cover: Diffblue Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    2022-07-01

    Tests for Spring Controllers with session attributes

    Diffblue Cover now writes tests for Spring Controllers with session attributes, for both the CLI and the IntelliJ plugin. For example:

    2025-09-01

    This release enhances support for key Java frameworks including Spring, JUnit 5, and Mockito. Test readability is also improved with better method inlining for fluent builders, and the command-line interface benefits from significant performance gains.


    Framework & Library Support

    • Enhanced Spring Support: Cover now provides improved support for Spring projects that rely on XML-based context configurations.

    2023-05-02

    Tests for methods using ZonedDateTime

    Diffblue Cover is now able to use more aggressive mocking techniques to mitigate issues caused by unsatisfied external dependencies. Such external dependencies can include specific environments, files or network services. As of this release, Cover utilizes better algorithms and techniques to handle such cases more effectively by avoiding execution of the problematic code.

    Given the following code:

    Cover is now able to write a valid test:

    2023-02-02

    Diffblue Cover extends the types of custom inputs that can be specified in DiffblueRules.yml

    Diffblue Cover can now use values specified via immediate constant values supporting single- or multi-dimensional arrays.

    For example, the following configuration specifies a single unconditional default rule for String[] and String[][]:

    In addition to general purpose factory methods, it's also common to provide classes in the

    2022-08-05

    Harmonized directory handling options

    Deploying Cover is now even easier thanks to improvements to the command line options -–target-directory and -–working-directory. A new simplified workflow allows both types of functionality to be driven from a single option, --working-directory. This change reduces script maintenance overhead for our customers and improves command line readability.

    Further details available here: {: target="_blank" rel="noopener"}

    2022-03-01

    More plugin tests!

    This release, we have updated the Diffblue Cover IntelliJ plugin to include partial tests by default, resulting in more tests written. We have switched on the option of writing tests for enum values by default, too. We have also added a summary panel so you can easily see how many complete and partial tests have been written: {: width="735" height="306"} As shown in this image, you can click on Change Settings if you should want to turn off either of these new default options.

    2022-12-01

    IntelliJ IDEA 2022.3 support

    Diffblue Cover now supports IntelliJ IDEA 2022.3 (Community and Ultimate). In keeping with our policy of supporting the current and previous release, Diffblue Cover now supports IntelliJ IDEA 2022.3 and 2022.2. Support for IntelliJ IDEA 2022.1 has been removed as of Diffblue Cover 2022.12.01.

    2022-09-01

    Enhanced log files for efficient technical support

    Efficient support for all types of technical issues, user queries and errors is now facilitated with our dedicated support log file system.

    We have separated log files into two specific flavors: User log files contain details necessary to understand and remedy common configuration and build issues; Support log files contain extra debug information, which will enable our technical support team to more efficiently respond to queries.

    {: width="330" height="243"}

    Our user logs are clearer and thorough, making it easy to find the answer you need.

      /**
      * Method under test: {@link Time#addAnHour(ZonedDateTime)}
      */
      @Test
      public void testAddAnHour() {
        // Arrange
        Time time = new Time(LocalDate.of(1970, 1, 1).atStartOfDay().atZone(ZoneOffset.UTC));
        LocalDate ofResult = LocalDate.of(1970, 1, 1);
    
        // Act
        ZonedDateTime actualAddAnHourResult = time.addAnHour(ofResult.atStartOfDay().atZone(ZoneOffset.UTC));
    
        // Assert
        assertEquals("Z", actualAddAnHourResult.getZone().toString());
        LocalDateTime toLocalDateTimeResult = actualAddAnHourResult.toLocalDateTime();
        LocalDate toLocalDateResult = toLocalDateTimeResult.toLocalDate();
        assertSame(ofResult, toLocalDateResult);
        assertEquals("1970-01-01", toLocalDateResult.toString());
        assertEquals("01:00", toLocalDateTimeResult.toLocalTime().toString());
      }
    @ManagedByDiffblue
    annotation.
    • Action Required for DiffblueBuild.yaml: To ensure correct coverage reporting, users with a DiffblueBuild.yaml file from before release 2025.06.02 must manually update it. Replace all instances of "MaintainedByDiffblue" with "MaintainedByDiffblue,ContributionFromDiffblue" and set the file version to 2.1.

    Diffblue Cover now annotates setup and teardown methods it generates with @ManagedByDiffblue. This allows Diffblue Cover to modify or delete these methods in subsequent runs, providing greater flexibility. Requires cover-annotations v1.4.0 or higher. [Ref: TG-23045]

  • Diffblue Cover now annotates new tests with @ManagedByDiffblue and @Tag("ContributionFromDiffblue") when using cover-annotations v1.4.0 or higher, providing clearer attribution and aligning with current best practices for test management. [Ref: TG-23031]

  • Diffblue Cover now better determines appropriate return values for mocks, resulting in more generated tests. This enhances coverage in scenarios where objects are difficult to instantiate, leading to more comprehensive test suites. [Ref: TG-22643]

  • Resolved an issue where manual TestNG tests could fail when placed in the same file as tests written by Diffblue Cover. This was caused by setup and teardown methods not being correctly applied to manual tests, which is now fixed. [Ref: TG-23348]

  • Resolved an issue that prevented Diffblue Cover from writing tests for code on Java 9+ due to Java module system restrictions. It now correctly handles field accessibility, increasing test generation for affected code, such as that using character sets. [Ref: TG-23338]

  • Resolved an issue where Cover would improperly handle enclosing class types, which prevented test generation for non-static inner classes extending from a generic superclass. [Ref: TG-23324]

  • Resolved an issue where Diffblue Cover would produce an F009 internal error when analyzing code with certain enclosing types. Diffblue Cover now correctly handles these structures, successfully generating tests in cases where it previously failed. [Ref: TG-23316]

  • Plugin: Resolved an issue where Diffblue Cover would fail with an F009 internal error for default interface methods. It now correctly identifies when no implementation is available and reports a T009, providing clearer feedback to the user. [Ref: TG-23309]

  • Resolved an issue that could prevent test generation in rare situations involving mocking a Collection, resulting in an F009 error. Diffblue Cover is now able to proceed with test creation in these cases, unblocking test writing for the affected methods. [Ref: TG-23308]

  • Resolved an issue that prevented Diffblue Cover from writing tests for Spring Controller methods returning UNAUTHORIZED or INTERNAL_SERVER_ERROR statuses. Diffblue Cover now successfully generates tests for these HTTP response status codes. [Ref: TG-23307]

  • Resolved an issue where Diffblue Cover would incorrectly process @InTestsMock annotations that forbid mocking. This ensures the annotation's behavior is consistent and predictable when guiding test generation. [Ref: TG-23175]

  • Plugin: Resolved an issue where Diffblue Cover could cause the IntelliJ IDE to become unresponsive when opening or switching between files. The update process for gutter icons has been optimized, resulting in significantly improved IDE performance. [Ref: TG-23170]

  • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]
  • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

  • CLI: Diffblue Cover now allows customization of the maximum number of assertions it includes in each generated test. This feature is accessible through the new --max-assertions-per-test option or DIFFBLUE_MAX_ASSERTIONS_PER_TEST environment variable. [Ref: TG-22946]

  • CLI: Diffblue Cover now enables listing all project modules when dcover list-modules is run. This is useful for managing multi-module operations, especially for restarting a cancelled process from a designated module. [Ref: TG-22838]

  • CLI: Diffblue Cover now orders test class annotations alphabetically, which means annotation ordering is now always consistent. This change will cause one-time churn where annotations were previously not alphabetically sorted. [Ref: TG-22760]

  • Plugin: Cover now supports IntelliJ IDEA 2025.1 (Community and Ultimate editions). Support for 2024.2 has been removed. [Ref: TG-22575]

  • CLI & Plugin: Diffblue Cover now more accurately determines type arguments for Optional objects in user code. This leads to improved test quality, coverage, and reliability for methods handling Optional inputs. [Ref: TG-17587]

  • CLI & Plugin: Resolved an issue affecting the discovery of @InTestsUse... annotations (e.g., @InTestsUseIntegers) on Spring Controller methods. Tests produced by Cover will now reflect parameters defined in these annotations. [Ref: TG-22710]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

  • Diffblue Cover now generates tests for methods containing catch blocks for unchecked exceptions. To trigger these error-handling paths, Diffblue Cover creates tests with mocked calls that are configured to throw the appropriate exceptions. [Ref: TG-23043]

  • Diffblue Cover now gives higher priority to creating mocks when guided by the @InTestMock annotation with MockDecision.RECOMMENDED. This also applies when no decision is specified, as RECOMMENDED is the default, making annotation-based mocking more predictable. [Ref: TG-22843]

  • Resolved an issue that could cause Diffblue Cover to fail with an F009 internal error when encountering a malformed exception during test generation. Cover now handles this situation gracefully, unblocking test creation for the affected code. [Ref: TG-23277]

  • Resolved an issue where Diffblue Cover would incorrectly discard tests involving exceptions from a superclass. Tests for methods that call superclass methods which throw exceptions are now correctly generated and asserted. [Ref: TG-22657]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

  • @ManagedByDiffblue
    annotation.
    • Action Required for DiffblueBuild.yaml: To ensure correct coverage reporting, users with a DiffblueBuild.yaml file from before release 2025.06.02 must manually update it. Replace all instances of "MaintainedByDiffblue" with "MaintainedByDiffblue,ContributionFromDiffblue" and set the file version to 2.1.

    Diffblue Cover now annotates setup and teardown methods it generates with @ManagedByDiffblue. This allows Diffblue Cover to modify or delete these methods in subsequent runs, providing greater flexibility. Requires cover-annotations v1.4.0 or higher. [Ref: TG-23045]

  • Diffblue Cover now annotates new tests with @ManagedByDiffblue and @Tag("ContributionFromDiffblue") when using cover-annotations v1.4.0 or higher, providing clearer attribution and aligning with current best practices for test management. [Ref: TG-23031]

  • Diffblue Cover now better determines appropriate return values for mocks, resulting in more generated tests. This enhances coverage in scenarios where objects are difficult to instantiate, leading to more comprehensive test suites. [Ref: TG-22643]

  • Resolved an issue that prevented Diffblue Cover from writing tests for code on Java 9+ due to Java module system restrictions. It now correctly handles field accessibility, increasing test generation for affected code, such as that using character sets. [Ref: TG-23338]
  • Resolved an issue where Cover would improperly handle enclosing class types, which prevented test generation for non-static inner classes extending from a generic superclass. [Ref: TG-23324]

  • Resolved an issue where Diffblue Cover would produce an F009 internal error when analyzing code with certain enclosing types. Diffblue Cover now correctly handles these structures, successfully generating tests in cases where it previously failed. [Ref: TG-23316]

  • Plugin: Resolved an issue where Diffblue Cover would fail with an F009 internal error for default interface methods. It now correctly identifies when no implementation is available and reports a T009, providing clearer feedback to the user. [Ref: TG-23309]

  • Resolved an issue that could prevent test generation in rare situations involving mocking a Collection, resulting in an F009 error. Diffblue Cover is now able to proceed with test creation in these cases, unblocking test writing for the affected methods. [Ref: TG-23308]

  • Resolved an issue that prevented Diffblue Cover from writing tests for Spring Controller methods returning UNAUTHORIZED or INTERNAL_SERVER_ERROR statuses. Diffblue Cover now successfully generates tests for these HTTP response status codes. [Ref: TG-23307]

  • Resolved an issue where Diffblue Cover would incorrectly process @InTestsMock annotations that forbid mocking. This ensures the annotation's behavior is consistent and predictable when guiding test generation. [Ref: TG-23175]

  • Plugin: Resolved an issue where Diffblue Cover could cause the IntelliJ IDE to become unresponsive when opening or switching between files. The update process for gutter icons has been optimized, resulting in significantly improved IDE performance. [Ref: TG-23170]

  • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]
  • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

  • annotation.
    • Action Required for DiffblueBuild.yaml: To ensure correct coverage reporting, users with a DiffblueBuild.yaml file from before release 2025.06.02 must manually update it. Replace all instances of "MaintainedByDiffblue" with "MaintainedByDiffblue,ContributionFromDiffblue" and set the file version to 2.1.

    Diffblue Cover now allows specifying a factory for creating custom object return values in mocks, using the new returnValueFactory field in the @InTestsMock annotation. [Ref: TG-22955]
  • Plugin: Diffblue Cover can now be installed on IntelliJ IDEA Community Edition 2025.2 EAP and IntelliJ IDEA Ultimate 2025.2 EAP. This support is currently in preview mode. [Ref: TG-22566]

  • Resolved an issue that caused Diffblue Cover to report an F009 (Internal Error) when encountering corrupt files, such as broken .jar archives, on the classpath. [Ref: TG-23263]

  • Plugin: Resolved an issue causing the IntelliJ UI to become unresponsive when writing tests for large scopes. Test preparation is now an optimized background task, ensuring the UI remains interactive and test generation starts faster. [Ref: TG-23012]

  • Resolved an issue where Diffblue Cover would incorrectly report E054 (No class files found) for modules without source files. It now reports E129 (No source files found) to reduce confusion and improve diagnostics. [Ref: TG-21053]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

  • Diffblue Cover now issues a warning message if the configured test output directory is not src/test/java. This helps users identify potential misconfigurations before tests are created. [Ref: TG-23101]
  • Diffblue Cover now provides new attributes for the @InTestsMock annotation, enabling users to specify return values for methods in mocked classes. This allows Diffblue Cover to generate tests with more domain-specific mock behaviors. [Ref: TG-23049]

  • Diffblue Cover now writes tests with improved consideration for the isPresent status of java.util.Optional objects. This leads to better test generation and coverage for code involving Optionals. [Ref: TG-22868]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • In some circumstances, Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title "Tests for review" can be malformed. [Ref: TG-22805]

  • Cover does not currently support Java 24. Please switch your JDK version to 21 or lower. [Ref: TG-22920]

  • Cleaner Console Output: Resolved an issue that caused unnecessary console messages about synthetic or generated methods, resulting in a less verbose output from the CLI.

  • For enterprise deployments, Cover Reports can now track command line and plugin usage. Enable this feature by setting the telemetry.collect.username property in the telemetry.properties file to record the user's git identity. [Ref: TG-23916]

  • Diffblue Cover now writes tests compatible with JUnit 6 for projects using Java 17 and higher. For projects on Java versions 8 through 16, Diffblue Cover continues to generate tests using the JUnit 5 framework. [Ref: TG-23826]

  • CLI: Diffblue Cover now uses less memory when writing tests. The memory footprint remains stable throughout the test generation process, regardless of run duration or the number of tests created, improving performance and stability for large projects. [Ref: TG-23717]

  • Plugin: The Diffblue Cover IntelliJ plugin is now compatible with the IntelliJ 2025.3 Early Access Program (EAP), allowing unit test generation within the newest pre-release versions of the IDE. [Ref: TG-22571]

  • Reports: The total line count metric in Reports only includes Java code. Kotlin code is not included. [Ref: TG-22088]

  • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

  • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

  • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

  • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

  • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

  • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

  • When test formatting settings are changed, the Test Review feature may incorrectly remove the @ManagedByDiffblue annotation from tests, particularly in cases involving static import formatting changes. [Ref: TG-23750]

  • Plugin: Using the Test Review feature may create tests that have incompatible dependency injection systems. [Ref: TG-23935]

  • Cover: If Dependency Injection libraries change between runs, Cover may select the DI system from a previously-generated test instead of a more suitable DI system now available on the classpath. [Ref: TG-24021]

  • IntelliJ Plugin: Cover is now able to fix E086 (Specified test framework not available), on demand, via the 'Project Environment Health Check' panel. [Ref: TG-18462]

  • IntelliJ Plugin: Cover's 'Fix issue' prompts, to automatically fix common project configuration problems, has now been moved to the 'Project Environment Health Check' panel. [Ref: TG-18449]

  • Resolved an issue which caused Cover to not report E052 (Missing dependency) when Spring Test or Spring Boot Test dependencies are required but missing. [Ref: TG-18046]

  • Resolved an issue which caused JSON serialization issues to be reported as R024. These are now reported as F020 (Failed to parse internal json message). [Ref: TG-17210]

  • CLI: Resolved an issue which caused Cover to recommend using dcover create when encountering an E005 (Parent module without classes) even if the E005 was encountered with a different subcommand. [Ref: TG-18702]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]
  • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

  • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Plugin: Under some circumstances, when writing tests at a Class level, Cover will delete an existing getter test. [Ref: TG-20611]

  • Plugin: Under some circumstances, when writing Java tests for Kotlin code, Cover may produce non-compiling tests. [Ref: TG-20759]

  • Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    Updated JUnit 5 Support: Cover now supports writing tests using the JUnit Jupiter 5.13.4 API. This allows you to generate tests for projects that use this newer version of the framework.

  • Updated Mockito 5 Support: Cover now supports Mockito Core 5.19.0, ensuring that Cover can generate tests for projects that depend on this newer version of the mocking framework.

  • Improved Test Readability

    • Improved Method Inlining: Cover now generates more readable tests by improving how it inlines method calls, especially for fluent-style builders. Please be aware that existing tests using these patterns may be updated to reflect this improvement.

    CLI Enhancements

    • Improved Performance: The list-modules and upload CLI commands now have significantly improved performance, resulting in faster project analysis and interaction.


    Important Notices

    Action Required

    • Action Required for users of DiffblueBuild.yaml: As announced in 2025.08.02's release notes, a breaking change is now in effect for DiffblueBuild.yaml to enable a faster upload command. To ensure compatibility, projects with an existing DiffblueBuild.yaml file must be manually updated to add a new classpath phase. Please see our documentation for detailed instructions.


    Enhancements

    • Diffblue Cover now supports and recommends JUnit Jupiter API version 5.13.4, ensuring compatibility for writing tests against projects using this newer version of the JUnit 5 testing framework. [Ref: TG-23719]

    • Diffblue Cover now supports Mockito Core version 5.19.0. This update allows Diffblue Cover to write tests for projects using the latest features of this mocking framework, ensuring continued compatibility. [Ref: TG-23718]

    • CLI: Diffblue Cover now reports a specific error (E097) instead of a generic internal error (F009) when an https URL is incorrectly used to connect to a non-SSL Cover Reports server, providing more precise feedback for troubleshooting. [Ref: TG-23707]

    • Diffblue Cover now provides improved support for Spring Boot XML context configurations, especially in conjunction with @MockBean. This allows Diffblue Cover to write more comprehensive unit tests for Spring Boot projects that rely on XML-based configuration. [Ref: TG-23495]

    • CLI: Diffblue Cover now executes the list-modules and upload CLI commands significantly faster by optimizing how the project's classpath is processed. [Ref: TG-22625]

    • Diffblue Cover now has improved inlining logic for fluent-style method calls, particularly for builder patterns. This results in higher quality, more readable tests. Note that existing tests for these patterns will be updated. [Ref: TG-20259]

    Resolved Issues

    • Resolved an issue that prevented Diffblue Cover from writing tests for certain Spring Controllers. Diffblue Cover now correctly uses a fully configured Jackson ObjectMapper, rather than creating a default instance. [Ref: TG-23713]

    • Resolved an issue that could prevent test creation when generating mocks for code with optional dependencies. Diffblue Cover now more reliably writes tests for methods that reference classes not present on the classpath, improving overall test generation. [Ref: TG-23686]

    Known Issues

    • Plugin: Diffblue Cover incorrectly displays a menu option to write tests for existing test files. [Ref: TG-17163]

    • Cover supports Open JDK and Oracle JDK; results with other JDKs may differ due to the variability in their implementations of Java. [Ref: TG-19345]

    • Cover may encounter an F009 (Internal error) caused by a ClassCircularityError involving org/mockito/configuration/MockitoConfiguration when writing tests with Mockito 5. To avoid this, use an earlier version of Mockito. Downgrading to Mockito 4.x is the recommended workaround. [Ref: TG-19610]

    • Reports: Cover only counts Java code towards the total line count metrics. Kotlin code is not currently included. [Ref: TG-22088]

    • Reports: Total lines of code metric can incorrectly count a multi-line comment at the end of a line of code, resulting in fewer than expected lines counted. [Ref: TG-22089]

    • Reports: Following an upgrade, the 'Total Lines of Code' card may show 0 until a new reports bundle has been uploaded. [Ref: TG-22094]

    • Cover may write more simplistic tests with less meaningful assertions when Spring Boot dependency injection is disabled. [Ref: TG-22102]

    • In some circumstances, Cover will still write Spring Boot tests when Spring Boot dependency injection is disabled. [Ref: TG-22103]

    • Cover may write failing TestNG tests when Spring Boot dependency injection is disabled. [Ref: TG-22107]

    • Plugin: On some displays, the Test Review subsection title 'Tests for review' is malformed. [Ref: TG-22805]

    • Diffblue Cover does not currently support test creation for projects using Java 24; please use JDK 21 or lower. [Ref: TG-22920]

    Docs
    Docs
    Docs
    Docs
    IntelliJ Plugin: Resolved an issue which caused Cover to silently fail after clicking 'fix all issues' after renaming a module. [Ref: TG-18992]
  • Resolved an issue which, in some circumstances, caused Cover to not write tests for code using JwsHeader class. [Ref: TG-19018]

  • Resolved an issue which, in some circumstances, caused Cover to write failing tests containing .getClassLoader(). [Ref: TG-18998]

  • Resolved an issue which caused Cover to not write tests because of Spring beans with primitive type names. [Ref: TG-18628]

  • Diffblue's Licensing Service Status page

    IntelliJ Plugin: Resolved an issue which caused Cover to report errors while attempting to write tests on packages above the main package. [Ref: TG-18807]

  • IntelliJ Plugin: Resolved an issue which caused Cover to select a suboptimal working directory (such as src/main) when writing tests for Gradle projects. [Ref: TG-18102]

  • Reports: Resolved an issue which caused Cover to not update project group pages when new data was uploaded. [Ref: TG-17927]

  • Authenticating Cover Reports Uploads documentation
    (No inputs found that don't throw a trivial exception) instead of
    R011
    (Sandboxing policy violation). [Ref: TG-18733]
  • Reports: Resolved an issue which caused Cover Reports to display Application error: a client-side exception has occurred [...] when navigating to the URL of a deleted project. [Ref: TG-19296]

  • Reports: Resolved an issue which, in some circumstances, caused Cover to provide an inaccurate count of lines of code which are not covered by tests. [Ref: TG-19277]

  • Reports: Resolved an issue which, when using older versions of JaCoCo (< 0.8.7), caused Cover to report an inaccurate test count. Upgrade to 2023.06.01 and upload a new reports bundle to correct any previously inaccurate counts. [Ref: TG-19193]

  • Cover Refactor: Getting Started

    Cover: Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

  • Plugin: Cover Plugin may display tests links which do not work when writing tests for multiple methods at once. To avoid this, write tests at the class level or for a single method. [Ref: TG-20050]

  • Plugin: Cover Plugin will get stuck during the 'Preparing' phase if the run configurations created by the plugin are used. To avoid this issue, do not use the run configurations created by the plugin. [Ref: TG-20061]

  • Update Cover Documentation

    Cover now provides a stack trace when it encounters R081 (Exception in arrange section) to help identify the reason tests could not be written. [Ref: TG-18734]

    Resolved an issue which caused Cover to report Internal error when executing a test, ignoring and continuing when temporary files were not deleted. [Ref: TG-18779]
  • Resolved an issue which, in some circumstances, caused Cover to report Missing Spring component. Cover now looks in more locations for an XML configuration to use in Spring tests. [Ref: TG-18731]

  • IntelliJ Plugin: Resolved an issue which caused Cover to write tests at the source language level rather than the bytecode version level specified in the project. [Ref: TG-18530]

  • Resolved an issue which caused Cover to not report an error if the version of Gradle is not compatible with the version of Java, i.e. Gradle 7.3 or higher is needed on Java 17 projects and Gradle 5.0 or higher is needed on Java 11 projects. [Ref: TG-16879]

  • CLI: Resolved an issue which caused Cover to write the user log file to different locations depending on command being run. [Ref: TG-16827]

  • Preflight check capability
    Diffblue Cover Reports
    Preflight checks documentation
    src/test/java
    source tree with factory methods for use specifically in tests. In the following example a factory method is used to provide an array of ISBN instances for use where an array of ISBN objects is required:

    For more information check out Customizing test inputs

    Enhancements

    • CLI: Cover now outputs a list of tests which failed during test validation to the console and log file. [Ref: TG-18369]

    • Cover now allows immediate values for array literals to be specified in DiffblueRules.yml. See the 'Customizing test inputs' documentation for more details. [Ref: TG-18619]

    • Cover now allows factory methods which produce arrays to be specified in DiffblueRules.yml. See the 'Customizing test inputs' documentation for more details. [Ref: TG-18595]

    • Cover now uses better inputs for Map objects whilst writing tests. [Ref: TG-18420]

    Resolved Issues

    • Resolved an issue which caused Cover to not provide a warning when JDK 8u251 or earlier was in use. The minimum supported version is now JDK 8u261. [Ref: TG-18670]

    • Resolved an issue which, in some circumstances, caused Cover to report R083 (Can't find a suitable constructor) while writing tests for trivial methods when a factory method is available. [Ref: TG-18594]

    • Resolved an issue which caused Cover to incorrectly report E066 (Dependency incompatible with JDK) when Spring dependencies are mismatched. [Ref: TG-18519]

    • IntelliJ Plugin: Resolved an issue which caused Cover to silently fail, after clicking 'fix all issues', when project environment health check issues were detected in projects which are unable to be fixed. [Ref: TG-18615]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading the Coverage Reports tab. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

      INFO  Environment summary:
      INFO  --------------------
      INFO  Java version                  17.0.5              SUCCESS
      INFO  Build system                  Gradle              SUCCESS
      INFO  Mocking Framework             Mockito 4.5.1       SUCCESS
      INFO  Testing framework             JUnit Jupiter 5     SUCCESS
      INFO  Hamcrest                      Hamcrest 2 2.2      SUCCESS
      INFO  Spring Core                   5.3.21              SUCCESS
      INFO  Spring Boot                   2.7.1               SUCCESS
      INFO  Spring Boot Test              2.7.1               SUCCESS
      INFO  Spring Web                    5.3.21              SUCCESS
      INFO  Spring Test                   5.3.21              SUCCESS
      WARN  Test execution                                    WARNING
      INFO
      WARN  Environment check status: WARNING
      INFO  Running existing tests, this can take a few minutes.
      WARN  E035: Running existing tests failed
      WARN  Diffblue Cover tried to run the command "gradle test", but it failed.
      WARN  The output from running this command is available towards the end of the log
      WARN  file. While Diffblue Cover could not figure out the reason for this and cannot
      WARN  fix it automatically, this issue is usually due to an incorrect command, or due
      WARN  to the failure of existing, user-provided tests.
      java.lang.String[]:
        - immediate: [ "Hello", "World!" ]
        - immediate: # this rule uses different syntax for the same rule as above
          - "Hello"
          - "World!"
    
      java.lang.String[][]:
        - immediate: [ [ "Multidimension", "arrays" ], [ "are", "also", "supported" ] ]
        - immediate: # this rule uses different syntax for the same rule as above
          - [ "Multidimension", "arrays" ]
          - [ "are", "also", "supported" ]
        - immediate: # this rule uses another syntax variation for the same rule
          - - "Multidimension"
            - "arrays"
          - - "are"
            - "also"
            - "supported"
      com.example.library.ISBN[]:
        - factory:
            method: com.example.library.ISBNTestSupport.isbnArrayForTesting:()[Lcom/example/library/ISBN;
    IntelliJ Plugin: Cover now spends less time indexing on Java 11 and Java 17 projects. [Ref: TG-15538]
  • CLI: Cover now allows environment values to be specified via the --environment option. [Ref: TG-17472]

  • CLI: Cover now supports Mockito static mocking via the --mock-static option. This feature enables the mocking of the static methods of the specified classes in created tests using Mockito.mockStatic. Requires Mockito 3.4.0 and above. [Ref: TG-17399]

  • CLI: Cover now outputs more precise recommendations when JUnit dependencies are missing, mismatched or unsupported. [Ref: TG-17230]

  • Cover now writes tests, when mocks need to be used, where it previously may have failed with an R002 (Missing observers). [Ref: TG-16610]

  • CLI: Resolved an issue which, in some circumstances, Cover would encounter a StackOverflowError. [Ref: TG-17519]

  • Resolved an issue which, in some circumstances, caused Cover to write tests containing many calls to copy constructors. [Ref: TG-17520]

  • Resolved an issue which caused Cover to not track Generic Type Arguments when choosing factories. [Ref: TG-17478]

  • Resolved an issue which caused Cover to provide type parameters to outer classes of non-static inner classes. [Ref: TG-17465]

  • https://docs.diffblue.com/knowledge-base/cli/mock-static
    https://docs.diffblue.com/knowledge-base/cli/cli-manual/#environment
    click here
    here
    this video

    Cover now provides improved guidance if R013 (No inputs found that don't throw a trivial exception) is encountered whilst writing tests. [Ref: TG-17037]

  • IntelliJ Plugin: Cover now provides a 'Write Skeleton Tests' button. See the Skeleton Tests Documentation for more details. [Ref: TG-16581]

  • /knowledge-base/intellij/skeleton-tests/
    click here
    here
    this video

    Cover now includes a Javadoc which links to the methods it has written tests for. [Ref: TG-16584]

  • Cover now provides a warning if the version of Mockito on the classpath is not compatible with the chosen JVM. [Ref: TG-16464]

  • click here
    here
    this video
    See 'Custom Inputs' documentation.

    IntelliJ Plugin: Cover now shows 'what's new' updates in an IDE tab rather than a window overlay. [Ref: TG-17653]

    Devoxx Belgium 2022.
    click here
    here
    this video
    Tests for classes implementing the Builder pattern

    Diffblue Cover now recognises that build is a builder method, i.e. it creates a new object using the fields of the class to call a constructor and returns the result. This means that we can now write tests by calling the build method and asserting on its result.

    Coming soon!

    We are busy getting ready for IntelliJ 2022.2! More details when the new IntelliJ release is announced, please watch this space.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • CLI: Cover now detects testable methods faster. [Ref: TG-17337]

    • Cover now always includes MethodGroup failure reasons, if present, in the log file. [Ref: TG-17121]

    • Cover now provides improved guidance when an R012 (JNI sandbox policy violation) has been encountered. [Ref: TG-17100]

    • Cover now sets @SessionAttributes for Spring Controller tests when appropriate. [Ref: TG-17070]

    • Cover is now able to write tests for classes implementing the Builder pattern. [Ref: TG-13577]

    Resolved Issues

    • CLI: Resolved an issue which caused Cover to reject prefixes which end in a Java keyword. [Ref: TG-17358]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from root module with --working-directory. [Ref: TG-16876]

    Enhancements
    • Cover is now able to construct mock objects with deeper levels of nesting. Previously, where Cover couldn't have written tests because it was unable to mock such objects, R013 (No inputs found that don't throw a trivial exception) would've been reported. [Ref: TG-19023]

    • Cover now ensures that the Mockito version in use is not too high for the selected Java version. This is shown in the Project Environment Health Check panel in the IntelliJ plugin and is provided as a warning in the CLI. [Ref: TG-19020]

    • CLI: Cover now enforces a minimum Maven Surefire Plugin version of 2.19 when using JUnit 4 and Cover CLI's --coverage-reports option to upload reports bundles to Cover Reports. [Ref: TG-18783]

    • CLI: Cover's now ensure that JaCoCo has been configured correctly so that the --coverage-reports option can be used reliably. [Ref: TG-18660]

    • Cover is now better at detecting that a class is a Spring bean and should be tested using Spring dependency injection. [Ref: TG-19162]

    • Reports: Improved 'sizing option buttons' experience on the Project Map view. [Ref: TG-19177]

    • Reports: Cover now shows a filterable list of projects on the homepage, replacing the 'getting started' view, once a coverage reports bundle has been uploaded. This ensures accurate coverage data is reported to Cover Reports. [Ref: TG-19028]

    • Refactor: Cover now places getters with its corresponding setter, other getters or constructors instead of at the end of the file. See the documentation for more details. [Ref: TG-19119]

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to incorrectly mock the method under test. [Ref: TG-18971]

    • CLI: Resolved an issue which caused Cover to incorrectly report error detected while trying to execute tests despite the --skip-test-validation option being passed. Cover now reports disabled, at user's request. [Ref: TG-18421]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    Enhancements to Static Mocking

    Sandboxing is used by Diffblue Cover to run tests in a controlled environment in order to prevent inadvertent changes or damage to your system.

    Execution inside Diffblue Cover's sandboxing environment prohibits certain operations, e.g. making connections to external services. In order to write tests for classes these operations need to be mocked.

    Diffblue Cover now harnesses the power of static mocking to automatically mock methods that violate sandboxing restrictions, resulting in additional functional tests to further improve coverage of your code.

    Added support for Mockito versions

    We are pleased to bring to our customers support for all Mockito versions through to the recently released 4.7.0.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Cover now provides improved guidance when an R027 (Failed to create Spring context due to missing beans in the current Spring profile) has been encountered. [Ref: TG-17648]

    • Cover now supports Mockito 4.7.0. [Ref: TG-17614]

    • Cover now provides more detailed guidance to fix project test configuration issues which would prevent tests being written. [Ref: TG-17564]

    • CLI: Cover now provides more detailed remediation guidance if build system issues are detected. [Ref: TG-17547]

    • Cover now attempts to write tests which use static mocks where R011 (Sandboxing policy violation) would have previously been reported. [Ref: TG-17523]

    • CLI: Cover's CLI commands now produce their output relative to the working directory. The default target directory is working-directory/.diffblue. The --target-directory option has been removed and --working-directory should be used instead. [Ref: TG-17113]

    Resolved Issues

    • Resolved an issue which caused Cover to report R024 (Analysis service shutdown unexpectedly) for classes with complex mutually recursive private methods. [Ref: TG-17621]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    https://docs.diffblue.com/knowledge-base/troubleshooting/working-directory-update-release-2022-08-05/
    Suppressing SonarQube warnings

    SonarQube is a tool to enforce coding practices to help developers write better code. Some of its rules have the purpose to detect common mistakes; others purely concern specific aspects of coding style. Some of the latter rules are a matter of taste and usually need to be tailored to the coding guidelines of a specific project. Using all rules may lead to lots of noisy warnings, and sometimes such warnings are triggered on tests created by Diffblue Cover.

    This release, we have added the --annotate-suppress-warnings option, to reduce the warnings in the tests created by Diffblue Cover. Full details are in our documentation.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • IntelliJ Plugin: Cover now writes partial tests by default. Partial test writing can be configured via the Cover plugin settings. [Ref: TG-16578]

    • IntelliJ Plugin: Cover now provides a summary of tests written in the Diffblue Tool Panel. [Ref: TG-16577]

    • CLI: Cover now adds @SuppressWarning annotations to tests it writes when the --annotate-suppress-warnings CLI option is used. [Ref: TG-16611]

    • Cover now uses xml configuration for testing spring classes even if the spring-boot-test dependency is not present. [Ref: TG-16456]

    • CLI: Cover's test validation now supports projects that use the (Maven or Gradle) ignoreFailures feature. [Ref: TG-16104]

    Resolved Issues

    • Resolved an issue which caused Cover to not detect calls to System.currentTimeMillis() in methods under test, in some circumstances, causing non-deterministic tests to be written. [Ref: TG-16643]

    • Test validation output has been improved in the case where some tests have been cleaned up and test validation still fails. [Ref: TG-16633]

    • Resolved an issue which, in some circumstances, caused Cover to not write tests for classes containing an @Value annotated field. [Ref: TG-16613]

    • CLI: Resolved an issue which caused Cover to report Cleaning tests failed rather than logging output code E087: Multiple testing frameworks when multiple test frameworks are available. [Ref: TG-16585]

    • CLI: Fixed incorrect descriptions for --name and --project options in Cover's man page and online help. [Ref: TG-16573]

    • CLI: Resolved an issue which caused Cover to not log the number of tests written per class to the log file while using --verbose. [Ref: TG-15145]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    New Diffblue Cover features

    Four new features - Reports, Optimize, Refactor and Replay - have been added in this release of Diffblue Cover. In addition to autonomously writing and maintaining entire unit test suites without developer intervention, Cover Enterprise Edition now enables you to:

    • Automatically refactor Java code to improve testability

    • Slash the time and cost to run tests in Continuous Integration

    • Understand test coverage and code risk across your organization

    • Automatically shift complex functional tests left into unit test suites

    Read this blog post or watch this short YouTube playlist to learn more about the new features. Then if you're interested in how the power of Enterprise Edition could help your team, get in touch via our website.

    {: width="908" height="251"}

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • CLI: Cover now includes a summary table of environment checks in the user and support log files. [Ref: TG-18202]

    • Reports: Improved UI responsiveness and usability. [Ref: TG-18170]

    • IntelliJ Plugin: Cover now supports IntelliJ IDEA Community Edition 2022.3 and IntelliJ IDEA Ultimate 2022.3. [Ref: TG-18092]

    Resolved Issues

    • IntelliJ Plugin: Resolved an issue, which, in some circumstances, caused Cover to report License unavailable. Cause: java.lang.NoClassDefFoundError [...] rather than providing remediation advice. [Ref: TG-17770]

    • Resolved an issue which, in some circumstances, caused Cover to use unnecessary local variables in written tests. [Ref: TG-18215]

    • Resolved an issue which caused Cover to not write tests for methods that return objects which can only be observed indirectly. Cover now writes assertions using indirect observers when no getter is available. [Ref: TG-17589]

    • Resolved an issue which caused Cover to not write a partial Spring test when it cannot produce a complete Spring test. [Ref: TG-17394]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading Coverage Reports. [Ref: TG-18257]

    Environment issue resolution suggestions reported in console output

    Some issues in your project build and test framework can be hard to diagnose - resulting in slow builds, failing tests, or errors while running your project.

    Now you get helpful information about common build and test framework issues in the console output to resolve common set-up problems.

    {: width="1039" height="309"}

    Meet the Diffblue team at Devoxx in October

    Diffblue are delighted to be sponsoring Devoxx Belgium 2022.{: target="_blank" rel="noopener"} Our team can't wait to talk about AI for Code with the Java development community.

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please click here. Full information on all our options is also available here.

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch this video to learn more.

    Enhancements

    • Cover's logging is now separated into user-focused and support-focused files to improve readability. [Ref: TG-17716]

    • CLI: Cover now considers Maven wrappers and local Gradle installations correctly. [Ref: TG-17658]

    • CLI: Cover now provides improved output during environment checks. [Ref: TG-17562]

    Resolved Issues

    • Resolved an issue which caused Cover to log an E004 as an Error, rather than a Warning, when a patch file which does not modify any classes, or an empty patch file, is used with --patch-only. [Ref: TG-17711]

    • Resolved an issue which, in some circumstances, caused Cover to not write tests because of @Value annotated arrays. [Ref: TG-17698]

    • Resolved an issue which caused Cover to incorrectly mock functional interfaces in Spring integration tests. [Ref: TG-17689]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    Partial Tests documentation

    2023-01-02

    Automatically find and resolve project dependency issues in the IntelliJ Plugin

    To get the best results from the Diffblue Cover IntelliJ Plugin we check that you have compatible versions of dependencies. Until now you have had to manually adjust your Maven/Gradle configuration to do this. In Diffblue Cover 2023.01.02 we provide a link to fix all issues which will add required dependencies as necessary to get the best results from Diffblue Cover.

    {: width="1170" height="376"}

    Validate your project is ready to run Diffblue Cover CLI

    Much like the Diffblue Cover IntelliJ Plugin, to get the best results from Diffblue in the shortest time possible it is important that your project is structured in the best way and with supported versions of dependencies. In this release, we introduce the unlicensed --preflight option which allows you to ensure that your project is ready for Diffblue Cover. Use preflight to find common problems in Maven/Gradle project structures as well as checking that the dependencies in your project are compatible.

    Enhancements

    • CLI: The create command now has a --preflight option to run the project environment checks without creating tests. [Ref: TG-18507]

    • Cover now supports JUnit 5.9.2. [Ref: TG-18270]

    • Cover now supports Mockito 4.11.0. [Ref: TG-18271]

    Resolved Issues

    • Resolved an issue where telemetry settings can get corrupted. [Ref: TG-18487]

    • Resolved an issue which could cause Cover to stop creating tests due to F009 Internal error with the message IllegalArgumentException: toClassType cannot be called on a type variable. [Ref: TG-18477]

    • IntelliJ Plugin: Fix hyperlinks opening in a new browser in more exotic Linux flavours. [Ref: TG-18425]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading Coverage Reports. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2022-06-02

    Diffblue Cover now allows writing tests for code that calls JNI libraries

    The Java Native Interface (JNI) mechanism allows your Java applications to load native libraries written in C, C++, assembly, etc. Diffblue Cover executes your application in a sandboxed environment, so that its behavior can be analyzed without external effects, and by default this blocks the execution of JNI libraries. If you believe that Diffblue Cover is safe to call a native library that you use, then you can add it to the list of JNI libraries that are allowed to be loaded.

    Using the CLI

    Use the --allow-jni option to specifically allow JNI libraries with the given name prefix to be loaded. In this case, either --allow-jni custommagic or --allow-jni custom allows a JNI library custommagic to be loaded.

    Using the Intellij plugin Select Diffblue Cover Settings > Sandboxed Environment Options > Allowed JNI prefixes.

    For more information, please see our documentation at:

    Diffblue Cover provides additional guidance when using custom rules

    Using custom rules allows you to specify appropriate inputs necessary to write tests for a given method under test, should Diffblue Cover be unable to do them automatically. Custom rules must be formatted correctly.

    Diffblue Cover now offers additional guidance if the formatting is incorrect. For further information on custom rules, please see our documentation at:

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • Cover now allows additional JNI libraries to be used via the --allow-jni CLI option and Allowed JNI prefixes section of the IntelliJ Plugin settings. [Ref: TG-17102]

    • Cover now writes tests with MockitoJUnitRunner or MockitoExtension for Spring classes when spring-boot-test is not available. [Ref: TG-16457]

    Resolved Issues

    • Resolved an issue, which, in some circumstances, would prevent Cover from writing tests with more than one element in a Collection if a test with a single element Collection was written. [Ref: TG-17190]

    • Resolved an issue which, in some circumstances, would cause Cover to fail to activate, or write tests, on MacOS. [Ref: TG-16659]

    • Resolved an issue which caused Cover to report There is no license linked to your product

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from the root module with --working-directory. [Ref: TG-16876]

    2022-08-01

    IntelliJ 2022.2 support

    Diffblue is excited to announce that we now support the brand new IntelliJ 2022.2 release - IntelliJ IDEA Community Edition 2022.2 and IntelliJ IDEA Ultimate 2022.2 In keeping with our policy of supporting the current and the previous releases, we now support IntelliJ 2022.2 and IntelliJ 2022.1.

    Mockito static mocking

    In this release, we introduce support for Mockito static mocking using the new `–mock-static` option. This feature enables the mocking of static methods of the specified classes in created tests using `Mockito.mockStatic`. To use this feature, you must have Mockito 3.4.0 or above. Full documentation is provided here:

    New CLI environment variables option

    You can now set environment variables in Cover using the --environment option. For full details please see our user manual:

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • IntelliJ Plugin: Cover now supports IntelliJ IDEA Community Edition 2022.2 and IntelliJ IDEA Ultimate 2022.2. [Ref: TG-17517]

    • IntelliJ Plugin: Cover now avoids writing duplicate tests when 'Write Tests' executed on the same method/class/package. [Ref: TG-17504]

    • IntelliJ Plugin: Cover now displays and updates the 'Write Test' flask gutter icons quicker. [Ref: TG-17461]

    Resolved Issues

    • IntelliJ Plugin: Resolved an issue which caused Cover to not use IntelliJ IDEA's proxy authentication settings. [Ref: TG-17339]

    • CLI: Resolved an issue which caused Cover to be unable to resolve subprojects in a Gradle multi-module project. [Ref: TG-17544]

    • CLI: Resolved an issue which, in some circumstances, Cover would encounter a StackOverflowError. [Ref: TG-17519]

    Known Issues

    • CLI: The command dcover clean --failing does not work on Gradle projects. This command is now deprecated and dcover validate should be used instead. [Ref: TG-11707]

    • For multi-module projects, --coverage-reports needs to be run in the sub-modules, not from root module with --working-directory. [Ref: TG-16876]

    2023-01-01

    Controller tests using MockMvcBuilder for spring-framework (non spring-boot) projects

    Until now where you have a spring-framework project that is not using spring-boot, Diffblue Cover would produce non-canonical Spring tests (still using @Mock and @InjectMock however). In this release Cover now writes tests using MockMvcBuilder. As you can see below, the example uses MockMvc to test the method.

    Tests for Spring Controllers with Map-valued RequestBody that create non-empty maps

    In this release Cover is able to produce tests with valuable maps where a Spring Controller has Map-valued RequestBody that create non-empty maps. For Spring Controller methods with a @RequestBody Map argument Cover looks for relevant keys and values to populate the map in the resulting test, providing higher coverage, as shown in the following example:

    Enhancements

    • Cover now writes Controller tests using MockMvcBuilder for spring-framework projects without spring-boot. [Ref: TG-18388]

    • Cover now writes better tests for Spring Controller methods with @RequestBody parameters. [Ref: TG-17827]

    Resolved Issues

    • CLI: Resolved an issue which could cause Cover to discard the Gradle stack trace, rather than logging it to the user log file when an error with the build system is encountered. [Ref: TG-18365]

    • CLI: Resolved an issue which could cause Cover to rebuild all Gradle modules when tests are written. [Ref: TG-18349]

    • Resolved an issue which could cause Cover to not identify some Spring services, causing R013 (No inputs found that don't throw a trivial exception) to be reported. [Ref: TG-17392]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • Reports: Firefox users may encounter It seems like we encountered an error. Try refreshing this page or contact your administrator. while loading Coverage Reports. [Ref: TG-18257]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

    2023-03-02

    This release introduces a lot of improvements to the tests that Diffblue Cover automatically writes. Due to the large amount of code updates Diffblue will make, we suggest rerunning Diffblue Cover to create a new baseline set of tests for all of your projects.

    Higher-quality test code for methods involving generic types

    We have changed Cover to produce higher-quality test code when writing tests for methods involving generic types. In particular, we are more careful about preserving wildcards in type arguments.

    In this release we have tweaked our test creation strategy in a few places which will result in many, intentional, changes to the test code written by Cover.

    2023-07-02

    This release adds support for the TestNG testing framework and updates support for the Mockito mocking framework by adding support for Mockito 5. See the full Release Notes below for details of all enhancements and resolved issues covered by this release.

    Enhancements

    • Writing tests for Spring 6 entities and components is included in this release. Tests for spring controllers, repositories and validators will be available in a future release. [Ref: TG-19624]

    
    @ContextConfiguration(classes = {MyController.class})
    
    @ExtendWith(SpringExtension.class)
    
    class MyControllerDiffblueTest {
      @Autowired
      private MyController myController;
    
      @MockBean
      private Plain plain;
      /**
       * Method under test: {@link MyController#doSomethingOnBeanField(List)}
       */
      @Test
      void testDoSomethingOnBeanField() throws Exception {
        // Arrange
        when(plain.doSomething()).thenReturn("Do Something");
        MockHttpServletRequestBuilder getResult = MockMvcRequestBuilders.get("/do-plain");
        MockHttpServletRequestBuilder requestBuilder = getResult.sessionAttr("bandersnatch", new ArrayList<>());
    
        // Act and Assert
        MockMvcBuilders.standaloneSetup(myController)
            .build()
            .perform(requestBuilder)
            .andExpect(MockMvcResultMatchers.status().isOk())
            .andExpect(MockMvcResultMatchers.content().contentType("text/plain;charset=ISO-8859-1"))
            .andExpect(MockMvcResultMatchers.content().string("Do Something"));
      }
      public class Resource {
        public long getSize() {
        // !!! Code failure simulation !!!
          throw new NullPointerException();
        }
      }
      
      public class ServiceController {
        public ServiceController() {
        }
      
        public Resource getResource() {
          return new Resource();
        }
      }
      
      public class ServiceBuilder {
        public ServiceController build() {
          return new ServiceController();
        }
      }
      
      public class ClassUnderTest {
          public ClassUnderTest( ServiceController controller ) {
          //Calling problematic code
          controller.getResource().getSize();
        }
      }
      class ClassUnderTestDiffblueTest {
          /**
          * Method under test: {@link ClassUnderTest#ClassUnderTest(ServiceController)}
          */
          @Test
          void testConstructor() {
              // Arrange
              Resource resource = mock(Resource.class);
              when(resource.getSize()).thenReturn(3L);
              ServiceController controller = mock(ServiceController.class);
              when(controller.getResource()).thenReturn(resource);
              
              // Act
              new ClassUnderTest(controller);
              
              // Assert
              verify(controller).getResource();
              verify(resource).getSize();
          }
      }

    Cover: Diffblue Cover now supports Gradle projects using the Kotlin DSL (i.e. build.gradle.kts). [Ref: TG-19460]

  • Cover: Diffblue Cover now writes tests which use both empty and non-empty Collections for inputs when possible. [Ref: TG-19399]

  • Cover: Diffblue Cover now supports TestNG. Note that for Spring 4 projects that use TestNG and Mockito, the Mockito version must be below 2.7.0. Support for TestNG with Mockito >= 2.7.0, Spring 5 or Spring 6 is due in future releases. [Ref: TG-19329]

  • CLI: Diffblue Cover CLI now has a --mock-construction option to mock constructors of the given classes in tests. [Ref: TG-18763]

  • Cover: Diffblue Cover now supports mocking with the latest version of Mockito (Mockito 5). [Ref: TG-18613]

  • Resolved Issues

    • CLI: Updated --coverage-reports environment checks to WARN and continue instead of ERROR when JaCoCo encounters an issue. [Ref: TG-19457]

    • Cover: Resolved an issue such that mocks are now disabled if Mockito can't be initialized. [Ref: TG-19401]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration [Ref: TG-18282]

    • Cover may encounter an F009: Internal error while writing tests using Mockito 5. To avoid this issue use a version of Mockito earlier than 5. [Ref: TG-19610]

    • Cover may, in some circumstances, write tests which provoke W002: Test compiled, but did not pass, while using TestNG with Spring 4. [Ref: TG-19619]

    • Cover reports Command could not be completed due to an unexpected error: java.lang.AssertionError: expected value for fact SELECTED_BUILD_SYSTEM. while using an unsupported Java version. To avoid this issue, use a supported version of Java 8, 11 or 17. [Ref: TG-19623]

    preflight checks
    Cover Refactor
    IntelliJ Plugin: Project dependencies reported as missing can now be added with a single click in the tool panel. [Ref: TG-18207]
  • IntelliJ Plugin: Tool panel now uses the standard warning icon. [Ref: TG-18117]

  • CLI: Cover now warns (with E109) if JVM max heap size is set below the minimum of 4GB. [Ref: TG-17949]

  • CLI: Warnings about problematic class and method name templates are now errors. [Ref: TG-17659]

  • Dependency recommendations now include the recommended level of scope (in Maven) or implementation (in Gradle). [Ref: TG-18050]

  • Improved communication of problems with Maven JaCoCo plugin versions. [Ref: TG-17865]

  • Reports: Resolved an issue that could prevent large report files from being uploaded to Cover Reports. [Ref: TG-17240]

  • CLI: Cover fails to detect and work with Gradle 7.6. [Ref: TG-18548]

    IntelliJ Plugin: Cover now reports
    E067
    (JVM not a 64-bit implementation) if a 32-bit JVM has been detected. [Ref: TG-17612]
  • Reports: The 'Overview dashboard' now includes a counter showing the total number of lines of code in the project. [Ref: TG-18368]

  • Reports: Performance improvements. [Ref: TG-18375]

  • Reports: Resolved an issue which could cause Cover to not halt with an ERROR whilst running Cover CLI with the --coverage-reports option with an incompatible version of Surefire. [Ref: TG-17288]

    Passing method type parameters instead of using casts when generating mocks

    Previously, where Cover would have written:

    ...it will now write:

    Easier to read mocking

    Cover no longer inserts casts before Mockito.mock; for instance, instead of:

    ...it will now write the simpler:

    It's also worth noting that Cover now adds disambiguation casts more aggressively to distinguish between various overloads; in particular, you may see additional casts appear before null arguments.

    Better variable naming for tests

    The names of variables that Cover creates now more closely reflect their usage; for instance, instead of:

    ...the ofResult is replaced with birthDate:

    When Cover creates more than one variable of the same type, it now uses more intuitive numbering. For example, for three variables of the same type, instead of:

    ...the numbering of the second variable of the same type is 2, the third is numbered 3:

    IntelliJ IDEA 2023.1 support

    Diffblue Cover now supports IntelliJ IDEA 2023.1 (Community and Ultimate). In keeping with our policy of supporting the current and previous release, Diffblue Cover now supports IntelliJ IDEA 2022.3 and 2023.1. Support for IntelliJ IDEA 2022.2 has been removed as of Diffblue Cover 2023.03.02.

    Enhancements

    • IntelliJ Plugin: Cover now supports IntelliJ IDEA Community Edition 2023.1 and IntelliJ IDEA Ultimate 2023.1. [Ref: TG-18633]

    • Cover now produces more and better tests for code involving generics with wildcards. [Ref: TG-17479]

    • Cover now allows factories with class parameters to be specified in DiffblueRules.yml. See the 'Customizing test inputs' documentation for more details. [Ref: TG-18761]

    • Cover now selects better parameters for streams that are relevant for the method under test. [Ref: TG-16964]

    • Cover now has an improved ability to derive variable names from method parameter names in the code under test. [Ref: TG-18804]

    • Cover now has improved support for Spring 4.1.1. [Ref: TG-18657]

    • Cover now writes easier to read tests for Spring Repository save(...) methods so that they only save in the Act phase of tests. [Ref: TG-18802]

    • Reports: Cover now has simplified and clearer reporting dashboards. [Ref: TG-18738]

    Resolved Issues

    • Resolved an issue, which, in some circumstances, caused Cover to incorrectly report R011 (Sandboxing policy violation) instead of R020 (Temporary files were created but not deleted). [Ref: TG-18778]

    • Resolved an issue which caused dcover coverage-reports to report E084: JaCoCo command failed whilst using Surefire 3.0.0 when there are no existing manually written tests. [Ref: TG-18762]

    • Resolved an issue which, in some circumstances, would cause Cover to report com.diffblue.cover.exception.limitation.SpringContextCreationException: Failed to create Spring context using package [...]. [Ref: TG-18743]

    • Resolved an issue which, in some circumstances, caused Cover to report R024 (Analysis service shutdown unexpectedly) and R025 (Skipped due to previous failure). [Ref: TG-18742]

    • Resolved an issue which caused Cover to not exclude methods that throw InterruptedException from getters used in assertions. [Ref: TG-18723]

    • Resolved an issue which caused Cover to not consider using the current date as a test input, rather than just fixed dates. [Ref: TG-18710]

    • Resolved an issue which caused duplicate Detected Mockito version lines in the console and log files. [Ref: TG-18692]

    • CLI: Removed output code E106 (Multiple versions of dependencies) which provided a non-actionable output. [Ref: TG-18044]

    Known Issues

    • Cover may produce tests for JUnit 4.10 and lower that do not compile due to the use of assertNotEquals. [Ref: TG-17605]

    • IntelliJ Plugin: Upgrading to IntelliJ IDEA 2022.3 may, in some circumstances, cause existing run configurations to no longer produce tests. Removing any run configurations for that entity and writing tests again will recreate a working run configuration. [Ref: TG-18282]

      $ dcover create --preflight
      INFO  Diffblue Cover 2023.01.02-4cf7d6f
      INFO
      INFO  Detecting environment:
      INFO  ----------------------
      INFO  Java version: 11.0.15
      INFO  Selected build system: Maven
      INFO  Selected classpath from build system Maven
      INFO  Selected Java language compliance level: 1.8, from build system
      INFO  Selected test framework: JUnit Jupiter 5
      INFO  Selected test validation: enabled
      INFO  Prefixes for filtering classes/methods:
      INFO    io.diffblue.corebanking
      INFO    io.diffblue.corebanking.account
      INFO    io.diffblue.corebanking.client
      INFO    io.diffblue.corebanking.compliance
      INFO    io.diffblue.corebanking.compliance.rules
      INFO    io.diffblue.corebanking.datamanagement
      INFO    io.diffblue.corebanking.transaction
      INFO    io.diffblue.corebanking.ui
      INFO    io.diffblue.corebanking.ui.menu
      INFO  Gathering methods to test...
      INFO
      INFO  Environment summary:
      INFO  --------------------
      INFO
      INFO  Java version                  11.0.15             SUCCESS
      INFO  Build system                  Maven               SUCCESS
      INFO  Testing framework             JUnit Jupiter 5     SUCCESS
      INFO  Surefire version              3.0.0-M3            SUCCESS
      INFO  Launcher                      JUnit Jupiter       SUCCESS
      INFO  Test validation               Enabled             SUCCESS
      INFO  Mocking Framework             Mockito 4.2.0       SUCCESS
      INFO  Custom input rules                                SUCCESS
      INFO
      INFO  Environment check status: SUCCESS
      INFO  Check log file at /Users/pipeline/corebanking-cf/.diffblue/log/user-20230124T164802.log for more details or run dcover with --verbose option.
      INFO  Finished in 23s
      @ExtendWith(MockitoExtension.class)
      class WebControllerDiffblueTest {
      @InjectMocks
      private WebController webController;
    
      @Mock
      private WebSvc webSvc;
      /**
      * Method under test: {@link WebController#getId(String)}
      */
      @Test
      void testGetId() throws Exception {
        // Arrange
        when(webSvc.nextId()).thenReturn(123);
        MockHttpServletRequestBuilder requestBuilder = MockMvcRequestBuilders.get("/id").param("prefix", "foo");
    
        // Act and Assert
        MockMvcBuilders.standaloneSetup(webController)
            .build()
            .perform(requestBuilder)
            .andExpect(MockMvcResultMatchers.status().isOk())
            .andExpect(MockMvcResultMatchers.content().contentType("text/plain;charset=ISO-8859-1"))
            .andExpect(MockMvcResultMatchers.content().string("foo123"));
        }
      }
      @PutMapping("/hr/pass")
      public RespBean updateHrPasswd(@RequestBody Map<String, Object> info) {
        String oldpass = (String) info.get("oldpass");
        String pass = (String) info.get("pass");
        Integer hrid = (Integer) info.get("hrid");
        if (hrService.updateHrPasswd(oldpass, pass, hrid)) {
          return RespBean.ok("Update successful!");
        }
        return RespBean.error("Update failed!");
      }
      when(ownerRepository.findById((Integer) any())).thenReturn(owner);
      when(ownerRepository.findById(Mockito.<Integer>any())).thenReturn(owner);
      PostMetaServiceImpl postMetaService = new PostMetaServiceImpl(
          (BaseMetaRepository<PostMeta>) mock(BaseMetaRepository.class), mock(PostRepository.class));
      PostMetaServiceImpl postMetaService = new PostMetaServiceImpl(mock(BaseMetaRepository.class),
          mock(PostRepository.class));
      Pet pet = new Pet();
      LocalDate ofResult = LocalDate.of(1970, 1, 1);
      pet.setBirthDate(ofResult);
      Pet pet = new Pet();
      LocalDate birthDate = LocalDate.of(1970, 1, 1);
      pet.setBirthDate(birthDate);
      PetType petType = new PetType();
      PetType petType1 = new PetType();
      PetType petType2 = new PetType();
      PetType petType = new PetType();
      PetType petType2 = new PetType();
      PetType petType3 = new PetType();

    Cover now ensures that known-vulnerable Maven dependencies are not downloaded at runtime. [Ref: TG-17134]

  • Cover now provides improved guidance if R008 (Failed to instantiate class under test) is encountered whilst writing tests. [Ref: TG-17231]

  • CLI: Cover now provides a warning if an empty or malformed custom test inputs file is provided via DiffblueRules.yml. [Ref: TG-16982]

  • , rather than an
    , if the computer's hardware configuration had changed. [Ref: TG-16368]
  • IntelliJ Plugin: Resolved an issue which caused Cover to not show a detailed failure message if it was unable to combine tests it had written with an existing test class. [Ref: TG-17228]

  • CLI: Resolved an issue which caused Cover to run integration tests (*IT.java classes) tests whilst using the --coverage-reports CLI option. [Ref: TG-17291]

  • https://docs.diffblue.com/knowledge-base/cli/jni/
    https://docs.diffblue.com/knowledge-base/cli/custom-inputs/
    click here
    here
    this video
    L016 output code
    IntelliJ Plugin: Cover now spends less time indexing on Java 11 and Java 17 projects. [Ref: TG-15538]
  • CLI: Cover now allows environment values to be specified via the --environment option. [Ref: TG-17472]

  • CLI: Cover now supports Mockito static mocking via the --mock-static option. This feature enables the mocking of the static methods of the specified classes in created tests using Mockito.mockStatic. Requires Mockito 3.4.0 and above. [Ref: TG-17399]

  • CLI: Cover now outputs more precise recommendations when JUnit dependencies are missing, mismatched or unsupported. [Ref: TG-17230]

  • Cover now writes tests, when mocks need to be used, where it previously may have failed with an R002 (Missing observers). [Ref: TG-16610]

  • Resolved an issue which, in some circumstances, caused Cover to write tests containing many calls to copy constructors. [Ref: TG-17520]
  • Resolved an issue which caused Cover to not track Generic Type Arguments when choosing factories. [Ref: TG-17478]

  • Resolved an issue which caused Cover to provide type parameters to outer classes of non-static inner classes. [Ref: TG-17465]

  • https://docs.diffblue.com/knowledge-base/cli/mock-static
    https://docs.diffblue.com/knowledge-base/cli/cli-manual/#environment
    click here
    here
    this video

    Release archive

    • 2025-12-01

    • 2025-11-02

    • 2025-11-01

    2022-10-03

    Plugin - Improved logging now available

    For our IntelliJ plugin users, additional logging is now available whenever you write either tests or skeleton tests. A timestamped log file is created in addition to the standard logs containing all activity, which makes it significantly easier to find a particular event. The screenshot below shows the contents of the /tmp/diffblue/log directory with the standard user log alongside a new timestamped user log:

    {: width="240" height="150"}

    Mockito versions

    In this release, we have standardized the Mockito versions supported by Diffblue Cover. This, and other useful information, is shown in our :

    | Java Version | Supported Mockito Versions |

    | --- | --- |

    | 17 | 4.1.0 - 4.7.0 |

    | 11 | 2.22.0 - 4.7.0 |

    | 8 | 1.9.5 - 4.7.0 |

    ​​​​​

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    2022-11-02

    New Diffblue Cover features

    Four new features - Reports, Optimize, Refactor and Replay - have been added in this release of Diffblue Cover. In addition to autonomously writing and maintaining entire unit test suites without developer intervention, Cover Enterprise Edition now enables you to:

    • Automatically refactor Java code to improve testability

    • Slash the time and cost to run tests in Continuous Integration

    • Understand test coverage and code risk across your organization

    • Automatically shift complex functional tests left into unit test suites

    Read or watch to learn more about the new features. Then if you're interested in how the power of Enterprise Edition could help your team, .

    {: width="908" height="251"}

    Developer Edition trial available

    We are delighted to now offer a 14-day trial version of our Developer Edition, which includes the Diffblue Cover CLI, as part of our new licensing option. We're really excited that you can now "try before you buy"! To download your trial of Diffblue Cover Developer Edition, please . Full information on all our options is also available .

    How do I automatically maintain all of these tests?

    Use Diffblue Cover on any CI platform to automatically update your unit tests and catch regressions for every commit - watch to learn more.

    Enhancements

    • IntelliJ Plugin: Cover now asks for a test framework to be selected, via the plugin settings, when multiple test frameworks are on the classpath, rather than defaulting to JUnit 5. [Ref: TG-18006]

    • Cover now supports customizing test inputs via DiffblueRules.yaml in addition to the previously supported DiffblueRules.yml, with the former taking precedence. Problems with custom inputs are treated as an error and Cover will not attempt to create tests with invalid custom input rules. See the documentation for more details.

    Resolved Issues

    • Resolved an issue which, in some circumstances, caused Cover to report F009 instead of writing tests because of a field inheriting from a class with generic parameters. [Ref: TG-18097]

    • Resolved an issue which caused Cover to attempt to mock non-accessible, package-private, classes whilst writing tests from outside of their package. [Ref: TG-18070]

    2025-10-02
    2025-10-01
    2025-09-02
    2025-09-01
    2025-08-02
    2025-08-01
    2025-07-02
    2025-07-01
    2025-06-04
    2025-06-03
    2025-06-02
    2025-06-01
    2025-05-02
    2025-05-01
    2025-04-02
    2025-04-01
    2025-03-02
    2025-03-01
    2025-02-02
    2025-02-01
    2025-01-02
    2025-01-01
    2024-12-02
    2024-12-01
    2024-11-02
    2024-11-01
    2024-10-02
    2024-10-01
    2024-09-02
    2024-09-01
    2024-08-02
    2024-08-01
    2024-07-04
    2024-07-03
    2024-07-01
    2024-06-02
    2024-06-01
    2024-05-02
    2024-05-01
    2024-04-02
    2024-04-01
    2024-03-02
    2024-03-01
    2024-02-02
    2024-02-01
    2024-01-02
    2024-01-01
    2023-12-02
    2023-12-01
    2023-11-03
    2023-11-02
    2023-11-01
    2023-10-02
    2023-10-01
    2023-09-02
    2023-09-01
    2023-08-02
    2023-08-01
    2023-07-03
    2023-07-02
    2023-07-01
    2023-06-02
    2023-06-01
    2023-05-02
    2023-05-01
    2023-04-02
    2023-04-01
    2023-03-02
    2023-03-01
    2023-02-02
    2023-02-01
    2023-01-02
    2023-01-01
    2022-12-02
    2022-12-01
    2022-11-02
    2022-11-01
    2022-10-03
    2022-10-02
    2022-10-01
    2022-09-02
    2022-09-01
    2022-08-05
    2022-08-03
    2022-08-02
    2022-08-01
    2022-07-02
    2022-07-01
    2022-06-02
    2022-06-01
    2022-05-02
    2022-05-01
    2022-04-02
    2022-04-01
    2022-03-02
    2022-03-01
    2022-02-02
    2022-02-01
    2022-01-02
    2022-01-01
    2021-06-02
    2021-02-01
    Datasheet
    click here
    here
    this video
    this blog post
    this short YouTube playlist
    get in touch via our website
    click here
    here
    this video
    customizing test inputs