mirror of
https://github.com/github/codeql.git
synced 2026-06-19 03:41:07 +02:00
Convert Python qlref tests to inline expectations
This commit is contained in:
@@ -1 +1,2 @@
|
||||
Variables/LeakingListComprehension.ql
|
||||
query: Variables/LeakingListComprehension.ql
|
||||
postprocess: utils/test/InlineExpectationsTestQuery.ql
|
||||
|
||||
@@ -2,12 +2,12 @@ from __future__ import print_function
|
||||
|
||||
def undefined_in_3():
|
||||
[x for x in range(3)]
|
||||
print(x)
|
||||
print(x) # $ Alert
|
||||
|
||||
def different_in_3():
|
||||
y = 10
|
||||
[y for y in range(3)]
|
||||
print(y)
|
||||
print(y) # $ Alert
|
||||
|
||||
def ok():
|
||||
[z for z in range(4)]
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
|
||||
|
||||
__all__ = [ "x", "y", "z", "module" ]
|
||||
__all__ = [ "x", "y", "z", "module" ] # $ Alert[py/undefined-export]
|
||||
|
||||
x = 1
|
||||
if 0:
|
||||
|
||||
@@ -1 +1,2 @@
|
||||
Variables/UndefinedExport.ql
|
||||
query: Variables/UndefinedExport.ql
|
||||
postprocess: utils/test/InlineExpectationsTestQuery.ql
|
||||
|
||||
@@ -1 +1,2 @@
|
||||
Variables/UndefinedGlobal.ql
|
||||
query: Variables/UndefinedGlobal.ql
|
||||
postprocess: utils/test/InlineExpectationsTestQuery.ql
|
||||
|
||||
@@ -1 +1,2 @@
|
||||
Variables/UninitializedLocal.ql
|
||||
query: Variables/UninitializedLocal.ql
|
||||
postprocess: utils/test/InlineExpectationsTestQuery.ql
|
||||
|
||||
@@ -1 +1 @@
|
||||
__all__ = [ "module", "not_exists" ]
|
||||
__all__ = [ "module", "not_exists" ] # $ Alert[py/undefined-export]
|
||||
Reference in New Issue
Block a user