Update dependency symfony/http-client to v7.1.7 [SECURITY] #3993
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Tests | |
on: | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
test: | |
name: Symfony (PHP 8.3) | |
runs-on: ubuntu-latest | |
env: | |
SYMFONY_DEPRECATIONS_HELPER: disabled | |
# Docs: https://docs.github.com/en/actions/using-containerized-services | |
services: | |
mysql: | |
image: mysql:latest | |
env: | |
MYSQL_ALLOW_EMPTY_PASSWORD: false | |
MYSQL_ROOT_PASSWORD: symfony | |
MYSQL_DATABASE: symfony | |
ports: | |
- 3306/tcp | |
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Use Node.js 21.x | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 21.x | |
# Docs: https://github.com/shivammathur/setup-php | |
- name: Setup PHP | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: 8.3 | |
extensions: mbstring, xml, ctype, iconv, intl, mysql | |
coverage: pcov | |
- name: Get composer cache directory | |
id: composer-cache | |
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- name: Cache composer dependencies | |
uses: actions/cache@v4 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }} | |
restore-keys: ${{ runner.os }}-composer- | |
- name: Install Composer dependencies | |
run: composer install --no-progress --prefer-dist --optimize-autoloader | |
- name: Install npm dependencies | |
run: npm ci && npm run build | |
- name: Run Migration | |
run: | | |
php bin/console doctrine:migrations:migrate --no-interaction || echo "No migrations found or migration failed" | |
env: | |
DATABASE_URL: mysql://root:symfony@127.0.0.1:${{ job.services.mysql.ports['3306'] }}/symfony?serverVersion=8.0&charset=utf8mb4 | |
- name: Run functional and integration test suite | |
run: php -dmax_execution_time=300 vendor/bin/phpunit --testsuite functional,integration | |
env: | |
DATABASE_URL: mysql://root:symfony@127.0.0.1:${{ job.services.mysql.ports['3306'] }}/symfony?serverVersion=8.0&charset=utf8mb4 | |
- name: Run unit test suite | |
run: php -dmax_execution_time=300 -dpcov.enabled=1 -dpcov.exclude="~vendor~" vendor/bin/phpunit --testsuite unit --coverage-clover ./.coverage/coverage.xml | |
env: | |
DATABASE_URL: mysql://root:symfony@127.0.0.1:${{ job.services.mysql.ports['3306'] }}/symfony?serverVersion=8.0&charset=utf8mb4 | |
- name: Upload coverage to codecov | |
uses: codecov/codecov-action@v4 | |
with: | |
exclude: resources,tests | |
token: ${{ secrets.CODECOV_TOKEN }} | |
directory: ./.coverage | |
- name: Check coverage | |
run: test ! -f ./.coverage/coverage.xml || php vendor/bin/phpfci inspect ./.coverage/coverage.xml --exit-code-on-failure --reportText |