Skip to content

Commit

Permalink
Code coverage for e2e tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Enkidu93 committed Nov 6, 2023
1 parent af79060 commit ccfff1c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/ci-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,12 @@ jobs:
run: sudo mkdir -p /var/lib/serval && sudo chmod 777 /var/lib/serval

- name: Test
run: dotnet test --no-build --verbosity normal --filter "TestCategory!=slow&TestCategory=E2E"
run: dotnet test --no-build --verbosity normal --filter "TestCategory!=slow&TestCategory=E2E" --collect:"Xplat Code Coverage"

- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

- name: Debug network (Post test)
if: ${{ failure() }}
Expand Down
6 changes: 6 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,12 @@ services:
- --no-launch-profile
- --additionalProbingPath
- /root/.nuget/packages
deploy:
resources:
limits:
memory: 2.5G
reservations:
memory: 2.5G
mongo:
hostname: mongo
image: mongo:6.0
Expand Down
4 changes: 4 additions & 0 deletions tests/Serval.E2ETests/Serval.E2ETests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="coverlet.collector" Version="6.0.0">
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.5.0" />
<PackageReference Include="nunit" Version="3.13.3" />
<PackageReference Include="NUnit3TestAdapter" Version="4.4.2" />
Expand Down

0 comments on commit ccfff1c

Please sign in to comment.