This lesson teaches you how to check that your code complies with coding standards designed to prevent errors and improve code quality. 

Background

C++test performs static analysis on source code to determine whether it complies with a specified set of coding standard rules. The set of rules is specified in a Test Configuration. C++test provides a number of built-in Test Configurations with corresponding predefined coding standard sets. You can define your own Test Configurations that contain only the coding standard rules most relevant to your projects and policies.

Each C++test coding standard rule is assigned a severity level. The severity level indicates the probability that a rule violation will cause a serious construction defect (i.e., a coding construct that causes application problems, such as slow performance, memory leaks, security vulnerabilities, and so on).

  • Highest – Severity 1
  • High – Severity 2
  • Medium – Severity 3
  • Low – Severity 4
  • Lowest – Severity 5

You should have already completed the Tutorial - Creating a C++test Project tutorial before completing the following exercises.

  • No labels