Skip to content

Commit 045a6c3

Browse files
committed
Python: Add test for tricky module member for type-tracking
Local testing shows that the `getDefinition` result for this is a `SSA filter definition`, and not an `AssignmentDefinition`.
1 parent f5ec548 commit 045a6c3

File tree

3 files changed

+5
-0
lines changed

3 files changed

+5
-0
lines changed

python/ql/test/experimental/dataflow/typetracking/mymodule.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,6 @@
22

33
def func():
44
return tracked # $tracked
5+
6+
z = tracked # $tracked
7+
some_func(z) # $tracked

python/ql/test/experimental/dataflow/typetracking/test.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ def test_import():
5454
mymodule.x # $tracked
5555
y = mymodule.func() # $tracked
5656
y # $tracked
57+
mymodule.z # $tracked
5758

5859
# ------------------------------------------------------------------------------
5960

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
| test.py:57:16:57:25 | Comment # $tracked | Missing result:tracked= |

0 commit comments

Comments
 (0)