Skip to content

Commit

Permalink
run tests with specific Symfony versions
Browse files Browse the repository at this point in the history
  • Loading branch information
VasekPurchart committed Dec 4, 2024
1 parent c248813 commit bba0923
Showing 1 changed file with 19 additions and 2 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
run: 'bin/phing composer-dependencies'

tests:
name: 'Tests - PHP ${{ matrix.php-version }}, ${{ matrix.composer-dependencies }} dependencies'
name: 'Tests - PHP ${{ matrix.php-version }}, Symfony: ${{ matrix.symfony-version}}, Composer ${{ matrix.composer-dependencies }} dependencies'
needs: 'lint'
runs-on: 'ubuntu-latest'

Expand All @@ -138,6 +138,12 @@ jobs:
- '7.2'
- '7.3'
- '7.4'
symfony-version:
# - '4.0' matthiasnoback/symfony-dependency-injection-test 4.3.0 requires symfony/config ^4.4 || ^5.3 || ^6.0
# - '4.1' matthiasnoback/symfony-dependency-injection-test 4.3.0 requires symfony/config ^4.4 || ^5.3 || ^6.0
# - '4.2' matthiasnoback/symfony-dependency-injection-test 4.3.0 requires symfony/config ^4.4 || ^5.3 || ^6.0
# - '4.3' matthiasnoback/symfony-dependency-injection-test 4.3.0 requires symfony/config ^4.4 || ^5.3 || ^6.0
- '4.4'
composer-dependencies:
- 'highest'
- 'lowest'
Expand All @@ -163,6 +169,17 @@ jobs:
uses: 'ramsey/[email protected]'
with:
dependency-versions: '${{ matrix.composer-dependencies }}'
-
name: 'Install specific versions'
env:
COMPOSER_PREFER_LOWEST: ${{ matrix.composer-dependencies == 'lowest' && 1 || 0 }}
run: |
composer update \
--ansi \
--with 'symfony/config=${{ matrix.symfony-version }}.*' \
--with 'symfony/dependency-injection=${{ matrix.symfony-version }}.*' \
--with 'symfony/http-kernel=${{ matrix.symfony-version }}.*' \
--with 'symfony/yaml=${{ matrix.symfony-version }}.*'
-
name: 'Run tests'
run: 'bin/phing tests'
Expand All @@ -171,7 +188,7 @@ jobs:
env:
COVERALLS_REPO_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
COVERALLS_PARALLEL: true
COVERALLS_FLAG_NAME: 'php-${{ matrix.php-version }}+${{ matrix.composer-dependencies }}-dependencies'
COVERALLS_FLAG_NAME: 'php-${{ matrix.php-version }}+symfony-${{ matrix.symfony-version }}+${{ matrix.composer-dependencies }}-dependencies'
run: |
wget https://github.com/php-coveralls/php-coveralls/releases/download/v2.4.3/php-coveralls.phar
php php-coveralls.phar --verbose --config build/coveralls.yml
Expand Down

0 comments on commit bba0923

Please sign in to comment.