Skip to content

Commit

Permalink
Update reports names to include package version
Browse files Browse the repository at this point in the history
  • Loading branch information
sfc-gh-jmartinezramirez committed Apr 11, 2024
1 parent 3a6ff67 commit 3b230f9
Showing 1 changed file with 17 additions and 12 deletions.
29 changes: 17 additions & 12 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,27 +73,28 @@ jobs:
- name: Run Tests
run: |
cd Snowflake.Data.Tests
dotnet-coverage collect "dotnet test --framework ${{ matrix.dotnet }} --no-build -l console;verbosity=normal" --output windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml --output-format cobertura --settings coverage.config
dotnet-coverage collect "dotnet test --framework ${{ matrix.dotnet }} --no-build -l console;verbosity=normal" --output windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml --output-format cobertura --settings coverage.config
env:
snowflake_cloud_env: ${{ matrix.cloud_env }}
pkg_version: ${{ matrix.pkg_version }}
net_version: ${{ matrix.dotnet }}
- name: Upload Code Coverage Report
uses: actions/upload-artifact@v3
with:
name: code-coverage-report
path: Snowflake.Data.Tests\windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml
path: Snowflake.Data.Tests\windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml
- name: Upload Test Performance Report
uses: actions/upload-artifact@v3
with:
name: tests-performance
path: Snowflake.Data.Tests\windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_performance.csv
path: Snowflake.Data.Tests\windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_performance.csv
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
# without the token code cov may fail because of Github limits https://github.com/codecov/codecov-action/issues/557
token: ${{ secrets.CODE_COV_UPLOAD_TOKEN }}
fail_ci_if_error: true
files: Snowflake.Data.Tests\windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml
files: Snowflake.Data.Tests\windows_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml

test-linux:
name: Tests on Linux
Expand All @@ -103,6 +104,7 @@ jobs:
matrix:
dotnet: ['net6.0']
cloud_env: ['AZURE', 'GCP', 'AWS']
pkg_version: ['current']
steps:
- uses: actions/checkout@v3
- name: Setup Dotnet
Expand Down Expand Up @@ -130,27 +132,28 @@ jobs:
- name: Run Tests
run: |
cd Snowflake.Data.Tests
dotnet-coverage collect "dotnet test --framework ${{ matrix.dotnet }} --no-build -l console;verbosity=normal" --output linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml --output-format cobertura --settings coverage.config
dotnet-coverage collect "dotnet test --framework ${{ matrix.dotnet }} --no-build -l console;verbosity=normal" --output linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml --output-format cobertura --settings coverage.config
env:
snowflake_cloud_env: ${{ matrix.cloud_env }}
pkg_version: ${{ matrix.pkg_version }}
net_version: ${{ matrix.dotnet }}
- name: Upload Code Coverage Report
uses: actions/upload-artifact@v3
with:
name: code-coverage-report
path: Snowflake.Data.Tests/linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml
path: Snowflake.Data.Tests/linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml
- name: Upload Test Performance Report
uses: actions/upload-artifact@v3
with:
name: tests-performance
path: Snowflake.Data.Tests/linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_performance.csv
path: Snowflake.Data.Tests/linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_performance.csv
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
# without the token code cov may fail because of Github limits https://github.com/codecov/codecov-action/issues/557
token: ${{ secrets.CODE_COV_UPLOAD_TOKEN }}
fail_ci_if_error: true
files: Snowflake.Data.Tests/linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml
files: Snowflake.Data.Tests/linux_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml

test-mac:
name: Tests on MAC
Expand All @@ -160,6 +163,7 @@ jobs:
matrix:
dotnet: ['net6.0']
cloud_env: ['AZURE', 'GCP', 'AWS']
pkg_version: ['current']
steps:
- uses: actions/checkout@v3
- name: Setup Dotnet
Expand Down Expand Up @@ -187,24 +191,25 @@ jobs:
- name: Run Tests
run: |
cd Snowflake.Data.Tests
dotnet-coverage collect "dotnet test --framework ${{ matrix.dotnet }} --no-build -l console;verbosity=normal" --output macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml --output-format cobertura --settings coverage.config
dotnet-coverage collect "dotnet test --framework ${{ matrix.dotnet }} --no-build -l console;verbosity=normal" --output macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml --output-format cobertura --settings coverage.config
env:
snowflake_cloud_env: ${{ matrix.cloud_env }}
pkg_version: ${{ matrix.pkg_version }}
net_version: ${{ matrix.dotnet }}
- name: Upload Code Coverage Report
uses: actions/upload-artifact@v3
with:
name: code-coverage-report
path: Snowflake.Data.Tests/macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml
path: Snowflake.Data.Tests/macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml
- name: Upload Test Performance Report
uses: actions/upload-artifact@v3
with:
name: tests-performance
path: Snowflake.Data.Tests/macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_performance.csv
path: Snowflake.Data.Tests/macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_performance.csv
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
# without the token code cov may fail because of Github limits https://github.com/codecov/codecov-action/issues/557
token: ${{ secrets.CODE_COV_UPLOAD_TOKEN }}
fail_ci_if_error: true
files: Snowflake.Data.Tests/macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_coverage.xml
files: Snowflake.Data.Tests/macos_${{ matrix.dotnet }}_${{ matrix.cloud_env }}_${{ matrix.pkg_version }}_coverage.xml

0 comments on commit 3b230f9

Please sign in to comment.