|
5 | 5 | branches: [ main ] |
6 | 6 | pull_request: |
7 | 7 | branches: [ main ] |
8 | | - |
9 | 8 |
|
10 | | - # Allows you to run this workflow manually from the Actions tab |
11 | 9 | workflow_dispatch: |
12 | 10 |
|
13 | 11 | jobs: |
14 | 12 |
|
15 | 13 | build-and-test: |
16 | 14 | runs-on: ubuntu-latest |
17 | | - |
| 15 | + |
18 | 16 | steps: |
19 | 17 |
|
20 | | - - name: checkout |
21 | | - uses: actions/checkout@v3 |
22 | | - |
23 | | - - name: Setup .NET |
24 | | - uses: actions/setup-dotnet@v3 |
25 | | - with: |
26 | | - dotnet-version: 7.0.x |
27 | | - |
28 | | - - name: Restore dependencies |
29 | | - run: dotnet restore |
30 | | - |
31 | | - - name: Build |
32 | | - run: dotnet build --no-restore |
33 | | - |
34 | | - - name: Test |
35 | | - run: dotnet test --no-build --logger 'trx;LogFileName=test-results.trx' |
36 | | - |
37 | | - - name: Collect Code Coverage |
38 | | - run: dotnet test --no-build --verbosity normal /p:CollectCoverage=true /p:CoverletOutputFormat=lcov /p:CoverletOutput=ManagedCode.Storage.Tests/lcov.info |
39 | | - |
40 | | - |
41 | | - - name: NDepend |
42 | | - uses: ndepend/ndepend-action@v1 |
43 | | - with: |
44 | | - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
45 | | - license: ${{ secrets.NDEPENDLICENSE }} |
46 | | - coveragefolder: ManagedCode.Storage.Tests/lcov.info |
47 | | - baseline: recent |
48 | | - #baseline: main_recent |
49 | | - |
50 | | - - name : coverlet |
51 | | - uses: b3b00/coverlet-action@1.1.9 |
52 | | - with: |
53 | | - testProject: 'ManagedCode.Storage.Tests/ManagedCode.Storage.Tests.csproj' |
54 | | - output: 'lcov.info' |
55 | | - outputFormat: 'lcov' |
56 | | - excludes: '[program]*,[test]test.*' |
57 | | - - name: coveralls |
58 | | - uses: coverallsapp/github-action@master |
59 | | - with: |
60 | | - github-token: ${{secrets.GITHUB_TOKEN }} |
61 | | - path-to-lcov: ManagedCode.Storage.Tests/lcov.info |
62 | | - |
| 18 | + - name: checkout |
| 19 | + uses: actions/checkout@v4 |
| 20 | + |
| 21 | + - name: Setup .NET |
| 22 | + uses: actions/setup-dotnet@v3 |
| 23 | + with: |
| 24 | + dotnet-version: 7.0.x |
| 25 | + |
| 26 | + - name: Restore dependencies |
| 27 | + run: dotnet restore |
| 28 | + |
| 29 | + - name: Build |
| 30 | + run: dotnet build |
| 31 | + |
| 32 | + - name: Test |
| 33 | + run: dotnet test /p:CollectCoverage=true /p:CoverletOutput=coverage /p:CoverletOutputFormat=opencover |
| 34 | + |
| 35 | + |
| 36 | + - name: NDepend |
| 37 | + uses: ndepend/ndepend-action@v1 |
| 38 | + with: |
| 39 | + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| 40 | + license: ${{ secrets.NDEPENDLICENSE }} |
| 41 | + coveragefolder: ${{ github.workspace }}/ManagedCode.Storage.IntegrationTests |
| 42 | + baseline: main_recent |
| 43 | + retention-days: 15 |
| 44 | + #stopIfQGFailed: true |
63 | 45 |
|
| 46 | + - name: Upload coverage reports to Codecov |
| 47 | + uses: codecov/codecov-action@v3 |
| 48 | + env: |
| 49 | + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |
0 commit comments