Skip to content

Commit

Permalink
ci: speed up scenario tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sjinks committed May 31, 2024
1 parent 4b12789 commit bbebfad
Showing 1 changed file with 16 additions and 6 deletions.
22 changes: 16 additions & 6 deletions .github/workflows/test-features.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,22 @@ jobs:
run: devcontainer features test -p features --skip-scenarios -f ${{ matrix.feature }} -i ${{ matrix.baseImage }}

scenarios:
name: 'Scenario: ${{ matrix.test }}'
name: 'Scenario: ${{ matrix.test.feature }} ${{ matrix.test.filter }}'
runs-on: ubuntu-latest
permissions:
contents: read
strategy:
fail-fast: false
matrix:
test:
- mailpit
- php
- ssh
- feature: mailpit
- feature: php
filter: php81
- feature: php
filter: php82
- feature: php
filter: php83
- feature: ssh
steps:
- name: Checkout repository
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
Expand All @@ -83,8 +88,13 @@ jobs:
done
- name: Run tests
run: devcontainer features test -p features --skip-autogenerated --skip-duplicated -f "${{ matrix.test }}"

run: |
if [ -z "${{ matrix.test.filter }}" ]; then
devcontainer features test -p features --skip-autogenerated --skip-duplicated -f "${{ matrix.test }}"
else
devcontainer features test -p features --skip-autogenerated --skip-duplicated -f "${{ matrix.test }}" --filter "${{ matrix.test.filter }}"
fi
global:
name: 'Global Scenario: ${{ matrix.test }}'
runs-on: ubuntu-latest
Expand Down

0 comments on commit bbebfad

Please sign in to comment.