Rule Compliance
Concept
Rule Compliance indicates how well the project development team follows the coding guidelines. A rule is not compliant if at least one unjustified violation is detected. If a violation is relaxed/justified using the "relaxation feature", it will not impact rule compliance. For this KPI, Squore only takes into account rules which nature is categorized as "Non Conformity".
Formula
Rule Compliance = (#violated rules / #Verified Rules)
Where: * "Violated rules" is the number of rules for which there is at least 1 violation * "Verified Rules" is the number of rules which were checked during static code analysis
Side Effect of External Data Provider
The list of "verified rules" depends on the static code analysis and thus, depends on the external tools results which are imported in the Squore project with Data providers.
Example:
-
Using ‘Squore Analyzer’ Data provider only: Total verified rules is 19 (for C language)
-
Using ‘Squore Analyzer’ + ‘PCLint’ Data providers: Total verified rules is 152.
Rule Compliance may drastically vary, depending on the static code analyzers used on the project.
Note: Squore dynamically create the ruleset based on the selected Data Providers. For instance, MISRA Checker will not be counted in the "verified rules" if no MISRA analyzer are called.
The reason comes from the "verified rules" which drastically changed:
Settings (Ruleset Template)
After selection of the Data Providers, Squore provides an interface to tune the ruleset in order to enable/disable specific rules.
It is possible to create a template to share this ruleset configuration between projects.