When using Pipeline and the Warnings plug-in, the delta is not calculated correctly.
We use the Warnings plug-in to:
- Fail a build when there are any compiler warnings (GCC), in a Build stage.
- Fail a build when more PC-Lint warnings are introduced. in a Analysis stage.
Previously we had separate jobs for Build and Analysis, but we are trying to move to using actual pipelines (instead of "chaining jobs").
The first build will run fine. It reports zero GCC warnings and, let's say, 124 PC-Lint warnings from old legacy code.
When I re-run the build on the same sources, I expect it to be successful again, because no new warnings have been introduced.
However, it states that the threshold of zero is exceeded by 124, when recording the PC-Lint warnings.
I reckon this is due to the fact that the PC-Lint warning count is compared against the GCC warning count, because they are effectively in the same job even though they are not in the same stage.
Personally I would expect the difference to be calculated based on what was previously seen in the same stage, or perhaps even for the same parser.
If there is another plug-in that allows me to do this in a similar matter and when using pipelines, I'd also love to know.