Skip to content

Commit

Permalink
test: disable xunit's AppDomain which seems to have been causing the …
Browse files Browse the repository at this point in the history
…issue with random CI failures (on mono). (#126)
  • Loading branch information
skwasjer authored Oct 6, 2024
1 parent 8590457 commit dca42eb
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 30 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,9 @@ jobs:
name: build

# Run all tests
- run: dotnet test --no-restore --no-build -c Release
- run: dotnet test --no-restore --no-build -c Release -- xUnit.AppDomain=denied
if: matrix.os == 'ubuntu-latest'
- run: dotnet test --no-restore --no-build -c Release --filter Category!=PublicApi
- run: dotnet test --no-restore --no-build -c Release --filter Category!=PublicApi -- xUnit.AppDomain=denied
if: matrix.os != 'ubuntu-latest'

pack:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sonarcloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,6 @@ jobs:
run: |
dotnet sonarscanner begin /k:"$SONAR_PROJECT_KEY" /o:"$SONAR_ORG_KEY" /d:sonar.host.url=https://sonarcloud.io /d:sonar.token="$SONAR_TOKEN" /d:sonar.cs.opencover.reportsPaths="**/*opencover.xml" $SONAR_PR_ARGS
dotnet test -c Release /p:CollectCoverage=true /p:CoverletOutputFormat=opencover /p:ExcludeByFile="test/**/*.cs" /p:VerifyPublicApi=false
dotnet test -c Release /p:CollectCoverage=true /p:CoverletOutputFormat=opencover /p:ExcludeByFile="test/**/*.cs" /p:VerifyPublicApi=false -- xUnit.AppDomain=denied
dotnet sonarscanner end /d:sonar.token="$SONAR_TOKEN"
4 changes: 0 additions & 4 deletions test/MockHttp.Json.Tests/MockHttp.Json.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@
<RootNamespace>MockHttp.Json</RootNamespace>
</PropertyGroup>

<ItemGroup>
<Compile Include="..\MockHttp.Testing\XunitAppDomainUnloadHook.cs" Link="XunitAppDomainUnloadHook.cs" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\MockHttp.Testing\MockHttp.Testing.csproj" />
<!-- For coverage purposes, override default dependency resolution and instead target specific frameworks. -->
Expand Down
4 changes: 0 additions & 4 deletions test/MockHttp.Server.Tests/MockHttp.Server.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@
<RootNamespace>MockHttp</RootNamespace>
</PropertyGroup>

<ItemGroup>
<Compile Include="..\MockHttp.Testing\XunitAppDomainUnloadHook.cs" Link="XunitAppDomainUnloadHook.cs" />
</ItemGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Extensions.Diagnostics.Testing" Version="8.9.1" />
</ItemGroup>
Expand Down
15 changes: 0 additions & 15 deletions test/MockHttp.Testing/XunitAppDomainUnloadHook.cs

This file was deleted.

4 changes: 0 additions & 4 deletions test/MockHttp.Tests/MockHttp.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@
<RootNamespace>MockHttp</RootNamespace>
</PropertyGroup>

<ItemGroup>
<Compile Include="..\MockHttp.Testing\XunitAppDomainUnloadHook.cs" Link="XunitAppDomainUnloadHook.cs" />
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\MockHttp.Testing\MockHttp.Testing.csproj" />
<!-- For coverage purposes, override default dependency resolution and instead target specific frameworks. -->
Expand Down

0 comments on commit dca42eb

Please sign in to comment.