Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 33 additions & 3 deletions .github/workflows/dotnet_test_runner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ name: .NET Test Runner
on:
workflow_dispatch:
push:
branches: [ "main" ]
branches: [ "main" ]
pull_request:
branches: [ "main" ]

jobs:

Expand Down Expand Up @@ -34,10 +36,38 @@ jobs:
with:
dotnet-version: 10.x

- name: Run tests
- name: Run tests with coverage
run: >
dotnet test
--configuration Release
--logger "GitHubActions;summary.includePassedTests=true;summary.includeSkippedTests=true"
--collect:"XPlat Code Coverage"
--results-directory ./coverage
--
RunConfiguration.CollectSourceInformation=true
RunConfiguration.CollectSourceInformation=true
DataCollectionRunSettings.DataCollectors.DataCollector.Configuration.Format=opencover

- name: Upload coverage to Codecov
uses: codecov/codecov-action@18283e04ce6e62d37312384ff67231eb8fd56d24
with:
directory: ./Tests/TyKonKet.BarcodeGenerator.Tests/coverage
files: '**/*.xml'
fail_ci_if_error: false
verbose: true

- name: Generate coverage report
if: always()
run: |
dotnet tool install -g dotnet-reportgenerator-globaltool
reportgenerator \
-reports:"coverage/**/*.xml" \
-targetdir:"coverage/report" \
-reporttypes:"Html;Badges" \
-verbosity:Info

- name: Upload coverage report artifact
if: always()
uses: actions/upload-artifact@v4
with:
name: coverage-report
path: Tests/TyKonKet.BarcodeGenerator.Tests/coverage/report
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,12 @@ We welcome contributions from the community! Here's how you can help:
- Improve documentation and examples
- Share your use cases and feedback

**Testing:**
- Run the comprehensive test suite: `dotnet test --configuration Release`
- Generate code coverage reports: `./scripts/run-coverage.sh` (Linux/macOS) or `.\scripts\run-coverage.ps1` (Windows)
- Review [test documentation](Tests/TyKonKet.BarcodeGenerator.Tests/README.md) for testing guidelines
- Ensure 80%+ code coverage for new features

---

## 📄 License
Expand Down
1 change: 1 addition & 0 deletions Tests/TyKonKet.BarcodeGenerator.Tests/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
coverage/
175 changes: 0 additions & 175 deletions Tests/TyKonKet.BarcodeGenerator.Tests/BarcodeOptionsTest.cs

This file was deleted.

Loading
Loading