diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b861357..ac9818d 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -18,8 +18,9 @@ jobs: matrix: dependencies: ["lowest", "highest"] php-version: - - "8.2" - "8.3" + - "8.4" + - "8.5" steps: - name: "Checkout" diff --git a/.github/workflows/code_coverage.yaml b/.github/workflows/code_coverage.yaml index 47e0790..4316232 100644 --- a/.github/workflows/code_coverage.yaml +++ b/.github/workflows/code_coverage.yaml @@ -14,7 +14,7 @@ jobs: - uses: actions/checkout@v4 - uses: shivammathur/setup-php@master with: - php-version: 8.2 + php-version: 8.4 coverage: xdebug - name: Load dependencies from cache id: composer-cache @@ -23,9 +23,9 @@ jobs: - uses: actions/cache@v4 with: path: ${{ steps.composer-cache.outputs.dir }} - key: ${{ runner.os }}-php8.2-composer-${{ hashFiles('**/composer.json') }} + key: ${{ runner.os }}-php8.4-composer-${{ hashFiles('**/composer.json') }} restore-keys: | - ${{ runner.os }}-php8.2-composer- + ${{ runner.os }}-php8.4-composer- - run: composer install --prefer-dist --no-progress --no-suggest - run: php vendor/bin/phpunit --coverage-clover build/logs/clover.xml diff --git a/composer.json b/composer.json index 758e6e2..534108d 100644 --- a/composer.json +++ b/composer.json @@ -14,16 +14,16 @@ } }, "require": { - "php": "^8.2", - "symfony/console": "^6.0|^7.0", + "php": "^8.3", + "symfony/console": "^7.4|^8.0", "doctrine/dbal": "^3.1|^4.0" }, "require-dev": { "brainbits/phpcs-standard": "^7.0", - "brainbits/phpstan-rules": "^3.0", - "jangregor/phpstan-prophecy": "^1.0", - "phpstan/phpstan": "^1.0", - "phpstan/phpstan-phpunit": "^1.3", + "brainbits/phpstan-rules": "^4.0", + "jangregor/phpstan-prophecy": "^2.2", + "phpstan/phpstan": "^2.0", + "phpstan/phpstan-phpunit": "^2.0", "phpunit/phpunit": "^10.2" }, "config": { diff --git a/tests/Command/WaitForDatabaseCommandTest.php b/tests/Command/WaitForDatabaseCommandTest.php index 5305538..c1d7991 100644 --- a/tests/Command/WaitForDatabaseCommandTest.php +++ b/tests/Command/WaitForDatabaseCommandTest.php @@ -23,6 +23,7 @@ public function testConstruction(): void $connection = $this->createMock(Connection::class); $command = new WaitForDatabaseCommand($connection); + /** @phpstan-ignore method.alreadyNarrowedType */ $this->assertInstanceOf(Command::class, $command); } @@ -69,7 +70,7 @@ public function testDatabaseAvailableAfterRetry(): void $this->assertSame(0, $result); preg_match_all('/Connection failed/', $tester->getDisplay(), $match); - $this->assertCount(1, $match[0] ?? []); + $this->assertCount(1, $match[0]); } public function testDatabaseFailAfterRetry(): void @@ -97,6 +98,6 @@ public function testDatabaseFailAfterRetry(): void $this->assertSame(200, $result); preg_match_all('/Connection failed/', $tester->getDisplay(), $match); - $this->assertCount(4, $match[0] ?? []); + $this->assertCount(4, $match[0]); } }