Skip to content

Commit

Permalink
ci: Use collector for test.yaml (#140)
Browse files Browse the repository at this point in the history
  • Loading branch information
hoxbro authored Oct 8, 2024
1 parent ca41e56 commit 651f3f2
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -112,32 +112,30 @@ jobs:
name: unit:${{ matrix.environment }}:${{ matrix.os }}
needs: [pre_commit, setup, pixi_lock]
runs-on: ${{ matrix.os }}
if: needs.setup.outputs.code_change == 'true'
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.setup.outputs.matrix) }}
timeout-minutes: 120
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
if: needs.setup.outputs.code_change == 'true'
with:
environments: ${{ matrix.environment }}
- name: Test Unit
if: needs.setup.outputs.code_change == 'true'
run: |
pixi run -e ${{ matrix.environment }} test-unit $COV
- name: Test Examples
if: needs.setup.outputs.code_change == 'true'
run: |
pixi run -e ${{ matrix.environment }} test-example
- uses: codecov/codecov-action@v4
if: needs.setup.outputs.code_change == 'true'
with:
token: ${{ secrets.CODECOV_TOKEN }}

core_test_suite:
name: core:${{ matrix.environment }}:${{ matrix.os }}
needs: [pre_commit, setup, pixi_lock]
runs-on: ${{ matrix.os }}
if: needs.setup.outputs.code_change == 'true'
strategy:
fail-fast: false
matrix:
Expand All @@ -146,18 +144,17 @@ jobs:
timeout-minutes: 120
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
if: needs.setup.outputs.code_change == 'true'
with:
environments: ${{ matrix.environment }}
- name: Test Unit
if: needs.setup.outputs.code_change == 'true'
run: |
pixi run -e ${{ matrix.environment }} test-unit
benchmark_test_suite:
name: benchmark:${{ matrix.environment }}:${{ matrix.os }}
needs: [pre_commit, setup, pixi_lock]
runs-on: ${{ matrix.os }}
if: needs.setup.outputs.code_change == 'true'
strategy:
fail-fast: false
matrix:
Expand All @@ -166,12 +163,20 @@ jobs:
timeout-minutes: 120
steps:
- uses: holoviz-dev/holoviz_tasks/pixi_install@v0
if: needs.setup.outputs.code_change == 'true'
with:
environments: ${{ matrix.environment }}
- name: Run benchmarks
uses: CodSpeedHQ/action@v3
if: needs.setup.outputs.code_change == 'true'
with:
token: ${{ secrets.CODSPEED_TOKEN }}
run: pixi run -e ${{ matrix.environment }} test-benchmark

result_test_suite:
name: result:test
needs: [unit_test_suite, core_test_suite]
if: always()
runs-on: ubuntu-latest
steps:
- name: check for failures
if: contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled')
run: echo job failed && exit 1

0 comments on commit 651f3f2

Please sign in to comment.