diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 8ef9f42d..cf07f7f7 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -2,14 +2,15 @@ name: Unit Tests on: [ push, pull_request_target ] jobs: + # This job will run tests for PHP 8.1 php8-1: name: Unit Tests php8.1 (php ${{ matrix.php-version }}) runs-on: ubuntu-latest # always run on push events # only run on pull_request_target event when pull request pulls from fork repository if: > - github.event_name == 'push' || - github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository + github.event_name == 'push' || + github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository strategy: fail-fast: false matrix: @@ -31,13 +32,44 @@ jobs: - run: composer test + # Add a new job for PHP 8.4 + php8-4: + name: Unit Tests php8.4 (php ${{ matrix.php-version }}) + runs-on: ubuntu-latest + # The 'if' condition should be the same as your other PHP version jobs + if: > + github.event_name == 'push' || + github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository + strategy: + fail-fast: false + matrix: + php-version: [ 8.4 ] # Specify PHP 8.4 here + + steps: + - uses: actions/checkout@v2 + + # Use shivammathur/setup-php to install PHP 8.4 + - uses: shivammathur/setup-php@2.9.0 # Ensure you are using a version of setup-php that supports 8.4 + with: + php-version: ${{ matrix.php-version }} + + # You might or might not need the php-cs-fixer removal depending on its 8.4 compatibility + # - run: composer remove --dev --no-update --no-interaction friendsofphp/php-cs-fixer + + - run: composer self-update + + - run: composer install --no-interaction --prefer-source --dev + + - run: composer test + + # This job will run tests for PHP 7.4 php7-4: name: Unit Tests php7.4 (php ${{ matrix.php-version }}) runs-on: ubuntu-latest # always run on push events # only run on pull_request_target event when pull request pulls from fork repository if: > - github.event_name == 'push' || + github.event_name == 'push' || github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository strategy: fail-fast: false @@ -57,13 +89,14 @@ jobs: - run: composer test + # This job will run tests for PHP 8.0 php8-0: name: Unit Tests php8.0 (php ${{ matrix.php-version }}) runs-on: ubuntu-latest # always run on push events # only run on pull_request_target event when pull request pulls from fork repository if: > - github.event_name == 'push' || + github.event_name == 'push' || github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository strategy: fail-fast: false @@ -83,18 +116,19 @@ jobs: - run: composer test + # This job runs tests with the Protobuf C Extension protobuf: name: Unit Tests With Protobuf C Extension 3.13 (php ${{ matrix.php-version }}) runs-on: ubuntu-latest # always run on push events # only run on pull_request_target event when pull request pulls from fork repository if: > - github.event_name == 'push' || - github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository + github.event_name == 'push' || + github.event_name == 'pull_request_target' && github.event.pull_request.head.repo.full_name != github.repository strategy: fail-fast: false matrix: - php-version: [ 8.1 ] + php-version: [ 8.1 ] # You might want to add 8.4 here as well if Protobuf supports it steps: - uses: actions/checkout@v2 @@ -108,5 +142,4 @@ jobs: - run: composer install --no-interaction --prefer-source --dev - - run: composer test - + - run: composer test \ No newline at end of file diff --git a/.php-cs-fixer.cache b/.php-cs-fixer.cache index c0dde319..6d2db2a8 100644 --- a/.php-cs-fixer.cache +++ b/.php-cs-fixer.cache @@ -1 +1 @@ -{"php":"8.1.27","version":"3.22.0:v3.22.0#92b019f6c8d79aa26349d0db7671d37440dc0ff3","indent":" ","lineEnding":"\n","rules":{"array_syntax":{"syntax":"short"},"no_unused_imports":true,"ordered_imports":{"imports_order":["const","class","function"]},"php_unit_fqcn_annotation":true,"phpdoc_return_self_reference":true,"phpdoc_scalar":true},"hashes":{"\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder2419\/examples\/digitalidentity\/app\/Http\/Controllers\/IdentityController.php":"369515522c3efd6cd55a8363d4e97c05","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4308\/src\/Identity\/Policy\/Policy.php":"e1bca74eaafe5271dd1a38769fe1c3b2","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder3692\/src\/Identity\/Policy\/PolicyBuilder.php":"88302b88aba33563661d4b989b5dc429","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder2054\/tests\/Identity\/Policy\/PolicyBuilderTest.php":"a262a261102744a1acf6d5d0b421dc44","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder5221\/src\/Identity\/ReceiptBuilder.php":"2e6ef33d3401f7cbd36145ad66b3b2ef","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder289\/examples\/digitalidentity\/app\/Http\/Controllers\/ReceiptController.php":"e79ec7e1511895c954f77c713d435ad2","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder2348\/tests\/Identity\/ReceiptTest.php":"b602e6828020fef411df597e17fa7c88","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4139\/examples\/digitalidentity\/routes\/web.php":"dcdc77843f3e59dd61467a324edf0c77","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder5396\/src\/Identity\/Receipt.php":"4744c8887009fd9ffbf084f99021eb1c","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder5193\/src\/Identity\/WrappedReceipt.php":"3a77a22be093a1da75438ea2bb9fcb20","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4416\/examples\/digitalidentity\/app\/Http\/Controllers\/AdvancedIdentityController.php":"6b5c23f2ce8da246bc41d136d87ecdb6","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder5544\/examples\/digitalidentity\/app\/Http\/Controllers\/AdvancedIdentityController.php":"6b5c23f2ce8da246bc41d136d87ecdb6","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4533\/src\/Identity\/Policy\/Policy.php":"bea4b7ebb268fca1ad719f933ec82cbd","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder3559\/tests\/Identity\/Policy\/PolicyBuilderTest.php":"f6d7380ae2db4eca426bb39ccfb3a900","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder2922\/examples\/digitalidentity\/routes\/web.php":"fdf260e4dfd18c8ba12078943564875a","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder3947\/src\/Constants.php":"4bb1127c9665c5d0496b90ea3211951d","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4440\/src\/Constants.php":"99a3224f6e3fcae067362798bbab64f0","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4745\/src\/Constants.php":"afc40e02bdc3a87ff7a874826447c604","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1311\/src\/Constants.php":"77a8a39eac3e973495b7719ebd41509e","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1635\/examples\/digitalidentity\/app\/Http\/Controllers\/ReceiptController.php":"10f70ffe111a0030b29762494cc5de7d"}} \ No newline at end of file +{"php":"8.1.32","version":"3.22.0:v3.22.0#92b019f6c8d79aa26349d0db7671d37440dc0ff3","indent":" ","lineEnding":"\n","rules":{"array_syntax":{"syntax":"short"},"no_unused_imports":true,"ordered_imports":{"imports_order":["const","class","function"]},"php_unit_fqcn_annotation":true,"phpdoc_return_self_reference":true,"phpdoc_scalar":true},"hashes":{"\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder2\/src\/DocScan\/Session\/Create\/SdkConfig.php":"3c5367db6d959a971a644458addf55c0","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder9\/src\/DocScan\/Session\/Create\/SdkConfig.php":"43f43af48ec97cdcdb18fc7e3214b1fe","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder6\/src\/DocScan\/Session\/Create\/SdkConfig.php":"cf9d9a38e680441b2c6f7a0ff8223f49","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder7\/src\/DocScan\/Session\/Create\/SdkConfig.php":"a8a73f190d6df54dad7b85538a5ba8c1","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder5\/src\/DocScan\/Session\/Create\/SdkConfig.php":"a8a73f190d6df54dad7b85538a5ba8c1","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder8\/src\/DocScan\/Session\/Create\/SdkConfig.php":"41598f811241011bfc9bec9efedfe2d1","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1173\/src\/DocScan\/Session\/Create\/SdkConfigBuilder.php":"bd08dbe98c30b8237c8b3dbe3fa54717","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder4\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"b6683f36fa99d0f40ca000b514484c83","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder556\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"84129c3ad0dc6ded2a483720271ca7f8","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder153\/src\/DocScan\/Session\/Create\/SdkConfigBuilder.php":"958070e7bb4bbab87eeffa375fe0c687","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder950\/tests\/DocScan\/Session\/Create\/SessionSpecificationBuilderTest.php":"96533aa316f6c2ae30d8df7286447315","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1641\/tests\/DocScan\/Session\/Create\/SessionSpecificationBuilderTest.php":"96533aa316f6c2ae30d8df7286447315","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder11\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"b6683f36fa99d0f40ca000b514484c83","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder10\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"644877fd6b116cdf2757395d7bb51614","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder3\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"b6683f36fa99d0f40ca000b514484c83","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder703\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"35aba377de39fa9938987da2791fabc7","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1422\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"b6683f36fa99d0f40ca000b514484c83","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder569\/src\/ShareUrl\/Policy\/DynamicPolicyBuilder.php":"e1b7507387c46ee254b092a3ce7bd00d","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder935\/tests\/DocScan\/Session\/Create\/SdkConfigBuilderTest.php":"ac6f9716136a4e85f1d7912120a8c34f","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1816\/tests\/DocScan\/Session\/Create\/SdkConfigBuilderTest.php":"d71391e04c522f5feecd88bbadc9e665","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1005\/tests\/DocScan\/Session\/Create\/SdkConfigBuilderTest.php":"33b4f768590c90d3d986deec7975d932","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1304\/tests\/DocScan\/Session\/Create\/SdkConfigBuilderTest.php":"a800549752475494d93c0b9e0759eed8","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder973\/examples\/digitalidentity\/vendor\/egulias\/email-validator\/src\/EmailLexer.php":"52f79f636074d41712f39ca68ca1b2e9","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder909\/examples\/digitalidentity\/sdk\/src\/Util\/Json.php":"0a82acbcdf378adf0211899e0770843d","\/private\/var\/folders\/b6\/tqq9d7y54ll62fjfysz50ry80000gn\/T\/PHP CS Fixertemp_folder1392\/examples\/profile\/sdk\/src\/Profile\/Util\/Attribute\/AnchorConverter.php":"f89140d17b89f938a289082a1b37f60f"}} \ No newline at end of file diff --git a/README.md b/README.md index e6dadebc..1910bd7b 100755 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ Please feel free to reach out ## Requirements -* PHP ^7.4 || ^8.0 || ^8.1 +* PHP ^7.4 || ^8.0 || ^8.1 || ^8.4 * CURL PHP extension (must support TLSv1.2) ### Recommended (optional) diff --git a/composer.json b/composer.json index 01038195..07709dda 100755 --- a/composer.json +++ b/composer.json @@ -9,7 +9,7 @@ "homepage": "https://yoti.com", "license": "MIT", "require": { - "php": "^7.4 || ^8.0 || ^8.1", + "php": "^7.4 || ^8.0 || ^8.1 || ^8.4", "ext-json": "*", "google/protobuf": "^3.10", "phpseclib/phpseclib": "^3.0", diff --git a/src/Aml/Profile.php b/src/Aml/Profile.php index b0ee2a10..a6e1a9ba 100644 --- a/src/Aml/Profile.php +++ b/src/Aml/Profile.php @@ -50,7 +50,7 @@ class Profile implements \JsonSerializable * @param \Yoti\Aml\Address $amlAddress * @param null|string $ssn */ - public function __construct($givenNames, $familyName, Address $amlAddress, string $ssn = null) + public function __construct($givenNames, $familyName, Address $amlAddress, ?string $ssn = null) { $this->givenNames = $givenNames; $this->familyName = $familyName; diff --git a/src/DocScan/Session/Create/Check/RequestedLivenessConfig.php b/src/DocScan/Session/Create/Check/RequestedLivenessConfig.php index 050655db..07db4fea 100644 --- a/src/DocScan/Session/Create/Check/RequestedLivenessConfig.php +++ b/src/DocScan/Session/Create/Check/RequestedLivenessConfig.php @@ -23,7 +23,7 @@ class RequestedLivenessConfig implements RequestedCheckConfigInterface */ private $manualCheck; - public function __construct(string $livenessType, int $maxRetries, string $manualCheck = null) + public function __construct(string $livenessType, int $maxRetries, ?string $manualCheck = null) { $this->livenessType = $livenessType; $this->maxRetries = $maxRetries; diff --git a/src/DocScan/Session/Create/ImportTokenBuilder.php b/src/DocScan/Session/Create/ImportTokenBuilder.php index 84340213..b40dd9bf 100644 --- a/src/DocScan/Session/Create/ImportTokenBuilder.php +++ b/src/DocScan/Session/Create/ImportTokenBuilder.php @@ -10,7 +10,7 @@ class ImportTokenBuilder private int $ttl; - public function withTtl(int $ttl = null): ImportTokenBuilder + public function withTtl(?int $ttl = null): ImportTokenBuilder { $this->ttl = $ttl ?? self::DEFAULT_TTL; diff --git a/src/DocScan/Session/Create/SdkConfig.php b/src/DocScan/Session/Create/SdkConfig.php index 683b403a..43c0498d 100644 --- a/src/DocScan/Session/Create/SdkConfig.php +++ b/src/DocScan/Session/Create/SdkConfig.php @@ -72,12 +72,12 @@ class SdkConfig implements \JsonSerializable * @var string|null */ private $darkMode; - + /** * @var string|null */ private $primaryColourDarkMode; - + /** * @var string|null */ @@ -263,7 +263,7 @@ public function getDarkMode(): ?string { return $this->darkMode; } - + /** * @return string|null */ diff --git a/src/DocScan/Session/Create/SdkConfigBuilder.php b/src/DocScan/Session/Create/SdkConfigBuilder.php index 67cfd4a7..5a4661dd 100644 --- a/src/DocScan/Session/Create/SdkConfigBuilder.php +++ b/src/DocScan/Session/Create/SdkConfigBuilder.php @@ -75,7 +75,7 @@ class SdkConfigBuilder * @var string|null */ private $darkMode; - + /** * @var string|null */ @@ -161,7 +161,7 @@ public function withBiometricConsentFlow(string $biometricConsentFlow): self $this->biometricConsentFlow = $biometricConsentFlow; return $this; } - + /** * Allows configuring the number of attempts permitted for text extraction on an ID document * diff --git a/src/Exception/ActivityDetailsException.php b/src/Exception/ActivityDetailsException.php index 1913be81..d01f61ac 100644 --- a/src/Exception/ActivityDetailsException.php +++ b/src/Exception/ActivityDetailsException.php @@ -25,7 +25,7 @@ public function __construct( $message = "", ?ResponseInterface $response = null, ?array $responseBody = null, - \Throwable $previous = null + ?\Throwable $previous = null ) { parent::__construct($message, $response, $previous); diff --git a/src/Exception/base/YotiException.php b/src/Exception/base/YotiException.php index 8dde0005..b6a7d2e6 100644 --- a/src/Exception/base/YotiException.php +++ b/src/Exception/base/YotiException.php @@ -20,7 +20,7 @@ class YotiException extends \Exception * @param ResponseInterface|null $response * @param \Throwable|null $previous */ - public function __construct($message = "", ?ResponseInterface $response = null, \Throwable $previous = null) + public function __construct($message = "", ?ResponseInterface $response = null, ?\Throwable $previous = null) { parent::__construct($this->formatMessage($message, $response), 0, $previous); diff --git a/src/Http/Exception/NetworkException.php b/src/Http/Exception/NetworkException.php index 0879d9f9..814871f7 100644 --- a/src/Http/Exception/NetworkException.php +++ b/src/Http/Exception/NetworkException.php @@ -19,7 +19,7 @@ class NetworkException extends ClientException implements NetworkExceptionInterf public function __construct( string $message, RequestInterface $request, - \Throwable $previous = null + ?\Throwable $previous = null ) { $this->setRequest($request); parent::__construct($message, 0, $previous); diff --git a/src/Http/Exception/RequestException.php b/src/Http/Exception/RequestException.php index 2ce34d5d..6c3a946c 100644 --- a/src/Http/Exception/RequestException.php +++ b/src/Http/Exception/RequestException.php @@ -19,7 +19,7 @@ class RequestException extends ClientException implements RequestExceptionInterf public function __construct( string $message, RequestInterface $request, - \Throwable $previous = null + ?\Throwable $previous = null ) { $this->setRequest($request); parent::__construct($message, 0, $previous); diff --git a/src/Http/RequestBuilder.php b/src/Http/RequestBuilder.php index 8afff19e..071b98a3 100644 --- a/src/Http/RequestBuilder.php +++ b/src/Http/RequestBuilder.php @@ -75,7 +75,7 @@ class RequestBuilder /** * @param \Yoti\Util\Config $config */ - public function __construct(Config $config = null) + public function __construct(?Config $config = null) { $this->config = $config ?? new Config(); } diff --git a/src/Http/RequestSigner.php b/src/Http/RequestSigner.php index 99bdff79..89c94ca6 100644 --- a/src/Http/RequestSigner.php +++ b/src/Http/RequestSigner.php @@ -15,7 +15,7 @@ class RequestSigner * @param \Yoti\Util\PemFile $pemFile * @param string $endpoint * @param string $httpMethod - * @param \Yoti\Http\Payload|NULL $payload + * @param \Yoti\Http\Payload|null $payload * * @return string * The base64 encoded signed message @@ -26,7 +26,7 @@ public static function sign( PemFile $pemFile, string $endpoint, string $httpMethod, - Payload $payload = null + ?Payload $payload = null ): string { $messageToSign = "{$httpMethod}&$endpoint"; if ($payload instanceof Payload) { diff --git a/src/Identity/Content/ApplicationContent.php b/src/Identity/Content/ApplicationContent.php index 8487fc4a..7c0d267f 100644 --- a/src/Identity/Content/ApplicationContent.php +++ b/src/Identity/Content/ApplicationContent.php @@ -10,7 +10,7 @@ class ApplicationContent private ?ApplicationProfile $profile; private ?ExtraData $extraData; - public function __construct(ApplicationProfile $profile = null, ExtraData $extraData = null) + public function __construct(?ApplicationProfile $profile = null, ?ExtraData $extraData = null) { $this->profile = $profile; $this->extraData = $extraData; diff --git a/src/Identity/Content/Content.php b/src/Identity/Content/Content.php index 9cf61c01..cef3ef37 100644 --- a/src/Identity/Content/Content.php +++ b/src/Identity/Content/Content.php @@ -9,7 +9,7 @@ class Content private ?string $profile; private ?string $extraData; - public function __construct(string $profile = null, string $extraData = null) + public function __construct(?string $profile = null, ?string $extraData = null) { $this->profile = $profile; $this->extraData = $extraData; diff --git a/src/Identity/Content/UserContent.php b/src/Identity/Content/UserContent.php index a32c2dfd..a69e24fd 100644 --- a/src/Identity/Content/UserContent.php +++ b/src/Identity/Content/UserContent.php @@ -10,7 +10,7 @@ class UserContent private ?UserProfile $profile; private ?ExtraData $extraData; - public function __construct(UserProfile $profile = null, ExtraData $extraData = null) + public function __construct(?UserProfile $profile = null, ?ExtraData $extraData = null) { $this->profile = $profile; $this->extraData = $extraData; diff --git a/src/Identity/Policy/PolicyBuilder.php b/src/Identity/Policy/PolicyBuilder.php index a3b8f479..8ad89aaa 100644 --- a/src/Identity/Policy/PolicyBuilder.php +++ b/src/Identity/Policy/PolicyBuilder.php @@ -51,8 +51,8 @@ public function withWantedAttribute(WantedAttribute $wantedAttribute): self */ public function withWantedAttributeByName( string $name, - array $constraints = null, - bool $acceptSelfAsserted = null + ?array $constraints = null, + ?bool $acceptSelfAsserted = null ): self { $wantedAttributeBuilder = (new WantedAttributeBuilder()) ->withName($name); @@ -71,7 +71,7 @@ public function withWantedAttributeByName( /** * @param Constraint[]|null $constraints */ - public function withFamilyName(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withFamilyName(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_FAMILY_NAME, @@ -83,7 +83,7 @@ public function withFamilyName(array $constraints = null, bool $acceptSelfAssert /** * @param Constraint[]|null $constraints */ - public function withGivenNames(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withGivenNames(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_GIVEN_NAMES, @@ -95,7 +95,7 @@ public function withGivenNames(array $constraints = null, bool $acceptSelfAssert /** * @param Constraint[]|null $constraints */ - public function withFullName(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withFullName(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_FULL_NAME, @@ -107,7 +107,7 @@ public function withFullName(array $constraints = null, bool $acceptSelfAsserted /** * @param Constraint[]|null $constraints */ - public function withDateOfBirth(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withDateOfBirth(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_DATE_OF_BIRTH, @@ -119,7 +119,7 @@ public function withDateOfBirth(array $constraints = null, bool $acceptSelfAsser /** * @param Constraint[]|null $constraints */ - public function withAgeOver(int $age, array $constraints = null, bool $acceptSelfAsserted = null): self + public function withAgeOver(int $age, ?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withAgeDerivedAttribute( UserProfile::AGE_OVER . $age, @@ -131,7 +131,7 @@ public function withAgeOver(int $age, array $constraints = null, bool $acceptSel /** * @param Constraint[]|null $constraints */ - public function withAgeUnder(int $age, array $constraints = null, bool $acceptSelfAsserted = null): self + public function withAgeUnder(int $age, ?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withAgeDerivedAttribute( UserProfile::AGE_UNDER . $age, @@ -145,8 +145,8 @@ public function withAgeUnder(int $age, array $constraints = null, bool $acceptSe */ public function withAgeDerivedAttribute( string $derivation, - array $constraints = null, - bool $acceptSelfAsserted = null + ?array $constraints = null, + ?bool $acceptSelfAsserted = null ): self { $wantedAttributeBuilder = (new WantedAttributeBuilder()) ->withName(UserProfile::ATTR_DATE_OF_BIRTH) @@ -166,7 +166,7 @@ public function withAgeDerivedAttribute( /** * @param Constraint[]|null $constraints */ - public function withGender(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withGender(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_GENDER, @@ -178,7 +178,7 @@ public function withGender(array $constraints = null, bool $acceptSelfAsserted = /** * @param Constraint[]|null $constraints */ - public function withPostalAddress(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withPostalAddress(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_POSTAL_ADDRESS, @@ -190,7 +190,7 @@ public function withPostalAddress(array $constraints = null, bool $acceptSelfAss /** * @param Constraint[]|null $constraints */ - public function withStructuredPostalAddress(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withStructuredPostalAddress(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_STRUCTURED_POSTAL_ADDRESS, @@ -202,7 +202,7 @@ public function withStructuredPostalAddress(array $constraints = null, bool $acc /** * @param Constraint[]|null $constraints */ - public function withNationality(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withNationality(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_NATIONALITY, @@ -214,7 +214,7 @@ public function withNationality(array $constraints = null, bool $acceptSelfAsser /** * @param Constraint[]|null $constraints */ - public function withPhoneNumber(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withPhoneNumber(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_PHONE_NUMBER, @@ -226,7 +226,7 @@ public function withPhoneNumber(array $constraints = null, bool $acceptSelfAsser /** * @param Constraint[]|null $constraints */ - public function withSelfie(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withSelfie(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_SELFIE, @@ -238,7 +238,7 @@ public function withSelfie(array $constraints = null, bool $acceptSelfAsserted = /** * @param Constraint[]|null $constraints */ - public function withDocumentDetails(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withDocumentDetails(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_DOCUMENT_DETAILS, @@ -250,7 +250,7 @@ public function withDocumentDetails(array $constraints = null, bool $acceptSelfA /** * @param Constraint[]|null $constraints */ - public function withDocumentImages(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withDocumentImages(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_DOCUMENT_IMAGES, @@ -262,7 +262,7 @@ public function withDocumentImages(array $constraints = null, bool $acceptSelfAs /** * @param Constraint[]|null $constraints */ - public function withEmail(array $constraints = null, bool $acceptSelfAsserted = null): self + public function withEmail(?array $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_EMAIL_ADDRESS, diff --git a/src/Identity/Policy/WantedAttribute.php b/src/Identity/Policy/WantedAttribute.php index dc34da79..47005af1 100644 --- a/src/Identity/Policy/WantedAttribute.php +++ b/src/Identity/Policy/WantedAttribute.php @@ -29,10 +29,10 @@ class WantedAttribute implements \JsonSerializable */ public function __construct( string $name, - string $derivation = null, + ?string $derivation = null, bool $optional = false, - bool $acceptSelfAsserted = null, - array $constraints = null + ?bool $acceptSelfAsserted = null, + ?array $constraints = null ) { Validation::notEmptyString($name, 'name'); $this->name = $name; diff --git a/src/Identity/ReceiptBuilder.php b/src/Identity/ReceiptBuilder.php index 0851a088..1ec378f2 100644 --- a/src/Identity/ReceiptBuilder.php +++ b/src/Identity/ReceiptBuilder.php @@ -42,14 +42,14 @@ public function withSessionId(string $sessionId): self return $this; } - public function withRememberMeId(string $rememberMeId = null): self + public function withRememberMeId(?string $rememberMeId = null): self { $this->rememberMeId = $rememberMeId; return $this; } - public function withParentRememberMeId(string $parentRememberMeId = null): self + public function withParentRememberMeId(?string $parentRememberMeId = null): self { $this->parentRememberMeId = $parentRememberMeId; @@ -63,28 +63,28 @@ public function withTimestamp(\DateTime $timestamp): self return $this; } - public function withApplicationContent(ApplicationProfile $profile, ExtraData $extraData = null): self + public function withApplicationContent(ApplicationProfile $profile, ?ExtraData $extraData = null): self { $this->applicationContent = new ApplicationContent($profile, $extraData); return $this; } - public function withUserContent(UserProfile $profile = null, ExtraData $extraData = null): self + public function withUserContent(?UserProfile $profile = null, ?ExtraData $extraData = null): self { $this->userContent = new UserContent($profile, $extraData); return $this; } - public function withError(string $error = null): self + public function withError(?string $error = null): self { $this->error = $error; return $this; } - public function withErrorReason(ErrorReason $errorReason = null): self + public function withErrorReason(?ErrorReason $errorReason = null): self { $this->errorReason = $errorReason; diff --git a/src/Identity/ReceiptParser.php b/src/Identity/ReceiptParser.php index 904ef7b7..39fae9ee 100644 --- a/src/Identity/ReceiptParser.php +++ b/src/Identity/ReceiptParser.php @@ -21,7 +21,7 @@ class ReceiptParser */ private $logger; - public function __construct(LoggerInterface $logger = null) + public function __construct(?LoggerInterface $logger = null) { $this->logger = $logger ?? new Logger(); } diff --git a/src/Profile/Attribute.php b/src/Profile/Attribute.php index 1117f728..39f1d8b2 100644 --- a/src/Profile/Attribute.php +++ b/src/Profile/Attribute.php @@ -36,7 +36,7 @@ class Attribute * @param Anchor[] $anchors * @param string|null $id */ - public function __construct(string $name, $value, array $anchors, string $id = null) + public function __construct(string $name, $value, array $anchors, ?string $id = null) { $this->name = $name; $this->value = $value; diff --git a/src/Profile/ExtraData/AttributeIssuanceDetails.php b/src/Profile/ExtraData/AttributeIssuanceDetails.php index 019350c6..d01ef7d4 100644 --- a/src/Profile/ExtraData/AttributeIssuanceDetails.php +++ b/src/Profile/ExtraData/AttributeIssuanceDetails.php @@ -28,7 +28,7 @@ class AttributeIssuanceDetails * @param \DateTime $expiryDate * @param \Yoti\Profile\ExtraData\AttributeDefinition[] $issuingAttributes */ - public function __construct(string $token, \DateTime $expiryDate = null, array $issuingAttributes = []) + public function __construct(string $token, ?\DateTime $expiryDate = null, array $issuingAttributes = []) { $this->token = $token; diff --git a/src/Profile/Util/Attribute/AnchorConverter.php b/src/Profile/Util/Attribute/AnchorConverter.php index a13d6147..816abd1b 100644 --- a/src/Profile/Util/Attribute/AnchorConverter.php +++ b/src/Profile/Util/Attribute/AnchorConverter.php @@ -61,7 +61,14 @@ private static function decodeAnchorValue(string $extEncodedValue): string $encodedBER = ASN1::extractBER($extEncodedValue); $decodedValArr = ASN1::decodeBER($encodedBER); if (isset($decodedValArr[0]['content'][0]['content'])) { - return $decodedValArr[0]['content'][0]['content']; + $value = $decodedValArr[0]['content'][0]['content']; + if (is_string($value) && $value !== '' && ord($value[0]) < 32) { + return substr($value, 1); + } + if (is_object($value) && method_exists($value, 'getContent')) { + $value = $value->getContent(); + } + return (string) $value; } return ''; } diff --git a/src/ShareUrl/Policy/DynamicPolicyBuilder.php b/src/ShareUrl/Policy/DynamicPolicyBuilder.php index 4d3ba083..17ac7ad5 100644 --- a/src/ShareUrl/Policy/DynamicPolicyBuilder.php +++ b/src/ShareUrl/Policy/DynamicPolicyBuilder.php @@ -77,8 +77,8 @@ public function withWantedAttribute(WantedAttribute $wantedAttribute): self */ public function withWantedAttributeByName( string $name, - Constraints $constraints = null, - bool $acceptSelfAsserted = null + ?Constraints $constraints = null, + ?bool $acceptSelfAsserted = null ): self { $wantedAttributeBuilder = (new WantedAttributeBuilder()) ->withName($name); @@ -100,7 +100,7 @@ public function withWantedAttributeByName( * * @return $this */ - public function withFamilyName(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withFamilyName(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_FAMILY_NAME, @@ -115,7 +115,7 @@ public function withFamilyName(Constraints $constraints = null, bool $acceptSelf * * @return self */ - public function withGivenNames(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withGivenNames(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_GIVEN_NAMES, @@ -130,7 +130,7 @@ public function withGivenNames(Constraints $constraints = null, bool $acceptSelf * * @return self */ - public function withFullName(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withFullName(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_FULL_NAME, @@ -145,7 +145,7 @@ public function withFullName(Constraints $constraints = null, bool $acceptSelfAs * * @return $this */ - public function withDateOfBirth(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withDateOfBirth(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_DATE_OF_BIRTH, @@ -161,7 +161,7 @@ public function withDateOfBirth(Constraints $constraints = null, bool $acceptSel * * @return $this */ - public function withAgeOver(int $age, Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withAgeOver(int $age, ?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withAgeDerivedAttribute( UserProfile::AGE_OVER . (string) $age, @@ -177,7 +177,7 @@ public function withAgeOver(int $age, Constraints $constraints = null, bool $acc * * @return $this */ - public function withAgeUnder(int $age, Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withAgeUnder(int $age, ?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withAgeDerivedAttribute( UserProfile::AGE_UNDER . (string) $age, @@ -195,8 +195,8 @@ public function withAgeUnder(int $age, Constraints $constraints = null, bool $ac */ public function withAgeDerivedAttribute( string $derivation, - Constraints $constraints = null, - bool $acceptSelfAsserted = null + ?Constraints $constraints = null, + ?bool $acceptSelfAsserted = null ): self { $wantedAttributeBuilder = (new WantedAttributeBuilder()) ->withName(UserProfile::ATTR_DATE_OF_BIRTH) @@ -216,7 +216,7 @@ public function withAgeDerivedAttribute( * * @return $this */ - public function withGender(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withGender(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_GENDER, @@ -231,7 +231,7 @@ public function withGender(Constraints $constraints = null, bool $acceptSelfAsse * * @return $this */ - public function withPostalAddress(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withPostalAddress(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_POSTAL_ADDRESS, @@ -246,8 +246,10 @@ public function withPostalAddress(Constraints $constraints = null, bool $acceptS * * @return $this */ - public function withStructuredPostalAddress(Constraints $constraints = null, bool $acceptSelfAsserted = null): self - { + public function withStructuredPostalAddress( + ?Constraints $constraints = null, + ?bool $acceptSelfAsserted = null + ): self { return $this->withWantedAttributeByName( UserProfile::ATTR_STRUCTURED_POSTAL_ADDRESS, $constraints, @@ -255,13 +257,14 @@ public function withStructuredPostalAddress(Constraints $constraints = null, boo ); } + /** * @param \Yoti\ShareUrl\Policy\Constraints $constraints * @param bool $acceptSelfAsserted * * @return $this */ - public function withNationality(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withNationality(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_NATIONALITY, @@ -276,7 +279,7 @@ public function withNationality(Constraints $constraints = null, bool $acceptSel * * @return $this */ - public function withPhoneNumber(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withPhoneNumber(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_PHONE_NUMBER, @@ -291,7 +294,7 @@ public function withPhoneNumber(Constraints $constraints = null, bool $acceptSel * * @return $this */ - public function withSelfie(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withSelfie(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_SELFIE, @@ -306,7 +309,7 @@ public function withSelfie(Constraints $constraints = null, bool $acceptSelfAsse * * @return $this */ - public function withDocumentDetails(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withDocumentDetails(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_DOCUMENT_DETAILS, @@ -321,7 +324,7 @@ public function withDocumentDetails(Constraints $constraints = null, bool $accep * * @return $this */ - public function withDocumentImages(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withDocumentImages(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_DOCUMENT_IMAGES, @@ -336,7 +339,7 @@ public function withDocumentImages(Constraints $constraints = null, bool $accept * * @return $this */ - public function withEmail(Constraints $constraints = null, bool $acceptSelfAsserted = null): self + public function withEmail(?Constraints $constraints = null, ?bool $acceptSelfAsserted = null): self { return $this->withWantedAttributeByName( UserProfile::ATTR_EMAIL_ADDRESS, diff --git a/src/ShareUrl/Policy/WantedAttribute.php b/src/ShareUrl/Policy/WantedAttribute.php index e525e446..d176070a 100644 --- a/src/ShareUrl/Policy/WantedAttribute.php +++ b/src/ShareUrl/Policy/WantedAttribute.php @@ -46,10 +46,10 @@ class WantedAttribute implements \JsonSerializable */ public function __construct( string $name, - string $derivation = null, - bool $acceptSelfAsserted = null, - Constraints $constraints = null, - bool $optional = null + ?string $derivation = null, + ?bool $acceptSelfAsserted = null, + ?Constraints $constraints = null, + ?bool $optional = null ) { Validation::notEmptyString($name, 'name'); $this->name = $name; diff --git a/tests/DocScan/Session/Create/SdkConfigBuilderTest.php b/tests/DocScan/Session/Create/SdkConfigBuilderTest.php index 2a70fc02..846f2433 100644 --- a/tests/DocScan/Session/Create/SdkConfigBuilderTest.php +++ b/tests/DocScan/Session/Create/SdkConfigBuilderTest.php @@ -322,7 +322,7 @@ public function shouldSetCorrectValueWithDarkModeAuto() $this->assertEquals('AUTO', $result->getDarkMode()); } - + /** * @test * @covers ::withDarkModeOn diff --git a/tests/DocScan/Session/Retrieve/Configuration/Capture/Document/RequiredDocumentResponsesTest.php b/tests/DocScan/Session/Retrieve/Configuration/Capture/Document/RequiredDocumentResponsesTest.php index 378b79b1..c5519782 100644 --- a/tests/DocScan/Session/Retrieve/Configuration/Capture/Document/RequiredDocumentResponsesTest.php +++ b/tests/DocScan/Session/Retrieve/Configuration/Capture/Document/RequiredDocumentResponsesTest.php @@ -45,14 +45,14 @@ class RequiredDocumentResponsesTest extends TestCase * @test * @covers ::createTaskFromArray * @covers ::getRequestedTasks - * @covers \RequiredIdDocumentResourceResponse::__construct - * @covers \RequiredIdDocumentResourceResponse::getSupportedCountries - * @covers \RequiredIdDocumentResourceResponse::getAllowedCaptureMethods - * @covers \RequiredIdDocumentResourceResponse::getAttemptsRemaining - * @covers \RequiredSupplementaryDocumentResourceResponse::__construct - * @covers \RequiredSupplementaryDocumentResourceResponse::getDocumentTypes - * @covers \RequiredSupplementaryDocumentResourceResponse::getCountryCodes - * @covers \RequiredSupplementaryDocumentResourceResponse::getObjective + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredIdDocumentResourceResponse::__construct + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredIdDocumentResourceResponse::getSupportedCountries + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredIdDocumentResourceResponse::getAllowedCaptureMethods + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredIdDocumentResourceResponse::getAttemptsRemaining + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredSupplementaryDocumentResourceResponse::__construct + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredSupplementaryDocumentResourceResponse::getDocumentTypes + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredSupplementaryDocumentResourceResponse::getCountryCodes + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Document\RequiredSupplementaryDocumentResourceResponse::getObjective */ public function shouldBuildCorrectly() { diff --git a/tests/DocScan/Session/Retrieve/Configuration/Capture/Task/RequestedTaskResponseTest.php b/tests/DocScan/Session/Retrieve/Configuration/Capture/Task/RequestedTaskResponseTest.php index 5e8017ef..52694f1a 100644 --- a/tests/DocScan/Session/Retrieve/Configuration/Capture/Task/RequestedTaskResponseTest.php +++ b/tests/DocScan/Session/Retrieve/Configuration/Capture/Task/RequestedTaskResponseTest.php @@ -19,8 +19,8 @@ class RequestedTaskResponseTest extends TestCase * @test * @covers ::getType * @covers ::getState - * @covers \RequestedIdDocTaskResponse::__construct - * @covers \RequestedSupplementaryDocTaskResponse::__construct + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Task\RequestedIdDocTaskResponse::__construct + * @covers \Yoti\DocScan\Session\Retrieve\Configuration\Capture\Task\RequestedSupplementaryDocTaskResponse::__construct */ public function shouldBuildCorrectly() { diff --git a/tests/DocScan/Session/Retrieve/IdentityProfileResponseTest.php b/tests/DocScan/Session/Retrieve/IdentityProfileResponseTest.php index 35476731..ede841d7 100644 --- a/tests/DocScan/Session/Retrieve/IdentityProfileResponseTest.php +++ b/tests/DocScan/Session/Retrieve/IdentityProfileResponseTest.php @@ -42,7 +42,6 @@ class IdentityProfileResponseTest extends TestCase * @covers ::getFailureReason * @covers ::getResult * @covers ::getSubjectId - * @covers \Yoti\DocScan\Session\Retrieve\IdentityProfile\FailureReasonResponse::getStringCode * @covers \Yoti\DocScan\Session\Retrieve\IdentityProfile\FailureReasonResponse::__construct */ public function shouldCreatedCorrectly(): void diff --git a/tests/Identity/ReceiptItemKeyTest.php b/tests/Identity/ReceiptItemKeyTest.php index 38190bbb..a63f9617 100644 --- a/tests/Identity/ReceiptItemKeyTest.php +++ b/tests/Identity/ReceiptItemKeyTest.php @@ -14,7 +14,6 @@ class ReceiptItemKeyTest extends TestCase * @covers ::getId * @covers ::getIv * @covers ::getValue - * @covers ::setIv * @covers ::__construct */ public function testShouldBuildCorrectly()