Skip to content

Commit 621e3f6

Browse files
committed
Python: Add dataflow test of deep call graph
1 parent 45ab723 commit 621e3f6

File tree

1 file changed

+25
-0
lines changed
  • python/ql/test/experimental/dataflow/coverage

1 file changed

+25
-0
lines changed

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

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -377,3 +377,28 @@ def test_swap():
377377
a, b = b, a
378378
SINK_F(a)
379379
SINK(b)
380+
381+
382+
def test_deep_callgraph():
383+
# port of python/ql/test/library-tests/taint/general/deep.py
384+
385+
def f1(arg):
386+
return arg
387+
388+
def f2(arg):
389+
return f1(arg)
390+
391+
def f3(arg):
392+
return f2(arg)
393+
394+
def f4(arg):
395+
return f3(arg)
396+
397+
def f5(arg):
398+
return f4(arg)
399+
400+
def f6(arg):
401+
return f5(arg)
402+
403+
x = f6(SOURCE)
404+
SINK(x) # Flow missing

0 commit comments

Comments
 (0)