Skip to content

delete unstable tests and skip redis tests if the redis extension is not installed #61

delete unstable tests and skip redis tests if the redis extension is not installed

delete unstable tests and skip redis tests if the redis extension is not installed #61

Workflow file for this run

name: codestyle
on:
pull_request:
workflow_dispatch:
jobs:
code-coverage:
name: Code Coverage
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
php-version:
- 8.2
services:
redis:
image: redis
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 6379:6379
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install PHP with extensions
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
coverage: pcov
tools: composer:v2
extensions: swoole, redis, pcntl
- name: Install dependencies with composer
run: composer update --no-ansi --no-interaction --no-progress
- name: Code Style
run: vendor/bin/pint --test --config ./pint.json
- name: Collect code coverage with phpunit
run: vendor/bin/phpunit --coverage-clover=coverage.xml
env:
REDIS_HOST: localhost
REDIS_PORT: 6379
- name: Send code coverage report to Codecov.io
uses: codecov/codecov-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage.xml