How to focus on new linting failures in code changes using Verissimo in DVT Eclipse IDE
Overview
This video demonstrates a powerful Verissimo workflow in the DVT IDE: by linting against a baseline, you can skip unchanged files to speed up the process and focus your analysis specifically on linting failures introduced by recent code changes.
This video was made with DVT version 25.1.12.
Details
Introduction
Verissimo identifies new issues caused by recent code changes by comparing current linting results to a previous baseline. It filters out pre-existing failures and helps you focus on the relevant, newly introduced ones.
First, let's run Verissimo with the "Basic" ruleset and generate a baseline report. When exporting it, make sure to include the source code.
Now, let's make some changes to the code. First, let's fix some of the failures, and then also add a few new variables.
Now let’s lint the project and focus on newly introduced failures. Start a new linting session, create a new configuration with the same ruleset, and select the baseline report folder. This is what tells Verissimo to trigger a comparison with the baseline.
You can also choose to Prewaive Unchanged Files, basically to skip linting those files that haven’t changed since the baseline was generated. This will significantly reduce linting time, especially in large projects.
Verissimo automatically brings up the Changes report, which shows only new failures introduced with our earlier changes. As you can see, only the changed lines have linting problem markers.
You can also view the linting results in The Changes HTML report, which - similarly - presents only new failures.
By the way, you can further explore the effects of your changes using the more advanced Compare report where you can independently explore New Fixes like this "cast", or New Failures introduced by the changes.
You might consider saving this linting session as a baseline for your next batch of changes. However, notice that failures from the unchanged files are missing, because we chose to pre-waive unchanged files for a shorter linting time. Therefore, before saving a new baseline, make sure to run Verissimo without pre-waiving.
Perhaps a better option is to integrate Verissimo in CI / CD flows and prepare “baseline reports” in advance, either nightly or for each commit.