Skip to content

Commit 2bc4a60

Browse files
committed
Python: Unify normal dataflow test setup
I went with NormalDataflowTest to signify that if you don't know what you're looking for, this is probably the one. I did not want to just call it DataflowTest, since that becomes a big vague when there are also `FlowTest.qll` and `MaximalFlowTest.qll` -- I'm open to renaming this though 👍
1 parent 4131960 commit 2bc4a60

File tree

9 files changed

+11
-26
lines changed

9 files changed

+11
-26
lines changed

python/ql/test/experimental/dataflow/coverage/dataflowTest.ql renamed to python/ql/test/experimental/dataflow/TestUtil/NormalDataflowTest.qll

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import python
22
import experimental.dataflow.TestUtil.FlowTest
33
import experimental.dataflow.testConfig
4+
private import semmle.python.dataflow.new.internal.PrintNode
45

56
class DataFlowTest extends FlowTest {
67
DataFlowTest() { this = "DataFlowTest" }
@@ -10,4 +11,8 @@ class DataFlowTest extends FlowTest {
1011
override predicate relevantFlow(DataFlow::Node source, DataFlow::Node sink) {
1112
exists(TestConfiguration cfg | cfg.hasFlow(source, sink))
1213
}
14+
15+
override predicate hasActualResult(Location location, string element, string tag, string value) {
16+
super.hasActualResult(location, element, tag, value)
17+
}
1318
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import python
2+
import experimental.dataflow.TestUtil.NormalDataflowTest
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import python
2+
import experimental.dataflow.TestUtil.NormalDataflowTest

python/ql/test/experimental/dataflow/fieldflow/dataflowTest.ql

Lines changed: 0 additions & 13 deletions
This file was deleted.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import python
2+
import experimental.dataflow.TestUtil.NormalDataflowTest

python/ql/test/experimental/dataflow/match/dataflowTest.ql

Lines changed: 0 additions & 13 deletions
This file was deleted.

0 commit comments

Comments
 (0)