Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support PHP 8.1 release #123

Merged
merged 1 commit into from
Dec 28, 2021
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
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ jobs:
strategy:
matrix:
php:
- 8.1
- 8.0
- 7.4
- 7.3
Expand Down
3 changes: 3 additions & 0 deletions bin/phar-composer
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,8 @@ if (file_exists(__DIR__ . '/../vendor/autoload.php')) {
exit(1);
}

// hide PHP 8.1 deprecations
error_reporting(E_ALL & ~E_DEPRECATED);

$app = new Clue\PharComposer\App();
$app->run();
3 changes: 2 additions & 1 deletion phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.5/phpunit.xsd"
bootstrap="tests/bootstrap.php"
cacheResult="false"
colors="true">
colors="true"
convertDeprecationsToExceptions="true">
<testsuites>
<testsuite name="PharComposer Test Suite">
<directory>./tests/</directory>
Expand Down
1 change: 1 addition & 0 deletions src/Clue/PharComposer/Package/Bundle.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ private function directoryContains(Finder $dir, $resource)
*
* @return \Traversable
*/
#[\ReturnTypeWillChange]
public function getIterator()
{
return new \ArrayIterator($this->resources);
Expand Down
1 change: 1 addition & 0 deletions tests/Command/SearchTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ public function testExecuteWithProjectAndSearchReturnsOneMatchWillAskForProject(
$packager = $this->getMockBuilder('Clue\PharComposer\Phar\Packager')->getMock();

$result = $this->getMockBuilder('Packagist\Api\Result\Result')->getMock();
$result->expects($this->exactly(2))->method('getName')->willReturn('foo/bar');

$packagist = $this->getMockBuilder('Packagist\Api\Client')->getMock();
$packagist->expects($this->once())->method('search')->with('foo')->willReturn(array($result));
Expand Down