Skip to content

Commit

Permalink
Support PHP 8.3
Browse files Browse the repository at this point in the history
  • Loading branch information
GrahamCampbell committed Dec 3, 2023
1 parent 53ad715 commit bcab7c0
Show file tree
Hide file tree
Showing 11 changed files with 19 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

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

- name: Composer normalize
uses: docker://ergebnis/composer-normalize-action
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
extensions: mbstring

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

- name: Install dependencies
run: composer update --no-interaction --prefer-stable --prefer-lowest --no-progress
Expand All @@ -37,7 +37,7 @@ jobs:
strategy:
max-parallel: 10
matrix:
php: ['7.2', '7.3', '7.4', '8.0', '8.1', '8.2']
php: ['7.2', '7.3', '7.4', '8.0', '8.1', '8.2', '8.3']

steps:
- name: Set up PHP
Expand All @@ -49,7 +49,7 @@ jobs:
extensions: mbstring

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

- name: Install dependencies
run: composer update --no-interaction --no-progress
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

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

- name: Setup PHP
uses: shivammathur/setup-php@v2
Expand Down
3 changes: 3 additions & 0 deletions .php-cs-fixer.dist.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
'@Symfony' => true,
'declare_strict_types' => false,
'global_namespace_import' => false,
'no_superfluous_phpdoc_tags' => [
'allow_mixed' => true,
],
'phpdoc_annotation_without_dot' => false,
'phpdoc_summary' => false,
'phpdoc_to_comment' => false,
Expand Down
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,13 @@
],
"require": {
"php": "^7.2.5 || ^8.0",
"guzzlehttp/guzzle": "^7.7",
"guzzlehttp/command": "^1.3",
"guzzlehttp/psr7": "^1.9.1 || ^2.4.5",
"guzzlehttp/guzzle": "^7.8",
"guzzlehttp/command": "^1.3.1",
"guzzlehttp/psr7": "^1.9.1 || ^2.5.1",
"guzzlehttp/uri-template": "^1.0.1"
},
"require-dev": {
"bamarni/composer-bin-plugin": "^1.8.1",
"bamarni/composer-bin-plugin": "^1.8.2",
"phpunit/phpunit": "^8.5.19 || ^9.5.8"
},
"autoload": {
Expand Down
9 changes: 3 additions & 6 deletions src/GuzzleClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,12 +34,9 @@ class GuzzleClient extends ServiceClient
* - response_locations: Associative array of location types mapping to
* ResponseLocationInterface objects.
*
* @param ClientInterface $client HTTP client to use.
* @param DescriptionInterface $description Guzzle service description
* @param callable $commandToRequestTransformer
* @param callable $responseToResultTransformer
* @param HandlerStack $commandHandlerStack
* @param array $config Configuration options
* @param ClientInterface $client HTTP client to use.
* @param DescriptionInterface $description Guzzle service description
* @param array $config Configuration options
*/
public function __construct(
ClientInterface $client,
Expand Down
2 changes: 1 addition & 1 deletion src/Parameter.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class Parameter implements ToArrayInterface
/** @var string */
private $format;

private $propertiesCache = null;
private $propertiesCache;

/** @var Description */
private $serviceDescription;
Expand Down
4 changes: 2 additions & 2 deletions src/ResponseLocation/XmlLocation.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@ public function after(
) {
// Handle additional, undefined properties
$additional = $model->getAdditionalProperties();
if ($additional instanceof Parameter &&
$additional->getLocation() == $this->locationName
if ($additional instanceof Parameter
&& $additional->getLocation() == $this->locationName
) {
$result = new Result(array_merge(
$result->toArray(),
Expand Down
2 changes: 0 additions & 2 deletions src/Serializer.php
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,6 @@ protected function createRequest(CommandInterface $command)
/**
* Create a request for an operation with a uri merged onto a base URI
*
* @param \GuzzleHttp\Command\Guzzle\Operation $operation
*
* @return \GuzzleHttp\Psr7\Request
*/
private function createCommandWithUri(
Expand Down
3 changes: 0 additions & 3 deletions tests/ResponseLocation/JsonLocationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,6 @@ public function testVisitsLocation()

/**
* @group ResponseLocation
*
* @param $name
* @param $expected
*/
public function testVisitsWiredArray()
{
Expand Down
2 changes: 1 addition & 1 deletion vendor-bin/php-cs-fixer/composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"require": {
"php": "^7.4 || ^8.0",
"friendsofphp/php-cs-fixer": "3.16.0"
"friendsofphp/php-cs-fixer": "3.40.2"
},
"config": {
"preferred-install": "dist"
Expand Down

0 comments on commit bcab7c0

Please sign in to comment.