Skip to content

Add vimeo/psalm and psalm/plugin-phpunit (#1230) #151

Add vimeo/psalm and psalm/plugin-phpunit (#1230)

Add vimeo/psalm and psalm/plugin-phpunit (#1230) #151

Workflow file for this run

name: Tests
on:
push:
pull_request:
# Allow manually triggering the workflow.
workflow_dispatch:
jobs:
phpunit:
name: PHPUnit on PHP ${{ matrix.php }}
runs-on: ubuntu-latest
strategy:
matrix:
php: ['7.4', '8.0', '8.1', '8.2']
continue-on-error: ${{ matrix.php == '8.2' }}
steps:
- name: Checkout Code
uses: actions/checkout@v2
- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
ini-values: zend.assertions=1, error_reporting=-1, display_errors=On
tools: composer:v2
extensions: mongodb, redis
coverage: xdebug
- name: Setup Problem Matchers
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"
- name: Install Dependencies
if: ${{ matrix.php != '8.2' }}
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --no-interaction --no-progress
- name: Install Dependencies (ignore platform)
if: ${{ matrix.php == '8.2' }}
uses: nick-invision/retry@v1
with:
timeout_minutes: 5
max_attempts: 5
command: composer update --no-interaction --no-progress --ignore-platform-req=php
- name: Execute PHPUnit
run: vendor/bin/phpunit