Skip to content

Commit 11970fb

Browse files
committed
C#: Add XML overlay tests.
1 parent 89f7619 commit 11970fb

File tree

7 files changed

+51
-0
lines changed

7 files changed

+51
-0
lines changed

csharp/ql/test/library-tests/overlay/base/test.expected

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,3 +261,16 @@ typeMentions
261261
| Program.cs:60:10:60:16 | ProgramAttribute |
262262
| Program.cs:61:16:61:19 | Void |
263263
| Program.cs:64:37:64:45 | Attribute |
264+
xmlLocatables
265+
| web.changed.config:2:1:12:17 | configuration |
266+
| web.changed.config:3:3:4:16 | system.web |
267+
| web.changed.config:5:3:11:22 | system.webServer |
268+
| web.changed.config:6:5:10:20 | httpProtocol |
269+
| web.changed.config:7:7:9:23 | customHeaders |
270+
| web.changed.config:8:9:8:42 | add |
271+
| web.changed.config:8:9:8:42 | name=MyOption |
272+
| web.changed.config:8:9:8:42 | value=1 |
273+
| web.unchanged.config:2:1:6:17 | configuration |
274+
| web.unchanged.config:3:3:5:16 | system.web |
275+
| web.unchanged.config:4:5:4:37 | httpCookies |
276+
| web.unchanged.config:4:5:4:37 | requireSSL=true |
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<configuration>
3+
<system.web>
4+
</system.web>
5+
<system.webServer>
6+
<httpProtocol>
7+
<customHeaders>
8+
<add name="MyOption" value="1" />
9+
</customHeaders>
10+
</httpProtocol>
11+
</system.webServer>
12+
</configuration>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<configuration>
3+
<system.web>
4+
<httpCookies requireSSL="true"/>
5+
</system.web>
6+
</configuration>

csharp/ql/test/library-tests/overlay/overlay/test.expected

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,3 +265,10 @@ typeMentions
265265
| Program.cs:60:10:60:16 | ProgramAttribute |
266266
| Program.cs:61:16:61:19 | Void |
267267
| Program.cs:64:37:64:45 | Attribute |
268+
xmlLocatables
269+
| web.changed.config:2:1:5:17 | configuration |
270+
| web.changed.config:3:3:4:16 | system.web |
271+
| web.unchanged.config:2:1:6:17 | configuration |
272+
| web.unchanged.config:3:3:5:16 | system.web |
273+
| web.unchanged.config:4:5:4:37 | httpCookies |
274+
| web.unchanged.config:4:5:4:37 | requireSSL=true |
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<configuration>
3+
<system.web>
4+
</system.web>
5+
</configuration>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="utf-8" ?>
2+
<configuration>
3+
<system.web>
4+
<httpCookies requireSSL="true"/>
5+
</system.web>
6+
</configuration>

csharp/ql/test/library-tests/overlay/test.ql

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,5 @@ query predicate commentLines(CommentLine cl) { any() }
3737
query predicate commentBlocks(CommentBlock cb) { any() }
3838

3939
query predicate typeMentions(TypeMention tm) { any() }
40+
41+
query predicate xmlLocatables(XmlLocatable xl) { any() }

0 commit comments

Comments
 (0)