rename / change the SymfonyCache to be a Psr6CacheItemPool adapter in… #51
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: GitHub Build | |
on: | |
push: | |
jobs: | |
sanity-check: | |
runs-on: ubuntu-24.04 | |
env: | |
key: cache-v2 | |
extensions: apc, redis, apcu, memcache, memcached | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup PHP {{ matrix.php-versions }} | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: 8.0 | |
tools: composer | |
extensions: ${{ env.extensions }} | |
ini-values: apc.enable_cli=1 | |
- name: Get composer cache directory | |
id: composer-cache | |
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- name: Cache vendor | |
uses: actions/cache@v4 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} | |
restore-keys: ${{ runner.os }}-composer- | |
- name: Validate composer.json | |
run: composer validate --strict | |
- name: Install dependencies | |
run: composer install --prefer-dist --no-progress | |
- name: format check etc | |
run: composer check-format | |
- name: phpstan | |
run: composer phpstan | |
- name: psalm | |
run: composer psalm | |
unit-test: | |
runs-on: ubuntu-24.04 | |
needs: [sanity-check] | |
env: | |
key: cache-v1 | |
extensions: apc, redis, apcu, memcache, memcached | |
services: | |
redis: | |
image: redis | |
ports: | |
- 6379:6379 | |
options: --health-cmd="redis-cli ping" --health-interval=10s --health-timeout=5s --health-retries=3 | |
memcache: | |
image: memcached | |
ports: | |
- 11211:11211 | |
strategy: | |
matrix: | |
php-versions: [ '8.0', '8.1', '8.2', '8.3' ] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup PHP {{ matrix.php-versions }} | |
uses: shivammathur/setup-php@v2 | |
with: | |
php-version: ${{ matrix.php-versions }} | |
tools: composer | |
extensions: ${{ env.extensions }} | |
ini-values: apc.enable_cli=1 | |
- name: Get composer cache directory | |
id: composer-cache | |
run: echo "dir=$(composer config cache-files-dir)" >> $GITHUB_OUTPUT | |
- name: Cache vendor/ | |
uses: actions/cache@v4 | |
with: | |
path: ${{ steps.composer-cache.outputs.dir }} | |
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} | |
restore-keys: ${{ runner.os }}-composer- | |
- name: Install dependencies | |
run: composer install --prefer-dist --no-progress | |
- name: psalm | |
run: composer psalm | |
- name: Run test suite | |
run: composer test | |
env: | |
REDIS_HOST: localhost | |
MEMCACHE_HOST: localhost |