Bump Microsoft.Azure.Functions.Worker.Extensions.EventHubs from 5.6.0… #555
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 | |
| jobs: | |
| build-and-test: | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| checks: write | |
| name: Build and Test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 'Checkout' | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup DotNet | |
| uses: actions/setup-dotnet@2016bd2012dba4e32de620c46fe006a3ac9f0602 | |
| with: | |
| global-json-file: global.json | |
| - name: Setup Java JDK | |
| uses: actions/setup-java@f2beeb24e141e01a676f977032f5a29d81c9e27e # v5.1.0 | |
| with: | |
| java-version: 17 | |
| distribution: zulu | |
| - name: Restore dependencies | |
| run: dotnet restore src/GitHubActions.Gates.Samples.sln | |
| - name: Build | |
| run: dotnet build src/GitHubActions.Gates.Samples.sln --no-restore /p:TreatWarningsAsErrors=true | |
| - name: Unit Tests | |
| run: dotnet test src/GitHubActions.Gates.Samples.sln --no-build --verbosity normal --logger:"junit;LogFilePath=unit-tests.xml" --collect:"XPlat Code Coverage" --results-directory ./coverage | |
| - name: Publish Unit Test Results | |
| uses: EnricoMi/publish-unit-test-result-action@27d65e188ec43221b20d26de30f4892fad91df2f | |
| if: always() && github.actor != 'dependabot[bot]' | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} | |
| check_name: Tests Results | |
| files: '**/unit-tests.xml' | |
| report_individual_runs: true | |
| deduplicate_classes_by_file_name: false | |
| - name: Merge coverage reports | |
| if: always() && github.actor != 'dependabot[bot]' | |
| run: | | |
| dotnet tool install --global dotnet-coverage | |
| cd coverage | |
| dotnet-coverage merge -o "${{github.workspace}}/coverage/coverage-merged.xml" -f cobertura -r coverage.cobertura.xml | |
| - name: Code Coverage Summary Report | |
| uses: irongut/CodeCoverageSummary@51cc3a756ddcd398d447c044c02cb6aa83fdae95 | |
| if: always() && github.actor != 'dependabot[bot]' | |
| with: | |
| filename: 'coverage/coverage-merged.xml' | |
| badge: true | |
| format: 'markdown' | |
| output: 'both' | |
| - name: Add code coverage to summary | |
| if: always() && github.actor != 'dependabot[bot]' | |
| run: | | |
| echo "## Code Coverage Summary" >> $GITHUB_STEP_SUMMARY | |
| cat code-coverage-results.md >> $GITHUB_STEP_SUMMARY | |
| - name: Add Coverage PR Comment | |
| uses: marocchino/sticky-pull-request-comment@773744901bac0e8cbb5a0dc842800d45e9b2b405 | |
| if: github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' | |
| with: | |
| recreate: true | |
| path: code-coverage-results.md | |
| code-scan: | |
| permissions: | |
| contents: read | |
| checks: write | |
| security-events: write | |
| name: Code Scanning | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 'Checkout' | |
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 | |
| with: | |
| fetch-depth: 0 | |
| - name: Setup DotNet | |
| uses: actions/setup-dotnet@2016bd2012dba4e32de620c46fe006a3ac9f0602 | |
| with: | |
| global-json-file: global.json | |
| - name: Initialize CodeQL | |
| uses: github/codeql-action/init@5d4e8d1aca955e8d8589aabd499c5cae939e33c7 #v3.29.5 | |
| with: | |
| languages: csharp | |
| queries: +security-extended,security-experimental,security-and-quality | |
| - name: Restore dependencies | |
| run: dotnet restore src/GitHubActions.Gates.Samples.sln | |
| - name: Build | |
| run: dotnet build src/GitHubActions.Gates.Samples.sln --no-restore /p:TreatWarningsAsErrors=true | |
| - name: Perform CodeQL Analysis | |
| uses: github/codeql-action/analyze@5d4e8d1aca955e8d8589aabd499c5cae939e33c7 #v3.29.5 | |
| with: | |
| category: "/language:csharp" |