From 3b230f9a3f656879d1179a0e2fbbb1ee5772afc6 Mon Sep 17 00:00:00 2001 From: Juan Martinez Ramirez Date: Thu, 11 Apr 2024 15:09:34 -0600 Subject: [PATCH] Update reports names to include package version --- .github/workflows/main.yml | 29 +++++++++++++++++------------ 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index b7ca8cf9d..c3e4f2dcb 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -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 @@ -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 @@ -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 @@ -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 @@ -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