testcontainers / testcontainers-dotnet

A library to support tests with throwaway instances of Docker containers for all compatible .NET Standard versions.
https://dotnet.testcontainers.org
MIT License
3.65k stars 250 forks source link

chore: Add Test Reporter GitHub Action #1095

Closed 0xced closed 4 months ago

0xced commented 5 months ago

What does this PR do?

This pull request introduces Test Reporter in the CI/CD pipeline to get visibility over the test that has been run as part of a GitHub action run.

Why is it important?

It's extremely hard to find a failed test deep inside the Run Tests step logs. Using Test Reporter is a very convenient way to see all the tests (passes/failed/skipped) at a glance.

Related issues

Related to https://github.com/testcontainers/testcontainers-dotnet/issues/1092#issuecomment-1907994037 where I absolutely had to do something to figure out which tests were failing.

How to test this PR

Just look at the results in a GitHub action run. For example: https://github.com/0xced/testcontainers-dotnet/actions/runs/7642079627/job/20821394193

And here's a screenshot in case in case this job expires.

Screenshot of a run with all tests passing

netlify[bot] commented 5 months ago

Deploy Preview for testcontainers-dotnet ready!

Name Link
Latest commit 38242a0c8432e946e354d43c97d53e16b7b06ef3
Latest deploy log https://app.netlify.com/sites/testcontainers-dotnet/deploys/65c7c86c56e42d0008cad461
Deploy Preview https://deploy-preview-1095--testcontainers-dotnet.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

0xced commented 5 months ago

The new Test Report action doesn't show up in https://github.com/testcontainers/testcontainers-dotnet/actions and is not executed.

According to this comment on Stack Overflow the .github/workflows/test-report.yml file must be added to the main branch first.