Skip to content

fix: use OIDC for Codecov (#180) #199

fix: use OIDC for Codecov (#180)

fix: use OIDC for Codecov (#180) #199

Workflow file for this run

name: .NET
on:
push:
branches: [master]
pull_request:
branches: [master]
permissions:
contents: read
id-token: write
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Install .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8
- name: Install .NET Framework (add MSBuild to Path)
uses: microsoft/setup-msbuild@v2
with:
msbuild-architecture: x64
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Test
# Strong name requires disabling xUnit app domains in order to get coverage using coverlet
# https://github.com/MarcoRossignoli/coverlet/blob/master/Documentation/KnownIssues.md#tests-fail-if-assembly-is-strong-named
run: dotnet test --no-build --verbosity normal --collect:"XPlat Code Coverage" test/Amazon.SecretsManager.Extensions.Caching.UnitTests -- RunConfiguration.DisableAppDomain=true
- name: Codecov
uses: codecov/codecov-action@v5
with:
directory: test/Amazon.SecretsManager.Extensions.Caching.UnitTests/TestResults
fail_ci_if_error: true
use_oidc: true