diff --git a/.github/workflows/gate.yml b/.github/workflows/gate.yml index 2d0724fd..f5213c42 100644 --- a/.github/workflows/gate.yml +++ b/.github/workflows/gate.yml @@ -1,6 +1,7 @@ name: Build on: + workflow_dispatch: push: branches: [ main ] pull_request: @@ -119,9 +120,45 @@ jobs: reporter: dotnet-trx only-summary: 'true' + linux: + + runs-on: ubuntu-latest + + permissions: + checks: write + + steps: + - uses: actions/checkout@v3 + - name: Setup .NET Core + uses: actions/setup-dotnet@v2 + with: + dotnet-version: 6.0.x + - name: Install dependencies + run: dotnet restore + - name: Build + run: dotnet build --configuration Release --no-restore + - name: Test + run: dotnet test --no-restore --verbosity normal -f net6.0 /p:CollectCoverage=true /p:CoverletOutput=TestResults/ /p:CoverletOutputFormat=lcov --logger "trx;LogFileName=results.trx" + - name: Publish coverage report to coveralls.io + uses: coverallsapp/github-action@master + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + path-to-lcov: BitFaster.Caching.UnitTests/TestResults/coverage.net6.0.info + flag-name: linux + parallel: true + - name: Generate unit test report + uses: phoenix-actions/test-reporting@v12 + id: unit-test-report-linux + if: success() || failure() + with: + name: test results (linux net6.0) + path: BitFaster.Caching.UnitTests/TestResults/results.trx + reporter: dotnet-trx + only-summary: 'true' + coverage: - needs: [win, mac] + needs: [win, mac, linux] runs-on: ubuntu-latest