Skip to content

Commit 0b579c0

Browse files
committed
C#: Update external models tests and expected test output.
1 parent 308aca6 commit 0b579c0

File tree

4 files changed

+8
-1
lines changed

4 files changed

+8
-1
lines changed

csharp/ql/test/library-tests/dataflow/external-models/sinks.expected

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,7 @@ invalidModelRow
44
| Sinks.cs:11:13:11:41 | this access | file-content-store |
55
| Sinks.cs:11:30:11:40 | access to local variable argToTagged | file-content-store |
66
| Sinks.cs:14:27:14:36 | access to local variable fieldWrite | sql-injection |
7+
| Sinks.cs:17:36:17:48 | access to local variable propertyWrite | sql-injection |
8+
| Sinks.cs:20:23:20:34 | access to local variable indexerWrite | sql-injection |
79
| Sinks.cs:26:20:26:22 | access to local variable res | js-injection |
810
| Sinks.cs:33:20:33:25 | access to local variable resTag | html-injection |

csharp/ql/test/library-tests/dataflow/external-models/sinks.ext.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,5 @@ extensions:
99
- ["My.Qltest", "SinkAttribute", false, "", "", "Attribute", "ReturnValue", "html-injection", "manual"]
1010
- ["My.Qltest", "SinkAttribute", false, "", "", "Attribute", "Argument", "file-content-store", "manual"]
1111
- ["My.Qltest", "SinkAttribute", false, "", "", "Attribute", "", "sql-injection", "manual"]
12+
- ["My.Qltest", "SinkPropertyAttribute", false, "", "", "Attribute.Setter", "Argument[0]", "sql-injection", "manual"]
13+
- ["My.Qltest", "SinkIndexerAttribute", false, "", "", "Attribute.Setter", "Argument[1]", "sql-injection", "manual"]

csharp/ql/test/library-tests/dataflow/external-models/srcs.expected

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ invalidModelRow
99
| Sources.cs:17:17:17:33 | call to method TaggedSrcMethod | local |
1010
| Sources.cs:18:17:18:30 | access to field TaggedSrcField | local |
1111
| Sources.cs:20:17:20:33 | call to method SrcTwoArg | local |
12+
| Sources.cs:22:17:22:39 | access to property TaggedSrcPropertyGetter | local |
13+
| Sources.cs:23:17:23:23 | access to indexer | local |
1214
| Sources.cs:27:14:27:20 | this | local |
1315
| Sources.cs:27:29:27:45 | taggedMethodParam | local |
1416
| Sources.cs:31:47:31:60 | taggedSrcParam | local |

csharp/ql/test/library-tests/dataflow/external-models/srcs.ext.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,5 @@ extensions:
1717
- ["My.Qltest", "SourceAttribute", false, "", "", "Attribute", "ReturnValue", "local", "manual"]
1818
- ["My.Qltest", "SourceAttribute", false, "", "", "Attribute", "Parameter", "local", "manual"]
1919
- ["My.Qltest", "SourceAttribute", false, "", "", "Attribute", "", "local", "manual"]
20-
- ["My.Qltest", "A", false, "SrcTwoArg", "(System.String,System.String)", "", "ReturnValue", "local", "manual"]
20+
- ["My.Qltest", "SourceAttribute", false, "", "", "Attribute.Getter", "ReturnValue", "local", "manual"]
21+
- ["My.Qltest", "A", false, "SrcTwoArg", "(System.String,System.String)", "", "ReturnValue", "local", "manual"]

0 commit comments

Comments
 (0)