C#: Port the java FrameworkCoverage query.

This commit is contained in:
Michael Nebel
2022-04-26 09:36:38 +02:00
parent db856798b9
commit 98b2bc06ce

View File

@@ -0,0 +1,18 @@
/**
* @id csharp/summary/framework-coverage
* @name Metrics of framework coverage
* @description Expose metrics for the number of API endpoints covered by CSV models.
* @kind metric
* @tags summary
*/
import csharp
import semmle.code.csharp.dataflow.ExternalFlow
from string namespaceAndType, int rows
where
exists(string namespace, string type |
namespaceAndType = namespace + ";" + type and
rows = strictsum(int n, string kind | modelCoverage(namespace, _, kind, type, n) | n)
)
select namespaceAndType, rows