Coverage for src/pytest_gitlab_code_quality/report.py: 100%

21 statements  

« prev     ^ index     » next       coverage.py v7.4.4, created at 2024-04-03 22:19 +0200

1from dataclasses import dataclass 

2 

3 

4@dataclass 

5class Lines: 

6 begin: int 

7 """The line on which the code quality violation occurred.""" 

8 

9 

10@dataclass 

11class Location: 

12 path: str 

13 """The relative path to the file containing the code quality violation.""" 

14 

15 lines: Lines 

16 

17 

18@dataclass 

19class Violation: 

20 """ 

21 A code quality violation / warning emitted during the test run. 

22 

23 See https://docs.gitlab.com/ee/ci/testing/code_quality.html#implement-a-custom-tool 

24 """ 

25 

26 description: str 

27 """A description of the code quality violation.""" 

28 

29 check_name: str 

30 """A unique name representing the static analysis check that emitted this issue.""" 

31 

32 fingerprint: str 

33 """A unique fingerprint to identify the code quality violation. For example, an MD5 hash.""" 

34 

35 severity: str 

36 """A severity string (can be info, minor, major, critical, or blocker).""" 

37 

38 location: Location