mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 07:47:22 +01:00
63 lines
1.5 KiB
YAML
63 lines
1.5 KiB
YAML
name: Static Analysis
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
schedule:
|
|
- cron: '0 0 * * *'
|
|
|
|
jobs:
|
|
static:
|
|
if: github.event_name != 'schedule' || github.repository == 'pestphp/pest'
|
|
name: Static Tests
|
|
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
fail-fast: true
|
|
matrix:
|
|
dependency-version: [prefer-lowest, prefer-stable]
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Setup PHP
|
|
uses: shivammathur/setup-php@v2
|
|
with:
|
|
php-version: 8.3
|
|
tools: composer:v2
|
|
coverage: none
|
|
extensions: sockets
|
|
|
|
- name: Get Composer cache directory
|
|
id: composer-cache
|
|
shell: bash
|
|
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: static-php-8.3-${{ matrix.dependency-version }}-composer-${{ hashFiles('**/composer.json') }}
|
|
restore-keys: |
|
|
static-php-8.3-${{ matrix.dependency-version }}-composer-
|
|
static-php-8.3-composer-
|
|
|
|
- name: Install Dependencies
|
|
run: composer update --prefer-stable --no-interaction --no-progress --ansi
|
|
|
|
- name: Profanity Check
|
|
run: composer test:profanity
|
|
|
|
- name: Type Check
|
|
run: composer test:type:check
|
|
|
|
- name: Type Coverage
|
|
run: composer test:type:coverage
|
|
|
|
- name: Refacto
|
|
run: composer test:refacto
|
|
|
|
- name: Style
|
|
run: composer test:lint
|