Skip to content

Commit b79e2dd

Browse files
committed
Ql4Ql: Add some more quality tag testcases.
1 parent f58064e commit b79e2dd

File tree

5 files changed

+38
-0
lines changed

5 files changed

+38
-0
lines changed

ql/ql/test/queries/style/MissingQualityMetadata/MissingQualityMetadata.expected

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,5 @@
22
| testcases/BadQualityMultipleTopLevel.ql:1:1:11:3 | QueryDoc | This query file has incorrect top-level categorisation. It should have exactly one top-level category, either `@tags maintainability` or `@tags reliability`. |
33
| testcases/BadQualityNoToplevel.ql:1:1:10:3 | QueryDoc | This query file has incorrect top-level categorisation. It should have exactly one top-level category, either `@tags maintainability` or `@tags reliability`. |
44
| testcases/BadQualityReliabilityWrongToplevel.ql:1:1:11:3 | QueryDoc | This query file has a sub-category of maintainability but is missing the `@tags maintainability` tag. |
5+
| testcases/GoodQualityMaintainabilityWithCrossSub.ql:1:1:12:3 | QueryDoc | This query file has a sub-category of reliability but is missing the `@tags reliability` tag. |
6+
| testcases/GoodQualityReliabilityWithCrossSub.ql:1:1:12:3 | QueryDoc | This query file has a sub-category of maintainability but is missing the `@tags maintainability` tag. |

ql/ql/test/queries/style/MissingQualityMetadata/testcases/GoodQualityMaintainabilityWithCrossSub.expected

Whitespace-only changes.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/**
2+
* @name Some query
3+
* @description Some description
4+
* @kind problem
5+
* @problem.severity warning
6+
* @precision very-high
7+
* @id ql/quality-query-test
8+
* @tags quality
9+
* maintainability
10+
* readability
11+
* correctness
12+
*/
13+
14+
import ql
15+
16+
from Class c
17+
where none()
18+
select c, ""

ql/ql/test/queries/style/MissingQualityMetadata/testcases/GoodQualityReliabilityWithCrossSub.expected

Whitespace-only changes.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/**
2+
* @name Some query
3+
* @description Some description
4+
* @kind problem
5+
* @problem.severity warning
6+
* @precision very-high
7+
* @id ql/quality-query-test
8+
* @tags quality
9+
* reliability
10+
* correctness
11+
* readability
12+
*/
13+
14+
import ql
15+
16+
from Class c
17+
where none()
18+
select c, ""

0 commit comments

Comments
 (0)