In this section:
Jtest supports static analysis with Checkstyle 5.5, 5.6, 5.7, and 6.5.
Downloading and Installing Checkstyle
- Download Checkstyle from the following website: http://sourceforge.net/projects/checkstyle/files.
- Unpack Checkstyle to install.
- Copy the configs, plugins, and rules folders from the
[INSTALL_DIR]/integration/checkstyle directory into the Checkstyle installation directory.
jtestcli.properties file to include the following properties:
Analyzing Code with Checkstyle
Specify the Checkstyle user test configurations to perform analysis with Checkstyle:
user://Checkstyle - Enables every rule
user://Checkstyle Recommended - Enables Checkstyle recommended rules
You can customize your Checkstyle integration by configuring the following properties.
# Custom limit for number of files to be tested in a single executed Checkstyle process. Default is 50.
# However, if subsequent files are placed in the same directory, they will be still scheduled to that
# process unless the "hard" limit is reached (twice the "regular" limit).
# Custom timeout (seconds) for the Checkstyle process to start. Default is 5 seconds.
# Custom timeout (seconds) for the Checkstyle process to complete. Default is 60 seconds.
# Custom launch file for Checkstyle process. Default is taken from the Checkstyle analyzer jar file.
# If one cannot be found, attempts to use file 'checkstyle.ini' from current working directory.
rulemap.txt file located in the
[INSTALL_DIR]/integration/checkstyle directory contains information about how rule IDs used in test configuration are mapped to Checkstyle rule types.