diff --git a/.github/workflows/php-cs-fixer.yml b/.github/workflows/php-cs-fixer.yml index 5b8a976..00ec14d 100644 --- a/.github/workflows/php-cs-fixer.yml +++ b/.github/workflows/php-cs-fixer.yml @@ -13,18 +13,30 @@ on: permissions: contents: write +concurrency: + group: ${{ github.head_ref || github.ref || github.run_id }}_php_cs_fixer + cancel-in-progress: true + jobs: - php-cs-fixer: + lint: runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v3 - - name: Run PHP CS Fixer - uses: docker://oskarstark/php-cs-fixer-ga + - uses: actions/checkout@v4 + + - name: Setup PHP + uses: shivammathur/setup-php@v2 with: - args: --config=.php-cs-fixer.dist.php --allow-risky=yes - - name: Commit changes - uses: stefanzweifel/git-auto-commit-action@v4 + php-version: '8.2' + + - name: Install Dependencies + run: | + composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist + + - name: Run PHP CS Fixer + run: ./vendor/bin/php-cs-fixer fix --allow-risky=yes + + - name: Commit Changes + uses: stefanzweifel/git-auto-commit-action@v5 with: commit_message: 🪄 Code Style Fixes + commit_options: '--no-verify' diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a15d439..1fdc01c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -20,14 +20,14 @@ jobs: fail-fast: true matrix: os: [ ubuntu-latest, windows-latest ] - php: [ 8.1, 8.2 ] + php: [ 8.2, 8.3, 8.4 ] stability: [ prefer-lowest, prefer-stable ] name: P${{ matrix.php }} - ${{ matrix.stability }} - ${{ matrix.os }} steps: - name: Checkout code - uses: actions/checkout@v3 + uses: actions/checkout@v5 - name: Setup PHP uses: shivammathur/setup-php@v2 diff --git a/.gitignore b/.gitignore index d10c490..ebba8f6 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ vendor .php-cs-fixer.cache .phpunit.result.cache tests/cache +.phpunit.cache diff --git a/composer.json b/composer.json index de2617b..74b0776 100644 --- a/composer.json +++ b/composer.json @@ -17,15 +17,14 @@ ], "minimum-stability": "stable", "require": { - "php": "^8.1", + "php": "^8.2", "saloonphp/saloon": "^3.0" }, "require-dev": { "friendsofphp/php-cs-fixer": "^3.13", - "pestphp/pest": "^2.3", - "spatie/ray": "^1.34.2", + "pestphp/pest": "^2.3 || ^4.0", "league/flysystem": "^3.12.2", - "orchestra/testbench": "^8.0", + "orchestra/testbench": "^9.15 || ^10.7", "psr/simple-cache": "^3.0" }, "scripts": { diff --git a/src/Data/CachedResponse.php b/src/Data/CachedResponse.php index fcffb93..e9c7b70 100644 --- a/src/Data/CachedResponse.php +++ b/src/Data/CachedResponse.php @@ -15,9 +15,9 @@ class CachedResponse * Constructor */ public function __construct( - readonly public RecordedResponse $recordedResponse, - readonly public DateTimeImmutable $expiresAt, - readonly public int $ttl, + public readonly RecordedResponse $recordedResponse, + public readonly DateTimeImmutable $expiresAt, + public readonly int $ttl, ) { // }