From 11ac028d76827118905f26da5f9da1a6fcb3b230 Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 18:53:11 +0200 Subject: [PATCH 1/7] Allow Symfony 7. --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 29bd28b..f407f71 100644 --- a/composer.json +++ b/composer.json @@ -25,7 +25,7 @@ "require": { "php": "^5.6 || ^7.0 || ^8.0", "portphp/portphp": "^1.1", - "symfony/console": "^2.7 || ^3.0 || ^4.0 || ^5.0 || ^6.0" + "symfony/console": "^2.7 || ^3.0 || ^4.0 || ^5.0 || ^6.0 || ^7.0" }, "autoload": { "psr-4": { From dfc6e619f452a7c09579d6b8933e4ccc64e694df Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 18:57:18 +0200 Subject: [PATCH 2/7] Update GitHub workflow to use newer versions of dependencies. --- .github/workflows/checks.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index 6d76b72..acf6f06 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -20,7 +20,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set up PHP uses: shivammathur/setup-php@v2 @@ -33,7 +33,7 @@ jobs: - name: Cache Composer packages id: composer-cache - uses: actions/cache@v2 + uses: actions/cache@v4 with: path: vendor key: ${{ runner.os }}-composer-${{ matrix.composer-prefer }}$-${{ hashFiles('**/composer.lock') }} From da8b3fab774a6fbc68bbf008cba9b457b177a6b6 Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 19:00:03 +0200 Subject: [PATCH 3/7] Bump PHP versions being tested. --- .github/workflows/checks.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index acf6f06..271f2dd 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -10,9 +10,9 @@ jobs: test: strategy: matrix: - php-versions: [ '7.4', '8.0', '8.1' ] + php-versions: [ '8.2', '8.3', '8.4', '8.5' ] include: - - php-versions: '7.4' + - php-versions: '8.5' coverage: pcov composer-prefer: '--prefer-lowest --prefer-stable' phpunit-flags: '--coverage-clover coverage.xml' From 0b5a3fa6c94fb477ef293b5a2ab2e198c0f5ca87 Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 19:01:35 +0200 Subject: [PATCH 4/7] Allow PHPspec for PHP 8. --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index f407f71..69fdb27 100644 --- a/composer.json +++ b/composer.json @@ -33,7 +33,7 @@ } }, "require-dev": { - "phpspec/phpspec": "^7.2", + "phpspec/phpspec": "^7.2 || ^8.0", "friends-of-phpspec/phpspec-code-coverage" : "^6.1" }, "extra": { From 9972fe2b1c4d85b22d9c8c40b7f0b48a35b5c83b Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 19:03:02 +0200 Subject: [PATCH 5/7] Allow friends-of-phpspec/phpspec-code-coverage for PHP 8. --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 69fdb27..3e93268 100644 --- a/composer.json +++ b/composer.json @@ -34,7 +34,7 @@ }, "require-dev": { "phpspec/phpspec": "^7.2 || ^8.0", - "friends-of-phpspec/phpspec-code-coverage" : "^6.1" + "friends-of-phpspec/phpspec-code-coverage" : "^6.1 | ^7.0" }, "extra": { "branch-alias": { From 7b747ba9295949815e11755138048ea948516bad Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 19:12:54 +0200 Subject: [PATCH 6/7] Update spec for PHP 8, do not upload to scrutinizer. --- .github/workflows/checks.yml | 12 ------------ phpspec.yml.ci | 2 +- spec/ProgressWriterSpec.php | 2 +- 3 files changed, 2 insertions(+), 14 deletions(-) diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index 271f2dd..32d4001 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -11,11 +11,6 @@ jobs: strategy: matrix: php-versions: [ '8.2', '8.3', '8.4', '8.5' ] - include: - - php-versions: '8.5' - coverage: pcov - composer-prefer: '--prefer-lowest --prefer-stable' - phpunit-flags: '--coverage-clover coverage.xml' runs-on: ubuntu-latest @@ -45,10 +40,3 @@ jobs: - name: Run phpspec run: vendor/bin/phpspec run --config phpspec.yml.ci - continue-on-error: true - - - name: Upload coverage - if: matrix.coverage - run: | - wget https://scrutinizer-ci.com/ocular.phar - php ocular.phar code-coverage:upload --format=php-clover coverage.clover --revision=${{ github.event.pull_request.head.sha || github.sha }} diff --git a/phpspec.yml.ci b/phpspec.yml.ci index 6f44e94..94caa4c 100644 --- a/phpspec.yml.ci +++ b/phpspec.yml.ci @@ -4,7 +4,7 @@ suites: psr4_prefix: Port\SymfonyConsole formatter.name: pretty extensions: - - PhpSpec\Extension\CodeCoverageExtension + FriendsOfPhpSpec\PhpSpec\CodeCoverage\CodeCoverageExtension: ~ code_coverage: format: clover output: coverage.clover diff --git a/spec/ProgressWriterSpec.php b/spec/ProgressWriterSpec.php index 6ec8d47..002178a 100644 --- a/spec/ProgressWriterSpec.php +++ b/spec/ProgressWriterSpec.php @@ -23,7 +23,7 @@ function it_is_initializable() function it_writes_items(CountableReader $reader, OutputInterface $output, OutputFormatterInterface $outputFormatter) { $outputFormatter->isDecorated()->willReturn(false); - $outputFormatter->setDecorated(false)->willReturn(); + $outputFormatter->setDecorated(false)->shouldBeCalled(); $outputFormatter->format(Argument::any())->willReturn(null); $reader->count()->willReturn(2); From 7a9e08230bff030befd96399d8fd7afe90843b87 Mon Sep 17 00:00:00 2001 From: Janez Urevc Date: Mon, 30 Mar 2026 19:19:53 +0200 Subject: [PATCH 7/7] Update composer.json Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 3e93268..e43c277 100644 --- a/composer.json +++ b/composer.json @@ -34,7 +34,7 @@ }, "require-dev": { "phpspec/phpspec": "^7.2 || ^8.0", - "friends-of-phpspec/phpspec-code-coverage" : "^6.1 | ^7.0" + "friends-of-phpspec/phpspec-code-coverage" : "^6.1 || ^7.0" }, "extra": { "branch-alias": {