Skip to content

Commit

Permalink
remove matrix strategy for integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
DaveSkender committed Nov 2, 2024
1 parent 205a5d1 commit a2a3456
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 22 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/test-indicators.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ jobs:
--verbosity normal
--logger trx
--collect:"XPlat Code Coverage"
--results-directory ./test-indicators
--results-directory ./test-results
# the remaining steps are only needed from one primary instance

Expand All @@ -62,12 +62,12 @@ jobs:
if: env.IS_PRIMARY == 'true' && always()
with:
name: Test results
path: ./test-indicators/**/*.trx
path: ./test-results/**/*.trx
reporter: dotnet-trx

- name: Publish coverage to Codacy
uses: codacy/codacy-coverage-reporter-action@v1
if: env.IS_PRIMARY == 'true'
with:
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }}
coverage-reports: ./test-indicators/**/coverage.cobertura.xml
coverage-reports: ./test-results/**/coverage.cobertura.xml
25 changes: 6 additions & 19 deletions .github/workflows/test-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,13 @@ on:
jobs:
test:
name: integration tests
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest

permissions:
contents: read
actions: read
checks: write

strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
dotnet-version: ["6.x", "8.x"]

env:

# identifying primary configuration so only one reports coverage
IS_PRIMARY: ${{ matrix.os == 'ubuntu-latest' && matrix.dotnet-version == '8.x' }}

steps:

- name: Checkout source
Expand All @@ -36,7 +26,7 @@ jobs:
id: dotnet-new
uses: actions/setup-dotnet@v4
with:
dotnet-version: ${{ matrix.dotnet-version }}
dotnet-version: "8.x"
dotnet-quality: "ga"

- name: Build library
Expand All @@ -53,12 +43,9 @@ jobs:
--no-build
--verbosity normal
--logger trx
--results-directory ./test-other
# the remaining steps are only needed from one primary instance
--results-directory ./test-results
- name: Test integrations
if: env.IS_PRIMARY == 'true'
env:
ALPACA_KEY: ${{ secrets.ALPACA_KEY }}
ALPACA_SECRET: ${{ secrets.ALPACA_SECRET }}
Expand All @@ -68,12 +55,12 @@ jobs:
--no-build
--verbosity normal
--logger trx
--results-directory ./test-other
--results-directory ./test-results
- name: Post test summary
uses: dorny/test-reporter@v1
if: env.IS_PRIMARY == 'true' && always()
if: always()
with:
name: Test results
path: ./test-other/**/*.trx
path: ./test-results/**/*.trx
reporter: dotnet-trx

0 comments on commit a2a3456

Please sign in to comment.