Skip to content

Commit

Permalink
πŸ‘¨β€πŸ”§ Fix unittests execution
Browse files Browse the repository at this point in the history
  • Loading branch information
roycornelissen committed Oct 20, 2023
1 parent 43d33e8 commit f0c28dc
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/compile-and-test-fast-feedback.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,10 @@ jobs:
run: dotnet build --no-restore

- name: add markdown report logger for frontend project
run: dotnet add unittests/unittests.csproj package LiquidTestReports.Markdown
run: dotnet add unittests/unittests.csproj package LiquidTestReports.Markdown

- name: Test
run: dotnet test --logger "liquid.md;logfilename=testResults.md"
run: dotnet test --logger "liquid.md;logfilename=testResults.md" unittests/unittests.csproj
- name: Output the results to the actions jobsummary
if: always()
run: cat $(find . -name testResults.md) >> $GITHUB_STEP_SUMMARY
7 changes: 7 additions & 0 deletions unittests/UnitTest1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,12 @@ public void numbers_are_even()
{
Assert.IsTrue(true);
}

[TestMethod]
public void Dummy_test()
{
var c = new GloboTicket.Catalog.Artist(Guid.NewGuid(), "Rolling Stones", "Rock'n'Roll");
Assert.AreEqual(c.Name, "Rolling Stones");
}
}
}
5 changes: 4 additions & 1 deletion unittests/unittests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,10 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="LiquidTestReports.Markdown" Version="1.0.9" />
<PackageReference Include="LiquidTestReports.Markdown" Version="1.0.9">
<IncludeAssets>all</IncludeAssets>
<PrivateAssets>all</PrivateAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.3.2" />
<PackageReference Include="MSTest.TestAdapter" Version="2.2.10" />
<PackageReference Include="MSTest.TestFramework" Version="2.2.10" />
Expand Down

0 comments on commit f0c28dc

Please sign in to comment.