I want to obtain new, fixed and total issues from cppcheck analysis and I want to compare this information with the previous analysis. But, for the new and fixed issues, there is not comparison and the returned value is always 0. All my issues are considered like "Outstanding". This is my code in my Jenkins pipeline :
recordIssues enabledForFailure: true, tool: cppCheck(pattern: 'cppcheck/cppcheck.xml')
def totalIssuesCountString = tm stringWithMacro: '${ANALYSIS_ISSUES_COUNT, tool="cppcheck", type="TOTAL"}'
int totalIssuesCount = totalIssuesCountString as int
def newIssuesCountString = tm stringWithMacro: '${ANALYSIS_ISSUES_COUNT, tool="cppcheck", type="NEW"}'
int newIssuesCount = newIssuesCountString as int
def fixedIssuesCountString = tm stringWithMacro: '${ANALYSIS_ISSUES_COUNT, tool="cppcheck", type="FIXED"}'
int fixedIssuesCount = fixedIssuesCountString as int
echo "New : ${newIssuesCount}"
echo "Fixed : ${fixedIssuesCount}"
echo "Total : ${totalIssuesCount}"
I tried many arguments of "recordIssues" command. I would like to obtain the comparison of the new and fixed issues with the previous analysis. I don't know why but, before the Jenkins update, this process works well and now, I have this problem.