diff --git a/.github/workflows/analyzers.yaml b/.github/workflows/analyzers.yaml
index bdf6b70..fbdbd31 100644
--- a/.github/workflows/analyzers.yaml
+++ b/.github/workflows/analyzers.yaml
@@ -7,7 +7,7 @@ jobs:
strategy:
matrix:
operating-system: [ubuntu-latest]
- php-versions: [ '8.2', '8.3' ]
+ php-versions: [ '8.3', '8.4', '8.5' ]
composer-options: [ '--ignore-platform-req=php+' ]
fail-fast: false
name: PHP ${{ matrix.php-versions }} @ ${{ matrix.operating-system }}
@@ -23,4 +23,5 @@ jobs:
- name: Install dependencies
run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }}
- name: Run the tests
- run: ./tools/psalm.phar
+ run: ./vendor/bin/psalm --no-cache
+ continue-on-error: ${{ matrix.php-versions == '8.5' }}
diff --git a/.github/workflows/code-style.yaml b/.github/workflows/code-style.yaml
index 8600cb5..fb19bca 100644
--- a/.github/workflows/code-style.yaml
+++ b/.github/workflows/code-style.yaml
@@ -7,7 +7,7 @@ jobs:
strategy:
matrix:
operating-system: [ubuntu-latest]
- php-versions: [ '8.2', '8.3', '8.4' ]
+ php-versions: [ '8.3', '8.4', '8.5' ]
composer-options: [ '--ignore-platform-req=php+' ]
fail-fast: false
name: PHP ${{ matrix.php-versions }} @ ${{ matrix.operating-system }}
@@ -23,4 +23,4 @@ jobs:
- name: Install dependencies
run: composer update --prefer-dist --no-progress --no-suggest ${{ matrix.composer-options }}
- name: Run the tests
- run: PHP_CS_FIXER_IGNORE_ENV=1 ./tools/php-cs-fixer.phar fix --dry-run
+ run: PHP_CS_FIXER_IGNORE_ENV=1 ./vendor/bin/php-cs-fixer fix --dry-run
diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml
index 06eb08e..5ad6bba 100644
--- a/.github/workflows/tests.yaml
+++ b/.github/workflows/tests.yaml
@@ -7,7 +7,7 @@ jobs:
strategy:
matrix:
operating-system: [ubuntu-latest]
- php-versions: [ '8.2', '8.3', '8.4' ]
+ php-versions: [ '8.3', '8.4', '8.5' ]
composer-options: [ '--ignore-platform-req=php+' ]
fail-fast: false
name: PHP ${{ matrix.php-versions }} @ ${{ matrix.operating-system }}
diff --git a/.phive/phars.xml b/.phive/phars.xml
deleted file mode 100644
index 838d454..0000000
--- a/.phive/phars.xml
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
diff --git a/composer.json b/composer.json
index 225b11a..d2f551f 100644
--- a/composer.json
+++ b/composer.json
@@ -20,17 +20,19 @@
}
],
"require": {
- "php": "~8.2.0 || ~8.3.0 || ~8.4.0",
+ "php": "~8.3.0 || ~8.4.0 || ~8.5.0",
"ext-soap": "*",
"ext-dom": "*",
- "azjezz/psl": "^3.0",
- "php-soap/engine": "^2.13",
- "php-soap/wsdl": "^1.12",
+ "azjezz/psl": "^3.0 || ^4.0",
+ "php-soap/engine": "^2.16",
+ "php-soap/wsdl": "^1.14",
"symfony/options-resolver": "^5.4 || ^6.0 || ^7.0"
},
"require-dev": {
- "php-soap/engine-integration-tests": "^1.9",
- "php-soap/xml": "^1.8",
- "phpunit/phpunit": "^10.0.19 || ^11.0.0"
+ "php-soap/engine-integration-tests": "^1.10",
+ "php-soap/xml": "^1.9",
+ "phpunit/phpunit": "~12.3",
+ "vimeo/psalm": "~6.13",
+ "php-cs-fixer/shim": "~3.88"
}
}
diff --git a/phpunit.xml b/phpunit.xml
index 4101bcf..5939443 100644
--- a/phpunit.xml
+++ b/phpunit.xml
@@ -1,4 +1,11 @@
-
+
./tests/Functional
diff --git a/psalm.xml b/psalm.xml
index 0a69163..02b5f9b 100644
--- a/psalm.xml
+++ b/psalm.xml
@@ -7,6 +7,8 @@
allowStringToStandInForClass="true"
rememberPropertyAssignmentsAfterCall="false"
skipChecksOnUnresolvableIncludes="false"
+ findUnusedCode="false"
+ ensureOverrideAttribute="false"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://getpsalm.org/schema/config"
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
diff --git a/src/AbusedClient.php b/src/AbusedClient.php
index e2dca2a..5e4cdad 100644
--- a/src/AbusedClient.php
+++ b/src/AbusedClient.php
@@ -49,7 +49,8 @@ public function __doRequest(
string $location,
string $action,
int $version,
- bool $one_way = false
+ bool $one_way = false,
+ ?string $uriParserClass = null,
): string {
$this->storedRequest = new SoapRequest($request, $location, $action, $version, $one_way);
diff --git a/src/Metadata/MethodsParser.php b/src/Metadata/MethodsParser.php
index 1637886..cda273f 100644
--- a/src/Metadata/MethodsParser.php
+++ b/src/Metadata/MethodsParser.php
@@ -41,7 +41,7 @@ private function parseMethodFromString(string $methodString): Method
private function transformListResponseToArray(string $methodString): string
{
- return preg_replace('/^list\(([^\)]*)\)(.*)/i', 'array$2', $methodString);
+ return (string) preg_replace('/^list\(([^\)]*)\)(.*)/i', 'array$2', $methodString);
}
private function parseParameters(string $methodString): ParameterCollection
@@ -51,7 +51,7 @@ private function parseParameters(string $methodString): ParameterCollection
return new ParameterCollection();
}
- $parameters = preg_split('/,\s?/', $properties[1]);
+ $parameters = preg_split('/,\s?/', $properties[1]) ?: [];
return new ParameterCollection(...array_map(
function (string $parameter): Parameter {
diff --git a/src/Transport/ExtSoapServerTransport.php b/src/Transport/ExtSoapServerTransport.php
index ac91909..23aeb63 100644
--- a/src/Transport/ExtSoapServerTransport.php
+++ b/src/Transport/ExtSoapServerTransport.php
@@ -20,7 +20,7 @@ public function request(SoapRequest $request): SoapResponse
{
ob_start();
$this->server->handle($request->getRequest());
- $responseBody = ob_get_contents();
+ $responseBody = (string) ob_get_contents();
ob_end_clean();
return new SoapResponse($responseBody);
diff --git a/tests/Functional/ExtSoap/Encoding/DuplicateTypenamesTest.php b/tests/Functional/ExtSoap/Encoding/DuplicateTypenamesTest.php
index 1b6c41d..1415dbd 100644
--- a/tests/Functional/ExtSoap/Encoding/DuplicateTypenamesTest.php
+++ b/tests/Functional/ExtSoap/Encoding/DuplicateTypenamesTest.php
@@ -5,6 +5,7 @@
namespace SoapTest\ExtSoapEngine\Functional\ExtSoap\Encoding;
use DOMDocument;
+use PHPUnit\Framework\Attributes\RunInSeparateProcess;
use Soap\Engine\SimpleEngine;
use Soap\ExtSoapEngine\Configuration\ClassMap\ClassMap;
use Soap\ExtSoapEngine\Configuration\ClassMap\ClassMapCollection;
@@ -52,10 +53,7 @@ public function test_it_registers_both_types()
static::assertEquals([...$store2->getProperties()][0]->getName(), 'Attribute2');
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_knows_how_to_encode_both_types()
{
$engine = new SimpleEngine($this->driver, $this->transport);
@@ -74,10 +72,7 @@ public function test_it_knows_how_to_encode_both_types()
static::assertStringContainsString('ok', $lastRequestInfo->getLastResponse());
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_uses_same_model_for_both_objects()
{
$this->driver = $this->configureSoapDriver($this->wsdl, [
@@ -116,10 +111,7 @@ public function validate($store1, $store2)
static::assertStringContainsString('attr2', $lastRequestInfo->getLastResponse());
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_is_possible_to_override_a_single_instance_with_typemap()
{
$this->driver = $this->configureSoapDriver($this->wsdl, [
diff --git a/tests/Functional/ExtSoap/Encoding/EnumTest.php b/tests/Functional/ExtSoap/Encoding/EnumTest.php
index 6554cb4..6d36397 100644
--- a/tests/Functional/ExtSoap/Encoding/EnumTest.php
+++ b/tests/Functional/ExtSoap/Encoding/EnumTest.php
@@ -6,6 +6,7 @@
use DOMDocument;
use Exception;
+use PHPUnit\Framework\Attributes\RunInSeparateProcess;
use Soap\Engine\SimpleEngine;
use Soap\ExtSoapEngine\ExtSoapDriver;
use Soap\ExtSoapEngine\Transport\TraceableTransport;
@@ -43,10 +44,7 @@ public function test_it_does_not_register_a_type()
static::assertCount(0, $types);
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_knows_how_to_add_enums()
{
$input = 'Home';
@@ -59,10 +57,7 @@ public function test_it_knows_how_to_add_enums()
static::assertStringContainsString('', $lastRequestInfo->getLastResponse());
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_does_not_validate_enums()
{
$input = 'INVALID';
@@ -74,10 +69,7 @@ public function test_it_does_not_validate_enums()
static::assertStringContainsString('', $lastRequestInfo->getLastResponse());
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_does_not_validate_enum_types()
{
$input = 123;
@@ -89,10 +81,7 @@ public function test_it_does_not_validate_enum_types()
static::assertStringContainsString('', $lastRequestInfo->getLastResponse());
}
- /**
- *
- * @runInSeparateProcess
- */
+ #[RunInSeparateProcess]
public function test_it_can_be_transformed_with_type_map()
{
$this->driver = $this->configureSoapDriver($this->wsdl, [
diff --git a/tools/php-cs-fixer.phar b/tools/php-cs-fixer.phar
deleted file mode 100755
index d071fa5..0000000
Binary files a/tools/php-cs-fixer.phar and /dev/null differ
diff --git a/tools/psalm.phar b/tools/psalm.phar
deleted file mode 100755
index 24b9ae3..0000000
Binary files a/tools/psalm.phar and /dev/null differ