Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 3 additions & 15 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,12 @@ jobs:
test:
strategy:
matrix:
php-versions: [ '7.4', '8.0', '8.1' ]
include:
- php-versions: '7.4'
coverage: pcov
composer-prefer: '--prefer-lowest --prefer-stable'
phpunit-flags: '--coverage-clover coverage.xml'
php-versions: [ '8.2', '8.3', '8.4', '8.5' ]

Copilot AI Mar 30, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

composer.json declares support for PHP ^5.6 || ^7.0 || ^8.0, but CI now only runs on PHP 8.2+. If older PHP versions are still supported, consider keeping at least one job for the lowest supported PHP to catch compatibility issues; otherwise update the php constraint to match the supported/tested range.

Suggested change
php-versions: [ '8.2', '8.3', '8.4', '8.5' ]
php-versions: [ '5.6', '8.2', '8.3', '8.4', '8.5' ]

Copilot uses AI. Check for mistakes.

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Set up PHP
uses: shivammathur/setup-php@v2
Expand All @@ -33,7 +28,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') }}
Expand All @@ -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 }}
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,16 +25,16 @@
"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": {
"Port\\SymfonyConsole\\": "src/"
}
},
"require-dev": {
"phpspec/phpspec": "^7.2",
"friends-of-phpspec/phpspec-code-coverage" : "^6.1"
"phpspec/phpspec": "^7.2 || ^8.0",
"friends-of-phpspec/phpspec-code-coverage" : "^6.1 || ^7.0"
},
"extra": {
"branch-alias": {
Expand Down
2 changes: 1 addition & 1 deletion phpspec.yml.ci
Original file line number Diff line number Diff line change
Expand Up @@ -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
2 changes: 1 addition & 1 deletion spec/ProgressWriterSpec.php
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down
Loading