removed preview #43
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| permissions: | |
| contents: read | |
| env: | |
| DOTNET_NOLOGO: true | |
| DOTNET_CLI_TELEMETRY_OPTOUT: true | |
| DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '10.0.x' | |
| - name: Restore dependencies | |
| run: dotnet restore AgentGuard.slnx | |
| - name: Build | |
| run: dotnet build AgentGuard.slnx --no-restore --configuration Release | |
| - name: Test | |
| run: | | |
| dotnet test AgentGuard.slnx \ | |
| --no-build \ | |
| --configuration Release \ | |
| --verbosity normal \ | |
| --logger "trx;LogFileName=results.trx" \ | |
| --collect:"XPlat Code Coverage" \ | |
| --results-directory TestResults | |
| - name: Upload test results | |
| uses: actions/upload-artifact@v4 | |
| if: always() | |
| with: | |
| name: test-results | |
| path: TestResults/ | |
| - name: Upload coverage | |
| uses: actions/upload-artifact@v4 | |
| if: always() | |
| with: | |
| name: coverage | |
| path: TestResults/**/coverage.cobertura.xml | |
| - name: Pack NuGet packages | |
| run: | | |
| dotnet pack AgentGuard.slnx \ | |
| --no-build \ | |
| --configuration Release \ | |
| --output artifacts/packages | |
| - name: Upload NuGet packages | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: nuget-packages | |
| path: | | |
| artifacts/packages/*.nupkg | |
| artifacts/packages/*.snupkg |