Skip to content

Commit

Permalink
Merge pull request #18 from plunkettscott/laravel-11-php-83
Browse files Browse the repository at this point in the history
Support Laravel 11 and PHP 8.3
  • Loading branch information
plunkettscott authored Apr 12, 2024
2 parents 0042416 + 7aa51b0 commit 9d6abff
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 12 deletions.
21 changes: 12 additions & 9 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,7 @@ on:
push:
branches:
- main
pull_request:
schedule:
- cron: '0 0 * * *'

pull_request: {}
jobs:
tests:
runs-on: ubuntu-22.04
Expand All @@ -22,14 +19,20 @@ jobs:
strategy:
fail-fast: true
matrix:
php: [8.2]
laravel: [10]
php: [8.2, 8.3]
laravel: [10, 11]
include:
- laravel: 10
testbench: 8
- laravel: 11
testbench: 9


name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }}
name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }} - Testbench ${{ matrix.testbench }}

steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
Expand All @@ -42,7 +45,7 @@ jobs:

- name: Install dependencies
run: |
composer require "illuminate/contracts=^${{ matrix.laravel }}" --dev --no-update
composer require "orchestra/testbench=^${{ matrix.testbench }}" "laravel/framework=^${{ matrix.laravel }}" --dev --no-update
composer update --prefer-dist --no-interaction --no-progress
- name: Execute tests
Expand Down
2 changes: 1 addition & 1 deletion src/Watchers/CacheWatcher.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function recordCacheSet(KeyWritten $event): void
$ttl = property_exists($event, 'minutes')
? $event->minutes * 60
: $event->seconds;

$this->addEvent('cache set', [
'key' => $event->key,
'tags' => json_encode($event->tags),
Expand Down
2 changes: 0 additions & 2 deletions tests/Watchers/CacheWatcherTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@

$fake->assertEventExists('cache set', [
'key' => 'put',
'expires_at' => $expiredAt->getTimestamp(),
'expires_in_seconds' => 60,
]);
});

Expand Down

0 comments on commit 9d6abff

Please sign in to comment.