Skip to content

Commit

Permalink
Add test run to test isElevated
Browse files Browse the repository at this point in the history
  • Loading branch information
ptvty committed Mar 31, 2024
1 parent c2ae50b commit 1d5cf35
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ jobs:
run: dotnet restore
- name: Publish for win-x64
run: dotnet publish -r win-x64
- name: Test run
run: ./bin/Release/net8.0/win-x64/publish/WinFileReadEvents.exe testRun
- name: Get version
id: package_version
uses: KageKirin/get-csproj-version@v0
Expand Down
5 changes: 5 additions & 0 deletions Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ static void Main(string[] args)

string? filePath = (args.Length < 1) ? null : args[0];

if (filePath == "testRun") {
Console.WriteLine("x|testRun");
return;
}

using var session = new TraceEventSession("FileRead");

Console.CancelKeyPress += (sender, e) => session.Stop();
Expand Down
2 changes: 1 addition & 1 deletion WinFileReadEvents.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<RootNamespace>WinFileReadEvents</RootNamespace>
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<Version>0.1.1</Version>
<Version>0.1.2</Version>
</PropertyGroup>

<ItemGroup>
Expand Down

0 comments on commit 1d5cf35

Please sign in to comment.