Skip to content

Commit

Permalink
Add integration test for --binlog
Browse files Browse the repository at this point in the history
  • Loading branch information
tamasvajk committed Jun 4, 2024
1 parent b8345b9 commit 6268963
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
| Program.cs:0:0:0:0 | Program.cs |
| obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs:0:0:0:0 | obj/Debug/net8.0/.NETCoreApp,Version=v8.0.AssemblyAttributes.cs |
| obj/Debug/net8.0/test.AssemblyInfo.cs:0:0:0:0 | obj/Debug/net8.0/test.AssemblyInfo.cs |
| obj/Debug/net8.0/test.GlobalUsings.g.cs:0:0:0:0 | obj/Debug/net8.0/test.GlobalUsings.g.cs |
5 changes: 5 additions & 0 deletions csharp/ql/integration-tests/all-platforms/binlog/Files.ql
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import csharp

from File f
where f.fromSource()
select f
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
var dummy = "dummy";
5 changes: 5 additions & 0 deletions csharp/ql/integration-tests/all-platforms/binlog/global.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"sdk": {
"version": "8.0.101"
}
}
10 changes: 10 additions & 0 deletions csharp/ql/integration-tests/all-platforms/binlog/test.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net8.0</TargetFramework>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
</PropertyGroup>

</Project>
5 changes: 5 additions & 0 deletions csharp/ql/integration-tests/all-platforms/binlog/test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import subprocess
from create_database_utils import *

subprocess.check_call(["dotnet", "build", "/bl:test.binlog"])
run_codeql_database_create([], lang="csharp", extra_args=["--build-mode=none", "-Obinlog=test.binlog"])

0 comments on commit 6268963

Please sign in to comment.