Command summary

Command summary

CommandDescription

dcover create

Create Tests - write tests for a project, package, method or class. See Create tests.

dcover create --preflight

Run Preflight Checks - verifies whether the local environment and the project are in the best condition possible for dcover to create tests, without actually creating the tests. See Project configuration for full details.

dcover help create

Help - display inline help for the dcover create command (syntax, available arguments, and short descriptions).

dcover version

Check Version - display your Cover CLI version.

Create tests

Usage: dcover create [@<argumentFile>...] [<entryPoint>...] [--<argument>...]

Example: dcover create @argfile.txt io.corebanking.Account --maven

Inline help: dcover help create

Description: The dcover create command writes tests for your projects, packages, classes, and methods.

  • By default, dcover create automatically writes tests for the entire project. If required, you can specify what packages, classes, or methods you want to write tests for, on the command line (using [<entryPoint>...]) - see Packages, classes, and methods.

  • Command lines can become very long when multiple options are specified. To keep your command lines short and avoid any potential issues with terminals that don't support very long command lines, you can make use of argument files to define your optional arguments (using [@<argumentFile>...]) - see Argument files for details.

Output Codes

Cover CLI performs a number of checks before, during, and after creating unit tests. Cover can generate a range of output codes during these checks to provide general information and highlight any issues. Details for all output codes are provided in the main Output Codes topic. Note that as and when these output codes are displayed within Cover CLI, additional specifics may also be provided, if relevant. Also, some common issues can be resolved automatically using dcover refactor - see Cover Refactor.

Last updated