mirror of
https://github.com/github/codeql.git
synced 2025-12-21 19:26:31 +01:00
Filter out tests directories
This commit is contained in:
@@ -68,7 +68,7 @@ predicate predictableInstruction(Instruction instr) {
|
||||
module ImproperArrayIndexValidationConfig implements DataFlow::ConfigSig {
|
||||
predicate isSource(DataFlow::Node source) {
|
||||
isFlowSource(source, _) and
|
||||
not source.asExpr().getFile().getRelativePath().regexpMatch("/tests?/")
|
||||
not source.getLocation().getFile().getRelativePath().regexpMatch("(.*/)?tests?/.*")
|
||||
}
|
||||
|
||||
predicate isBarrier(DataFlow::Node node) {
|
||||
|
||||
Reference in New Issue
Block a user