diff --git a/composer.json b/composer.json
index 48562d21..90b0adfe 100644
--- a/composer.json
+++ b/composer.json
@@ -55,7 +55,7 @@
"captainhook/captainhook": "^5.27",
"phpstan/phpstan": "^2.1",
"phpstan/phpstan-strict-rules": "^2.0",
- "phpunit/phpunit": "^12.4",
+ "phpunit/phpunit": "^13.0",
"slevomat/coding-standard": "^8.24",
"squizlabs/php_codesniffer": "^4.0",
"symfony/validator": "^8.0",
diff --git a/composer.lock b/composer.lock
index b0caae8b..f1351af9 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "30f8a088d44358fa3e9da7766ef61837",
+ "content-hash": "0bf467b0371f96cd3b53713628e560b5",
"packages": [
{
"name": "psr/container",
@@ -1565,16 +1565,16 @@
},
{
"name": "phpunit/php-code-coverage",
- "version": "12.5.3",
+ "version": "13.0.1",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
- "reference": "b015312f28dd75b75d3422ca37dff2cd1a565e8d"
+ "reference": "a8b58fde2f4fbc69a064e1f80ff917607cf7737c"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/b015312f28dd75b75d3422ca37dff2cd1a565e8d",
- "reference": "b015312f28dd75b75d3422ca37dff2cd1a565e8d",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/a8b58fde2f4fbc69a064e1f80ff917607cf7737c",
+ "reference": "a8b58fde2f4fbc69a064e1f80ff917607cf7737c",
"shasum": ""
},
"require": {
@@ -1582,17 +1582,17 @@
"ext-libxml": "*",
"ext-xmlwriter": "*",
"nikic/php-parser": "^5.7.0",
- "php": ">=8.3",
- "phpunit/php-file-iterator": "^6.0",
- "phpunit/php-text-template": "^5.0",
- "sebastian/complexity": "^5.0",
- "sebastian/environment": "^8.0.3",
- "sebastian/lines-of-code": "^4.0",
- "sebastian/version": "^6.0",
+ "php": ">=8.4",
+ "phpunit/php-file-iterator": "^7.0",
+ "phpunit/php-text-template": "^6.0",
+ "sebastian/complexity": "^6.0",
+ "sebastian/environment": "^9.0",
+ "sebastian/lines-of-code": "^5.0",
+ "sebastian/version": "^7.0",
"theseer/tokenizer": "^2.0.1"
},
"require-dev": {
- "phpunit/phpunit": "^12.5.1"
+ "phpunit/phpunit": "^13.0"
},
"suggest": {
"ext-pcov": "PHP extension that provides line coverage",
@@ -1601,7 +1601,7 @@
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "12.5.x-dev"
+ "dev-main": "13.0.x-dev"
}
},
"autoload": {
@@ -1630,7 +1630,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-code-coverage/issues",
"security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy",
- "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/12.5.3"
+ "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/13.0.1"
},
"funding": [
{
@@ -1650,32 +1650,32 @@
"type": "tidelift"
}
],
- "time": "2026-02-06T06:01:44+00:00"
+ "time": "2026-02-06T06:05:15+00:00"
},
{
"name": "phpunit/php-file-iterator",
- "version": "6.0.1",
+ "version": "7.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-file-iterator.git",
- "reference": "3d1cd096ef6bea4bf2762ba586e35dbd317cbfd5"
+ "reference": "6e5aa1fb0a95b1703d83e721299ee18bb4e2de50"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/3d1cd096ef6bea4bf2762ba586e35dbd317cbfd5",
- "reference": "3d1cd096ef6bea4bf2762ba586e35dbd317cbfd5",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/6e5aa1fb0a95b1703d83e721299ee18bb4e2de50",
+ "reference": "6e5aa1fb0a95b1703d83e721299ee18bb4e2de50",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "6.0-dev"
+ "dev-main": "7.0-dev"
}
},
"autoload": {
@@ -1703,7 +1703,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-file-iterator/issues",
"security": "https://github.com/sebastianbergmann/php-file-iterator/security/policy",
- "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/6.0.1"
+ "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/7.0.0"
},
"funding": [
{
@@ -1723,28 +1723,28 @@
"type": "tidelift"
}
],
- "time": "2026-02-02T14:04:18+00:00"
+ "time": "2026-02-06T04:33:26+00:00"
},
{
"name": "phpunit/php-invoker",
- "version": "6.0.0",
+ "version": "7.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-invoker.git",
- "reference": "12b54e689b07a25a9b41e57736dfab6ec9ae5406"
+ "reference": "42e5c5cae0c65df12d1b1a3ab52bf3f50f244d88"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/12b54e689b07a25a9b41e57736dfab6ec9ae5406",
- "reference": "12b54e689b07a25a9b41e57736dfab6ec9ae5406",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/42e5c5cae0c65df12d1b1a3ab52bf3f50f244d88",
+ "reference": "42e5c5cae0c65df12d1b1a3ab52bf3f50f244d88",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
"ext-pcntl": "*",
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"suggest": {
"ext-pcntl": "*"
@@ -1752,7 +1752,7 @@
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "6.0-dev"
+ "dev-main": "7.0-dev"
}
},
"autoload": {
@@ -1779,40 +1779,52 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-invoker/issues",
"security": "https://github.com/sebastianbergmann/php-invoker/security/policy",
- "source": "https://github.com/sebastianbergmann/php-invoker/tree/6.0.0"
+ "source": "https://github.com/sebastianbergmann/php-invoker/tree/7.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/phpunit/php-invoker",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:58:58+00:00"
+ "time": "2026-02-06T04:34:47+00:00"
},
{
"name": "phpunit/php-text-template",
- "version": "5.0.0",
+ "version": "6.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-text-template.git",
- "reference": "e1367a453f0eda562eedb4f659e13aa900d66c53"
+ "reference": "a47af19f93f76aa3368303d752aa5272ca3299f4"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/e1367a453f0eda562eedb4f659e13aa900d66c53",
- "reference": "e1367a453f0eda562eedb4f659e13aa900d66c53",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/a47af19f93f76aa3368303d752aa5272ca3299f4",
+ "reference": "a47af19f93f76aa3368303d752aa5272ca3299f4",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "5.0-dev"
+ "dev-main": "6.0-dev"
}
},
"autoload": {
@@ -1839,40 +1851,52 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-text-template/issues",
"security": "https://github.com/sebastianbergmann/php-text-template/security/policy",
- "source": "https://github.com/sebastianbergmann/php-text-template/tree/5.0.0"
+ "source": "https://github.com/sebastianbergmann/php-text-template/tree/6.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/phpunit/php-text-template",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:59:16+00:00"
+ "time": "2026-02-06T04:36:37+00:00"
},
{
"name": "phpunit/php-timer",
- "version": "8.0.0",
+ "version": "9.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-timer.git",
- "reference": "f258ce36aa457f3aa3339f9ed4c81fc66dc8c2cc"
+ "reference": "a0e12065831f6ab0d83120dc61513eb8d9a966f6"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/f258ce36aa457f3aa3339f9ed4c81fc66dc8c2cc",
- "reference": "f258ce36aa457f3aa3339f9ed4c81fc66dc8c2cc",
+ "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/a0e12065831f6ab0d83120dc61513eb8d9a966f6",
+ "reference": "a0e12065831f6ab0d83120dc61513eb8d9a966f6",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "8.0-dev"
+ "dev-main": "9.0-dev"
}
},
"autoload": {
@@ -1899,28 +1923,40 @@
"support": {
"issues": "https://github.com/sebastianbergmann/php-timer/issues",
"security": "https://github.com/sebastianbergmann/php-timer/security/policy",
- "source": "https://github.com/sebastianbergmann/php-timer/tree/8.0.0"
+ "source": "https://github.com/sebastianbergmann/php-timer/tree/9.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/phpunit/php-timer",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:59:38+00:00"
+ "time": "2026-02-06T04:37:53+00:00"
},
{
"name": "phpunit/phpunit",
- "version": "12.5.9",
+ "version": "13.0.1",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/phpunit.git",
- "reference": "83d4c158526c879b4c5cf7149d27958b6d912373"
+ "reference": "35b8abcac712ba24814d7fe8908dfb5702efb39f"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/83d4c158526c879b4c5cf7149d27958b6d912373",
- "reference": "83d4c158526c879b4c5cf7149d27958b6d912373",
+ "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/35b8abcac712ba24814d7fe8908dfb5702efb39f",
+ "reference": "35b8abcac712ba24814d7fe8908dfb5702efb39f",
"shasum": ""
},
"require": {
@@ -1933,22 +1969,22 @@
"myclabs/deep-copy": "^1.13.4",
"phar-io/manifest": "^2.0.4",
"phar-io/version": "^3.2.1",
- "php": ">=8.3",
- "phpunit/php-code-coverage": "^12.5.2",
- "phpunit/php-file-iterator": "^6.0.1",
- "phpunit/php-invoker": "^6.0.0",
- "phpunit/php-text-template": "^5.0.0",
- "phpunit/php-timer": "^8.0.0",
- "sebastian/cli-parser": "^4.2.0",
- "sebastian/comparator": "^7.1.4",
- "sebastian/diff": "^7.0.0",
- "sebastian/environment": "^8.0.3",
- "sebastian/exporter": "^7.0.2",
- "sebastian/global-state": "^8.0.2",
- "sebastian/object-enumerator": "^7.0.0",
- "sebastian/recursion-context": "^7.0.1",
- "sebastian/type": "^6.0.3",
- "sebastian/version": "^6.0.0",
+ "php": ">=8.4.1",
+ "phpunit/php-code-coverage": "^13.0.1",
+ "phpunit/php-file-iterator": "^7.0.0",
+ "phpunit/php-invoker": "^7.0.0",
+ "phpunit/php-text-template": "^6.0.0",
+ "phpunit/php-timer": "^9.0.0",
+ "sebastian/cli-parser": "^5.0.0",
+ "sebastian/comparator": "^8.0.0",
+ "sebastian/diff": "^8.0.0",
+ "sebastian/environment": "^9.0.0",
+ "sebastian/exporter": "^8.0.0",
+ "sebastian/global-state": "^9.0.0",
+ "sebastian/object-enumerator": "^8.0.0",
+ "sebastian/recursion-context": "^8.0.0",
+ "sebastian/type": "^7.0.0",
+ "sebastian/version": "^7.0.0",
"staabm/side-effects-detector": "^1.0.5"
},
"bin": [
@@ -1957,7 +1993,7 @@
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "12.5-dev"
+ "dev-main": "13.0-dev"
}
},
"autoload": {
@@ -1989,7 +2025,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/phpunit/issues",
"security": "https://github.com/sebastianbergmann/phpunit/security/policy",
- "source": "https://github.com/sebastianbergmann/phpunit/tree/12.5.9"
+ "source": "https://github.com/sebastianbergmann/phpunit/tree/13.0.1"
},
"funding": [
{
@@ -2013,32 +2049,32 @@
"type": "tidelift"
}
],
- "time": "2026-02-05T08:01:09+00:00"
+ "time": "2026-02-08T07:08:25+00:00"
},
{
"name": "sebastian/cli-parser",
- "version": "4.2.0",
+ "version": "5.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/cli-parser.git",
- "reference": "90f41072d220e5c40df6e8635f5dafba2d9d4d04"
+ "reference": "48a4654fa5e48c1c81214e9930048a572d4b23ca"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/90f41072d220e5c40df6e8635f5dafba2d9d4d04",
- "reference": "90f41072d220e5c40df6e8635f5dafba2d9d4d04",
+ "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/48a4654fa5e48c1c81214e9930048a572d4b23ca",
+ "reference": "48a4654fa5e48c1c81214e9930048a572d4b23ca",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "4.2-dev"
+ "dev-main": "5.0-dev"
}
},
"autoload": {
@@ -2062,7 +2098,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/cli-parser/issues",
"security": "https://github.com/sebastianbergmann/cli-parser/security/policy",
- "source": "https://github.com/sebastianbergmann/cli-parser/tree/4.2.0"
+ "source": "https://github.com/sebastianbergmann/cli-parser/tree/5.0.0"
},
"funding": [
{
@@ -2082,31 +2118,31 @@
"type": "tidelift"
}
],
- "time": "2025-09-14T09:36:45+00:00"
+ "time": "2026-02-06T04:39:44+00:00"
},
{
"name": "sebastian/comparator",
- "version": "7.1.4",
+ "version": "8.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/comparator.git",
- "reference": "6a7de5df2e094f9a80b40a522391a7e6022df5f6"
+ "reference": "29b232ddc29c2b114c0358c69b3084e7c3da0d58"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/6a7de5df2e094f9a80b40a522391a7e6022df5f6",
- "reference": "6a7de5df2e094f9a80b40a522391a7e6022df5f6",
+ "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/29b232ddc29c2b114c0358c69b3084e7c3da0d58",
+ "reference": "29b232ddc29c2b114c0358c69b3084e7c3da0d58",
"shasum": ""
},
"require": {
"ext-dom": "*",
"ext-mbstring": "*",
- "php": ">=8.3",
- "sebastian/diff": "^7.0",
- "sebastian/exporter": "^7.0"
+ "php": ">=8.4",
+ "sebastian/diff": "^8.0",
+ "sebastian/exporter": "^8.0"
},
"require-dev": {
- "phpunit/phpunit": "^12.2"
+ "phpunit/phpunit": "^13.0"
},
"suggest": {
"ext-bcmath": "For comparing BcMath\\Number objects"
@@ -2114,7 +2150,7 @@
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "7.1-dev"
+ "dev-main": "8.0-dev"
}
},
"autoload": {
@@ -2154,7 +2190,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/comparator/issues",
"security": "https://github.com/sebastianbergmann/comparator/security/policy",
- "source": "https://github.com/sebastianbergmann/comparator/tree/7.1.4"
+ "source": "https://github.com/sebastianbergmann/comparator/tree/8.0.0"
},
"funding": [
{
@@ -2174,33 +2210,33 @@
"type": "tidelift"
}
],
- "time": "2026-01-24T09:28:48+00:00"
+ "time": "2026-02-06T04:40:39+00:00"
},
{
"name": "sebastian/complexity",
- "version": "5.0.0",
+ "version": "6.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/complexity.git",
- "reference": "bad4316aba5303d0221f43f8cee37eb58d384bbb"
+ "reference": "c5651c795c98093480df79350cb050813fc7a2f3"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/bad4316aba5303d0221f43f8cee37eb58d384bbb",
- "reference": "bad4316aba5303d0221f43f8cee37eb58d384bbb",
+ "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/c5651c795c98093480df79350cb050813fc7a2f3",
+ "reference": "c5651c795c98093480df79350cb050813fc7a2f3",
"shasum": ""
},
"require": {
"nikic/php-parser": "^5.0",
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "5.0-dev"
+ "dev-main": "6.0-dev"
}
},
"autoload": {
@@ -2224,41 +2260,53 @@
"support": {
"issues": "https://github.com/sebastianbergmann/complexity/issues",
"security": "https://github.com/sebastianbergmann/complexity/security/policy",
- "source": "https://github.com/sebastianbergmann/complexity/tree/5.0.0"
+ "source": "https://github.com/sebastianbergmann/complexity/tree/6.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/sebastian/complexity",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:55:25+00:00"
+ "time": "2026-02-06T04:41:32+00:00"
},
{
"name": "sebastian/diff",
- "version": "7.0.0",
+ "version": "8.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/diff.git",
- "reference": "7ab1ea946c012266ca32390913653d844ecd085f"
+ "reference": "a2b6d09d7729ee87d605a439469f9dcc39be5ea3"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/7ab1ea946c012266ca32390913653d844ecd085f",
- "reference": "7ab1ea946c012266ca32390913653d844ecd085f",
+ "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/a2b6d09d7729ee87d605a439469f9dcc39be5ea3",
+ "reference": "a2b6d09d7729ee87d605a439469f9dcc39be5ea3",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0",
+ "phpunit/phpunit": "^13.0",
"symfony/process": "^7.2"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "7.0-dev"
+ "dev-main": "8.0-dev"
}
},
"autoload": {
@@ -2291,35 +2339,47 @@
"support": {
"issues": "https://github.com/sebastianbergmann/diff/issues",
"security": "https://github.com/sebastianbergmann/diff/security/policy",
- "source": "https://github.com/sebastianbergmann/diff/tree/7.0.0"
+ "source": "https://github.com/sebastianbergmann/diff/tree/8.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/sebastian/diff",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:55:46+00:00"
+ "time": "2026-02-06T04:42:27+00:00"
},
{
"name": "sebastian/environment",
- "version": "8.0.3",
+ "version": "9.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/environment.git",
- "reference": "24a711b5c916efc6d6e62aa65aa2ec98fef77f68"
+ "reference": "bb64d08145b021b67d5f253308a498b73ab0461e"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/24a711b5c916efc6d6e62aa65aa2ec98fef77f68",
- "reference": "24a711b5c916efc6d6e62aa65aa2ec98fef77f68",
+ "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/bb64d08145b021b67d5f253308a498b73ab0461e",
+ "reference": "bb64d08145b021b67d5f253308a498b73ab0461e",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"suggest": {
"ext-posix": "*"
@@ -2327,7 +2387,7 @@
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "8.0-dev"
+ "dev-main": "9.0-dev"
}
},
"autoload": {
@@ -2355,7 +2415,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/environment/issues",
"security": "https://github.com/sebastianbergmann/environment/security/policy",
- "source": "https://github.com/sebastianbergmann/environment/tree/8.0.3"
+ "source": "https://github.com/sebastianbergmann/environment/tree/9.0.0"
},
"funding": [
{
@@ -2375,34 +2435,34 @@
"type": "tidelift"
}
],
- "time": "2025-08-12T14:11:56+00:00"
+ "time": "2026-02-06T04:43:29+00:00"
},
{
"name": "sebastian/exporter",
- "version": "7.0.2",
+ "version": "8.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/exporter.git",
- "reference": "016951ae10980765e4e7aee491eb288c64e505b7"
+ "reference": "dc31f1f8e0186c8f0bb3e48fd4d51421d8905fea"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/016951ae10980765e4e7aee491eb288c64e505b7",
- "reference": "016951ae10980765e4e7aee491eb288c64e505b7",
+ "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/dc31f1f8e0186c8f0bb3e48fd4d51421d8905fea",
+ "reference": "dc31f1f8e0186c8f0bb3e48fd4d51421d8905fea",
"shasum": ""
},
"require": {
"ext-mbstring": "*",
- "php": ">=8.3",
- "sebastian/recursion-context": "^7.0"
+ "php": ">=8.4",
+ "sebastian/recursion-context": "^8.0"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "7.0-dev"
+ "dev-main": "8.0-dev"
}
},
"autoload": {
@@ -2445,7 +2505,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/exporter/issues",
"security": "https://github.com/sebastianbergmann/exporter/security/policy",
- "source": "https://github.com/sebastianbergmann/exporter/tree/7.0.2"
+ "source": "https://github.com/sebastianbergmann/exporter/tree/8.0.0"
},
"funding": [
{
@@ -2465,35 +2525,35 @@
"type": "tidelift"
}
],
- "time": "2025-09-24T06:16:11+00:00"
+ "time": "2026-02-06T04:44:28+00:00"
},
{
"name": "sebastian/global-state",
- "version": "8.0.2",
+ "version": "9.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/global-state.git",
- "reference": "ef1377171613d09edd25b7816f05be8313f9115d"
+ "reference": "e52e3dc22441e6218c710afe72c3042f8fc41ea7"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/ef1377171613d09edd25b7816f05be8313f9115d",
- "reference": "ef1377171613d09edd25b7816f05be8313f9115d",
+ "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e52e3dc22441e6218c710afe72c3042f8fc41ea7",
+ "reference": "e52e3dc22441e6218c710afe72c3042f8fc41ea7",
"shasum": ""
},
"require": {
- "php": ">=8.3",
- "sebastian/object-reflector": "^5.0",
- "sebastian/recursion-context": "^7.0"
+ "php": ">=8.4",
+ "sebastian/object-reflector": "^6.0",
+ "sebastian/recursion-context": "^8.0"
},
"require-dev": {
"ext-dom": "*",
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "8.0-dev"
+ "dev-main": "9.0-dev"
}
},
"autoload": {
@@ -2519,7 +2579,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/global-state/issues",
"security": "https://github.com/sebastianbergmann/global-state/security/policy",
- "source": "https://github.com/sebastianbergmann/global-state/tree/8.0.2"
+ "source": "https://github.com/sebastianbergmann/global-state/tree/9.0.0"
},
"funding": [
{
@@ -2539,33 +2599,33 @@
"type": "tidelift"
}
],
- "time": "2025-08-29T11:29:25+00:00"
+ "time": "2026-02-06T04:45:13+00:00"
},
{
"name": "sebastian/lines-of-code",
- "version": "4.0.0",
+ "version": "5.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/lines-of-code.git",
- "reference": "97ffee3bcfb5805568d6af7f0f893678fc076d2f"
+ "reference": "4f21bb7768e1c997722ccc7efb1d6b5c11bfd471"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/97ffee3bcfb5805568d6af7f0f893678fc076d2f",
- "reference": "97ffee3bcfb5805568d6af7f0f893678fc076d2f",
+ "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/4f21bb7768e1c997722ccc7efb1d6b5c11bfd471",
+ "reference": "4f21bb7768e1c997722ccc7efb1d6b5c11bfd471",
"shasum": ""
},
"require": {
"nikic/php-parser": "^5.0",
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "4.0-dev"
+ "dev-main": "5.0-dev"
}
},
"autoload": {
@@ -2589,42 +2649,54 @@
"support": {
"issues": "https://github.com/sebastianbergmann/lines-of-code/issues",
"security": "https://github.com/sebastianbergmann/lines-of-code/security/policy",
- "source": "https://github.com/sebastianbergmann/lines-of-code/tree/4.0.0"
+ "source": "https://github.com/sebastianbergmann/lines-of-code/tree/5.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/sebastian/lines-of-code",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:57:28+00:00"
+ "time": "2026-02-06T04:45:54+00:00"
},
{
"name": "sebastian/object-enumerator",
- "version": "7.0.0",
+ "version": "8.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/object-enumerator.git",
- "reference": "1effe8e9b8e068e9ae228e542d5d11b5d16db894"
+ "reference": "b39ab125fd9a7434b0ecbc4202eebce11a98cfc5"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/1effe8e9b8e068e9ae228e542d5d11b5d16db894",
- "reference": "1effe8e9b8e068e9ae228e542d5d11b5d16db894",
+ "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/b39ab125fd9a7434b0ecbc4202eebce11a98cfc5",
+ "reference": "b39ab125fd9a7434b0ecbc4202eebce11a98cfc5",
"shasum": ""
},
"require": {
- "php": ">=8.3",
- "sebastian/object-reflector": "^5.0",
- "sebastian/recursion-context": "^7.0"
+ "php": ">=8.4",
+ "sebastian/object-reflector": "^6.0",
+ "sebastian/recursion-context": "^8.0"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "7.0-dev"
+ "dev-main": "8.0-dev"
}
},
"autoload": {
@@ -2647,40 +2719,52 @@
"support": {
"issues": "https://github.com/sebastianbergmann/object-enumerator/issues",
"security": "https://github.com/sebastianbergmann/object-enumerator/security/policy",
- "source": "https://github.com/sebastianbergmann/object-enumerator/tree/7.0.0"
+ "source": "https://github.com/sebastianbergmann/object-enumerator/tree/8.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/sebastian/object-enumerator",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:57:48+00:00"
+ "time": "2026-02-06T04:46:36+00:00"
},
{
"name": "sebastian/object-reflector",
- "version": "5.0.0",
+ "version": "6.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/object-reflector.git",
- "reference": "4bfa827c969c98be1e527abd576533293c634f6a"
+ "reference": "3ca042c2c60b0eab094f8a1b6a7093f4d4c72200"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/4bfa827c969c98be1e527abd576533293c634f6a",
- "reference": "4bfa827c969c98be1e527abd576533293c634f6a",
+ "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/3ca042c2c60b0eab094f8a1b6a7093f4d4c72200",
+ "reference": "3ca042c2c60b0eab094f8a1b6a7093f4d4c72200",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "5.0-dev"
+ "dev-main": "6.0-dev"
}
},
"autoload": {
@@ -2703,40 +2787,52 @@
"support": {
"issues": "https://github.com/sebastianbergmann/object-reflector/issues",
"security": "https://github.com/sebastianbergmann/object-reflector/security/policy",
- "source": "https://github.com/sebastianbergmann/object-reflector/tree/5.0.0"
+ "source": "https://github.com/sebastianbergmann/object-reflector/tree/6.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/sebastian/object-reflector",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T04:58:17+00:00"
+ "time": "2026-02-06T04:47:13+00:00"
},
{
"name": "sebastian/recursion-context",
- "version": "7.0.1",
+ "version": "8.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/recursion-context.git",
- "reference": "0b01998a7d5b1f122911a66bebcb8d46f0c82d8c"
+ "reference": "74c5af21f6a5833e91767ca068c4d3dfec15317e"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/0b01998a7d5b1f122911a66bebcb8d46f0c82d8c",
- "reference": "0b01998a7d5b1f122911a66bebcb8d46f0c82d8c",
+ "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/74c5af21f6a5833e91767ca068c4d3dfec15317e",
+ "reference": "74c5af21f6a5833e91767ca068c4d3dfec15317e",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "7.0-dev"
+ "dev-main": "8.0-dev"
}
},
"autoload": {
@@ -2767,7 +2863,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/recursion-context/issues",
"security": "https://github.com/sebastianbergmann/recursion-context/security/policy",
- "source": "https://github.com/sebastianbergmann/recursion-context/tree/7.0.1"
+ "source": "https://github.com/sebastianbergmann/recursion-context/tree/8.0.0"
},
"funding": [
{
@@ -2787,32 +2883,32 @@
"type": "tidelift"
}
],
- "time": "2025-08-13T04:44:59+00:00"
+ "time": "2026-02-06T04:51:28+00:00"
},
{
"name": "sebastian/type",
- "version": "6.0.3",
+ "version": "7.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/type.git",
- "reference": "e549163b9760b8f71f191651d22acf32d56d6d4d"
+ "reference": "42412224607bd3931241bbd17f38e0f972f5a916"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/e549163b9760b8f71f191651d22acf32d56d6d4d",
- "reference": "e549163b9760b8f71f191651d22acf32d56d6d4d",
+ "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/42412224607bd3931241bbd17f38e0f972f5a916",
+ "reference": "42412224607bd3931241bbd17f38e0f972f5a916",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"require-dev": {
- "phpunit/phpunit": "^12.0"
+ "phpunit/phpunit": "^13.0"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "6.0-dev"
+ "dev-main": "7.0-dev"
}
},
"autoload": {
@@ -2836,7 +2932,7 @@
"support": {
"issues": "https://github.com/sebastianbergmann/type/issues",
"security": "https://github.com/sebastianbergmann/type/security/policy",
- "source": "https://github.com/sebastianbergmann/type/tree/6.0.3"
+ "source": "https://github.com/sebastianbergmann/type/tree/7.0.0"
},
"funding": [
{
@@ -2856,29 +2952,29 @@
"type": "tidelift"
}
],
- "time": "2025-08-09T06:57:12+00:00"
+ "time": "2026-02-06T04:52:09+00:00"
},
{
"name": "sebastian/version",
- "version": "6.0.0",
+ "version": "7.0.0",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/version.git",
- "reference": "3e6ccf7657d4f0a59200564b08cead899313b53c"
+ "reference": "ad37a5552c8e2b88572249fdc19b6da7792e021b"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/3e6ccf7657d4f0a59200564b08cead899313b53c",
- "reference": "3e6ccf7657d4f0a59200564b08cead899313b53c",
+ "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/ad37a5552c8e2b88572249fdc19b6da7792e021b",
+ "reference": "ad37a5552c8e2b88572249fdc19b6da7792e021b",
"shasum": ""
},
"require": {
- "php": ">=8.3"
+ "php": ">=8.4"
},
"type": "library",
"extra": {
"branch-alias": {
- "dev-main": "6.0-dev"
+ "dev-main": "7.0-dev"
}
},
"autoload": {
@@ -2902,15 +2998,27 @@
"support": {
"issues": "https://github.com/sebastianbergmann/version/issues",
"security": "https://github.com/sebastianbergmann/version/security/policy",
- "source": "https://github.com/sebastianbergmann/version/tree/6.0.0"
+ "source": "https://github.com/sebastianbergmann/version/tree/7.0.0"
},
"funding": [
{
"url": "https://github.com/sebastianbergmann",
"type": "github"
+ },
+ {
+ "url": "https://liberapay.com/sebastianbergmann",
+ "type": "liberapay"
+ },
+ {
+ "url": "https://thanks.dev/u/gh/sebastianbergmann",
+ "type": "thanks_dev"
+ },
+ {
+ "url": "https://tidelift.com/funding/github/packagist/sebastian/version",
+ "type": "tidelift"
}
],
- "time": "2025-02-07T05:00:38+00:00"
+ "time": "2026-02-06T04:52:52+00:00"
},
{
"name": "sebastianfeldmann/camino",
diff --git a/phpcs.xml b/phpcs.xml
index ef95aa77..cd5962c3 100644
--- a/phpcs.xml
+++ b/phpcs.xml
@@ -15,11 +15,20 @@
+
+
+
+
+
+
+
+
+
@@ -36,12 +45,14 @@
+
+
-
+
@@ -55,7 +66,12 @@
-
+
+
+
+
+
+
bin
examples
diff --git a/phpunit.xml b/phpunit.xml
index 3070c2b7..4a671660 100644
--- a/phpunit.xml
+++ b/phpunit.xml
@@ -4,7 +4,7 @@
bootstrap="./vendor/autoload.php"
colors="true"
stderr="true"
- beStrictAboutTestsThatDoNotTestAnything="false"
+ requireSealedMockObjects="true"
displayDetailsOnPhpunitDeprecations="true"
displayDetailsOnTestsThatTriggerDeprecations="true"
displayDetailsOnTestsThatTriggerErrors="true"
diff --git a/src/Dependency/Finder/FinderIterator.php b/src/Dependency/Finder/FinderIterator.php
index c90a8a89..af2842cd 100644
--- a/src/Dependency/Finder/FinderIterator.php
+++ b/src/Dependency/Finder/FinderIterator.php
@@ -4,8 +4,8 @@
namespace Picamator\TransferObject\Dependency\Finder;
-use IteratorAggregate;
use Countable;
+use IteratorAggregate;
use Symfony\Component\Finder\Finder;
use Traversable;
diff --git a/src/Generated/DefinitionBuiltInTypeTransfer.php b/src/Generated/DefinitionBuiltInTypeTransfer.php
index 891700cf..4724c9ac 100644
--- a/src/Generated/DefinitionBuiltInTypeTransfer.php
+++ b/src/Generated/DefinitionBuiltInTypeTransfer.php
@@ -4,9 +4,9 @@
namespace Picamator\TransferObject\Generated;
-use Picamator\TransferObject\TransferGenerator\Definition\Enum\BuiltInTypeEnum;
use Picamator\TransferObject\Transfer\AbstractTransfer;
use Picamator\TransferObject\Transfer\Attribute\Transformer\EnumTransformerAttribute;
+use Picamator\TransferObject\TransferGenerator\Definition\Enum\BuiltInTypeEnum;
/**
* Specification:
diff --git a/src/Shared/Filesystem/FileAppender.php b/src/Shared/Filesystem/FileAppender.php
index a3495f19..9b65f13b 100644
--- a/src/Shared/Filesystem/FileAppender.php
+++ b/src/Shared/Filesystem/FileAppender.php
@@ -20,7 +20,7 @@ public function appendToFile(string $filename, string $content): void
if ($writeResult === false) {
throw new FileAppenderException(
- sprintf('Failed to write content "%s" into the file "%s".', $content, $filename),
+ sprintf('Failed to write content into the file "%s".', $filename),
);
}
}
diff --git a/src/Shared/Filesystem/FileReader.php b/src/Shared/Filesystem/FileReader.php
index 3da92ac8..12d72fce 100644
--- a/src/Shared/Filesystem/FileReader.php
+++ b/src/Shared/Filesystem/FileReader.php
@@ -43,7 +43,7 @@ private function closeFile($file, string $filename): void
}
throw new FileReaderException(
- sprintf('Failed to close "%s" file.', $filename),
+ sprintf('Failed to close file "%s".', $filename),
);
}
diff --git a/src/Shared/Reader/FileReaderProgress.php b/src/Shared/Reader/FileReaderProgress.php
index b9492112..f051a0d5 100644
--- a/src/Shared/Reader/FileReaderProgress.php
+++ b/src/Shared/Reader/FileReaderProgress.php
@@ -46,14 +46,14 @@ private function getTotalBytes(string $filename): int
{
if (!$this->fileExists($filename)) {
throw new FileReaderException(
- sprintf('File "%s" is not exist.', $filename),
+ sprintf('File "%s" does not exist.', $filename),
);
}
$fileSize = $this->filesize($filename);
if ($fileSize === 0) {
throw new FileReaderException(
- sprintf('File size "%s" is empty.', $filename),
+ sprintf('File "%s" is empty.', $filename),
);
}
diff --git a/src/Transfer/Attribute/AttributeTrait.php b/src/Transfer/Attribute/AttributeTrait.php
index ef5a9747..6239f3c1 100644
--- a/src/Transfer/Attribute/AttributeTrait.php
+++ b/src/Transfer/Attribute/AttributeTrait.php
@@ -79,7 +79,7 @@ private function getConstantReflection(string $constantName, string $attributeNa
$firstReflectionAttribute = $reflectionAttributes[0] ?? null;
if ($firstReflectionAttribute === null) {
throw new AttributeTransferException(
- \sprintf('Constant\'s "%s" attribute "%s" not found.', $constantName, $attributeName),
+ \sprintf('Attribute "%s" not found for constant "%s".', $constantName, $attributeName),
);
}
diff --git a/src/TransferGenerator/Config/Config/ConfigProxy.php b/src/TransferGenerator/Config/Config/ConfigProxy.php
index 3418b1e5..feed87b6 100644
--- a/src/TransferGenerator/Config/Config/ConfigProxy.php
+++ b/src/TransferGenerator/Config/Config/ConfigProxy.php
@@ -50,7 +50,7 @@ private function getConfig(): ConfigInterface
}
throw new TransferGeneratorConfigNotFoundException(
- 'Transfer Object generator configuration not found. Please load configuration first.'
+ 'Transfer Object generator configuration not found. Please load the configuration first.'
);
}
}
diff --git a/src/TransferGenerator/Config/Validator/Content/RequiredContentValidator.php b/src/TransferGenerator/Config/Validator/Content/RequiredContentValidator.php
index 2f1b30d0..4f306235 100644
--- a/src/TransferGenerator/Config/Validator/Content/RequiredContentValidator.php
+++ b/src/TransferGenerator/Config/Validator/Content/RequiredContentValidator.php
@@ -12,7 +12,7 @@
{
use ValidatorMessageTrait;
- private const string ERROR_MESSAGE_TEMPLATE = 'Missing required configuration keys: "%s".';
+ private const string ERROR_MESSAGE_TEMPLATE = 'Missing required configuration keys: %s.';
public function validate(ConfigContentTransfer $configContentTransfer): ?ValidatorMessageTransfer
{
diff --git a/src/TransferGenerator/Definition/Filesystem/DefinitionFinder.php b/src/TransferGenerator/Definition/Filesystem/DefinitionFinder.php
index 5cefd65a..f54d0e9a 100644
--- a/src/TransferGenerator/Definition/Filesystem/DefinitionFinder.php
+++ b/src/TransferGenerator/Definition/Filesystem/DefinitionFinder.php
@@ -17,7 +17,7 @@
private const string FILE_NAME_PATTERN = '*.transfer.yml';
- private const string DEFINITIONS_NOT_FOUND_ERROR_MESSAGE = 'Missed Transfer Object definitions.';
+ private const string DEFINITIONS_NOT_FOUND_ERROR_MESSAGE = 'Missing Transfer Object definitions.';
public function __construct(
private FinderInterface $finder,
diff --git a/src/TransferGenerator/Definition/Validator/Content/EmptyPropertiesContentValidator.php b/src/TransferGenerator/Definition/Validator/Content/EmptyPropertiesContentValidator.php
index 67026e60..a996ed27 100644
--- a/src/TransferGenerator/Definition/Validator/Content/EmptyPropertiesContentValidator.php
+++ b/src/TransferGenerator/Definition/Validator/Content/EmptyPropertiesContentValidator.php
@@ -12,7 +12,7 @@
{
use ValidatorMessageTrait;
- private const string PROPERTY_ERROR_MESSAGE_TEMPLATE = 'Class "%s" properties were not defined.';
+ private const string PROPERTY_ERROR_MESSAGE_TEMPLATE = 'Properties for class "%s" are not defined.';
public function validate(DefinitionContentTransfer $contentTransfer): ?ValidatorMessageTransfer
{
diff --git a/src/TransferGenerator/Definition/Validator/Content/Property/AttributesPropertyValidator.php b/src/TransferGenerator/Definition/Validator/Content/Property/AttributesPropertyValidator.php
index df286e48..4c5b4909 100644
--- a/src/TransferGenerator/Definition/Validator/Content/Property/AttributesPropertyValidator.php
+++ b/src/TransferGenerator/Definition/Validator/Content/Property/AttributesPropertyValidator.php
@@ -18,7 +18,7 @@
private const string ATTRIBUTE_NOT_FOUND_ERROR_MESSAGE_TEMPLATE = 'Attribute "%s" not found.';
private const string INVALID_ATTRIBUTE_ERROR_MESSAGE_TEMPLATE = 'Class "%s" is not an attribute.';
private const string INVALID_ATTRIBUTE_TARGET_ERROR_MESSAGE_TEMPLATE
- = 'Attribute "%s" is not allowed to target on properties.';
+ = 'Attribute "%s" is not allowed to target properties.';
public function isApplicable(DefinitionPropertyTransfer $propertyTransfer): bool
{
diff --git a/src/TransferGenerator/Generator/Render/Expander/BuiltInTypeTemplateExpander.php b/src/TransferGenerator/Generator/Render/Expander/BuiltInTypeTemplateExpander.php
index 19493dfb..f42b92c6 100644
--- a/src/TransferGenerator/Generator/Render/Expander/BuiltInTypeTemplateExpander.php
+++ b/src/TransferGenerator/Generator/Render/Expander/BuiltInTypeTemplateExpander.php
@@ -4,12 +4,12 @@
namespace Picamator\TransferObject\TransferGenerator\Generator\Render\Expander;
+use Picamator\TransferObject\Generated\DefinitionPropertyTransfer;
+use Picamator\TransferObject\Generated\TemplateTransfer;
use Picamator\TransferObject\TransferGenerator\Definition\Enum\BuiltInTypeEnum;
use Picamator\TransferObject\TransferGenerator\Generator\Enum\DocBlockTemplateEnum;
use Picamator\TransferObject\TransferGenerator\Generator\Enum\InitiatorAttributeEnum;
use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeEnum;
-use Picamator\TransferObject\Generated\DefinitionPropertyTransfer;
-use Picamator\TransferObject\Generated\TemplateTransfer;
final class BuiltInTypeTemplateExpander extends AbstractTemplateExpander
{
diff --git a/src/TransferGenerator/Generator/Render/Expander/CollectionTypeTemplateExpander.php b/src/TransferGenerator/Generator/Render/Expander/CollectionTypeTemplateExpander.php
index 2a13243e..19647ae1 100644
--- a/src/TransferGenerator/Generator/Render/Expander/CollectionTypeTemplateExpander.php
+++ b/src/TransferGenerator/Generator/Render/Expander/CollectionTypeTemplateExpander.php
@@ -8,9 +8,9 @@
use Picamator\TransferObject\Generated\DefinitionPropertyTransfer;
use Picamator\TransferObject\Generated\TemplateTransfer;
use Picamator\TransferObject\TransferGenerator\Definition\Enum\BuiltInTypeEnum;
+use Picamator\TransferObject\TransferGenerator\Generator\Enum\DocBlockTemplateEnum;
use Picamator\TransferObject\TransferGenerator\Generator\Enum\InitiatorAttributeEnum;
use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
-use Picamator\TransferObject\TransferGenerator\Generator\Enum\DocBlockTemplateEnum;
final class CollectionTypeTemplateExpander extends AbstractTemplateExpander
{
diff --git a/src/TransferGenerator/Generator/Render/Expander/DateTimeTypeTemplateExpander.php b/src/TransferGenerator/Generator/Render/Expander/DateTimeTypeTemplateExpander.php
index 87908ac9..cc190565 100644
--- a/src/TransferGenerator/Generator/Render/Expander/DateTimeTypeTemplateExpander.php
+++ b/src/TransferGenerator/Generator/Render/Expander/DateTimeTypeTemplateExpander.php
@@ -4,9 +4,9 @@
namespace Picamator\TransferObject\TransferGenerator\Generator\Render\Expander;
-use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
use Picamator\TransferObject\Generated\DefinitionPropertyTransfer;
use Picamator\TransferObject\Generated\TemplateTransfer;
+use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
final class DateTimeTypeTemplateExpander extends AbstractTemplateExpander
{
diff --git a/src/TransferGenerator/Generator/Render/Expander/EnumTypeTemplateExpander.php b/src/TransferGenerator/Generator/Render/Expander/EnumTypeTemplateExpander.php
index dd346c39..3963020f 100644
--- a/src/TransferGenerator/Generator/Render/Expander/EnumTypeTemplateExpander.php
+++ b/src/TransferGenerator/Generator/Render/Expander/EnumTypeTemplateExpander.php
@@ -4,9 +4,9 @@
namespace Picamator\TransferObject\TransferGenerator\Generator\Render\Expander;
-use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
use Picamator\TransferObject\Generated\DefinitionPropertyTransfer;
use Picamator\TransferObject\Generated\TemplateTransfer;
+use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
final class EnumTypeTemplateExpander extends AbstractTemplateExpander
{
diff --git a/src/TransferGenerator/Generator/Render/Expander/NumberTypeTemplateExpander.php b/src/TransferGenerator/Generator/Render/Expander/NumberTypeTemplateExpander.php
index ff8af28d..db7966ef 100644
--- a/src/TransferGenerator/Generator/Render/Expander/NumberTypeTemplateExpander.php
+++ b/src/TransferGenerator/Generator/Render/Expander/NumberTypeTemplateExpander.php
@@ -4,9 +4,9 @@
namespace Picamator\TransferObject\TransferGenerator\Generator\Render\Expander;
-use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
use Picamator\TransferObject\Generated\DefinitionPropertyTransfer;
use Picamator\TransferObject\Generated\TemplateTransfer;
+use Picamator\TransferObject\TransferGenerator\Generator\Enum\TransformerAttributeTemplateEnum;
final class NumberTypeTemplateExpander extends AbstractTemplateExpander
{
diff --git a/tests/integration/Command/TransferGeneratorBulkCommandTest.php b/tests/integration/Command/TransferGeneratorBulkCommandTest.php
index a6f8f20f..3f8d1d21 100644
--- a/tests/integration/Command/TransferGeneratorBulkCommandTest.php
+++ b/tests/integration/Command/TransferGeneratorBulkCommandTest.php
@@ -81,7 +81,7 @@ public function testRunCommandWithEmptyConfigurationShouldShowErrorMessage(): vo
// Assert
$this->assertSame(1, $this->commandTester->getStatusCode());
- $this->assertStringContainsString('[ERROR] File size', $output);
+ $this->assertStringContainsString('empty', $output);
}
#[TestDox('Run command with valid configuration but invalid definition should show error message')]
@@ -112,7 +112,8 @@ public function testRunCommandWithValidConfigurationAndFailedFiberStartShouldSho
// Expect
$generatorFacadeMock->expects($this->once())
->method('getTransferGeneratorBulkFiber')
- ->willReturn($fiber);
+ ->willReturn($fiber)
+ ->seal();
// Act
$commandTester->execute(
diff --git a/tests/integration/Command/TransferGeneratorCommandTest.php b/tests/integration/Command/TransferGeneratorCommandTest.php
index a01d5378..2a7a0551 100644
--- a/tests/integration/Command/TransferGeneratorCommandTest.php
+++ b/tests/integration/Command/TransferGeneratorCommandTest.php
@@ -97,7 +97,8 @@ public function testRunCommandWithValidConfigurationAndFailedFiberStartShouldSho
// Expect
$generatorFacadeMock->expects($this->once())
->method('getTransferGeneratorFiber')
- ->willReturn($fiber);
+ ->willReturn($fiber)
+ ->seal();
// Act
$commandTester->execute(
diff --git a/tests/integration/DefinitionGenerator/DefinitionGeneratorFacadeTest.php b/tests/integration/DefinitionGenerator/DefinitionGeneratorFacadeTest.php
index 251712e8..f18660f9 100644
--- a/tests/integration/DefinitionGenerator/DefinitionGeneratorFacadeTest.php
+++ b/tests/integration/DefinitionGenerator/DefinitionGeneratorFacadeTest.php
@@ -183,7 +183,7 @@ public function testCompareSampleDataWithTransferObjectShouldSuccessfullyMatch(
$actual = $transfer->toArray();
// Assert
- $this->assertEquals($sampleContent, $actual);
+ $this->assertArraysAreEqual($sampleContent, $actual);
}
/**
@@ -241,7 +241,7 @@ public function testCompareFilteredSampleDataWithTransferObjectShouldSuccessfull
$actual = $this->filterArrayRecursive($transfer->toArray(), $filterCallback);
// Assert
- $this->assertEquals($sampleContent, $actual);
+ $this->assertArraysAreEqual($sampleContent, $actual);
}
/**
diff --git a/tests/integration/Transfer/Adapter/DummyTransferAdapterTest.php b/tests/integration/Transfer/Adapter/DummyTransferAdapterTest.php
index 088d89e4..9760d114 100644
--- a/tests/integration/Transfer/Adapter/DummyTransferAdapterTest.php
+++ b/tests/integration/Transfer/Adapter/DummyTransferAdapterTest.php
@@ -19,7 +19,7 @@ protected function setUp(): void
$this->bookmarkData = new BookmarkData();
}
- #[TestDox('Transformation fromArray and toArray')]
+ #[TestDox('Transformation fromArray() and toArray()')]
public function testTransformationFromArrayToArray(): void
{
// Arrange
@@ -32,10 +32,10 @@ public function testTransformationFromArrayToArray(): void
$actual = $bookmarkData->toArray();
// Assert
- $this->assertSame([], $actual);
+ $this->assertArraysAreIdentical([], $actual);
}
- #[TestDox('Transfer count')]
+ #[TestDox('Transfer count()')]
public function testTransferCount(): void
{
// Act
@@ -52,17 +52,17 @@ public function testTransferIterator(): void
$actual = iterator_to_array($this->bookmarkData);
// Assert
- $this->assertSame([], $actual);
+ $this->assertArraysAreIdentical([], $actual);
}
- #[TestDox('Transfer debugInfo')]
+ #[TestDox('Transfer debugInfo()')]
public function testTransferDebugInfo(): void
{
// Act
$actual = $this->bookmarkData->__debugInfo();
// Assert
- $this->assertSame([], $actual);
+ $this->assertArraysAreIdentical([], $actual);
}
#[TestDox('Transfer jsonSerialize')]
diff --git a/tests/integration/Transfer/Adapter/TransferAdapterTest.php b/tests/integration/Transfer/Adapter/TransferAdapterTest.php
index c6fd2f9d..954474a9 100644
--- a/tests/integration/Transfer/Adapter/TransferAdapterTest.php
+++ b/tests/integration/Transfer/Adapter/TransferAdapterTest.php
@@ -21,7 +21,7 @@
#[Group('transfer')]
class TransferAdapterTest extends TestCase
{
- #[TestDox('Transformation fromArray and toArray')]
+ #[TestDox('Transformation fromArray() and toArray()')]
public function testTransformationFromArrayToArray(): void
{
// Arrange
@@ -59,10 +59,10 @@ public function testTransformationFromArrayToArray(): void
$actual = $bookData->toArray();
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
- #[TestDox('Transformation fromArray on partly initialized properties')]
+ #[TestDox('Transformation fromArray() on partly initialized properties')]
public function testTransformationFromArrayOnPartlyInitializedProperties(): void
{
// Arrange
@@ -75,7 +75,7 @@ public function testTransformationFromArrayOnPartlyInitializedProperties(): void
$actual = $bookAuthorData->toArray();
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
#[TestDox('Transformation fromArray and toArray with reserved properties')]
@@ -95,11 +95,11 @@ public function testTransformationFromArrayToArrayWithReservedProperties(): void
$actual = $reserverPropertyData->toArray();
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
$this->assertSame($expected[ReservedAdvancedTransfer::DATA_PROP]['_data'], $reserverPropertyData->data->_data);
}
- #[TestDox('Transfer count')]
+ #[TestDox('Transfer count()')]
public function testTransferCount(): void
{
// Arrange
@@ -124,7 +124,7 @@ public function testTransferIterator(): void
$actual = iterator_to_array($bookData);
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
#[TestDox('Iterator on partly initialized properties')]
@@ -140,7 +140,7 @@ public function testIteratorOnPartlyInitializedProperties(): void
$actual = iterator_to_array($bookAuthorData);
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
#[TestDox('Transfer clone')]
@@ -178,7 +178,7 @@ public function testTransferClone(): void
$clonedBookData = clone $bookData;
// Assert
- $this->assertSame($expected, $clonedBookData->toArray());
+ $this->assertArraysAreIdentical($expected, $clonedBookData->toArray());
$this->assertSame($bookData->country, $clonedBookData->country);
$this->assertNotSame($bookData, $clonedBookData);
$this->assertNotSame($bookData->author, $clonedBookData->author);
@@ -189,7 +189,7 @@ public function testTransferClone(): void
$this->assertNotSame($bookData->notes, $clonedBookData->notes);
}
- #[TestDox('Transfer debugInfo')]
+ #[TestDox('Transfer debugInfo()')]
public function testDebugInfo(): void
{
// Arrange
@@ -200,7 +200,7 @@ public function testDebugInfo(): void
$actual = $bookData->__debugInfo();
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
#[TestDox('Transfer jsonSerialize')]
@@ -211,11 +211,13 @@ public function testTransferJsonSerialize(): void
$expected = $bookData->toArray();
// Act
- $actual = json_encode($bookData, flags: JSON_THROW_ON_ERROR);
- $actual = json_decode($actual, associative: true, flags: JSON_THROW_ON_ERROR);
+ $encodedBookData = json_encode($bookData, flags: JSON_THROW_ON_ERROR);
+ /** @var array $actual */
+ $actual = json_decode($encodedBookData, associative: true, flags: JSON_THROW_ON_ERROR);
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertNotEmpty($actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
#[TestDox('Transformation date time $dateTime to $expected by toArray')]
@@ -256,6 +258,6 @@ public function testBcMathTransformationToArray(string|int $price): void
$actual = $bookData->toArray();
// Assert
- $this->assertEquals($expected, $actual);
+ $this->assertArraysAreEqual($expected, $actual);
}
}
diff --git a/tests/integration/Transfer/TransferTest.php b/tests/integration/Transfer/TransferTest.php
index f6b091db..8401ab53 100644
--- a/tests/integration/Transfer/TransferTest.php
+++ b/tests/integration/Transfer/TransferTest.php
@@ -80,7 +80,7 @@ public function testTransformationFromToArray(array $data, array $expected): voi
// Assert
// @phpstan-ignore method.alreadyNarrowedType
$this->assertContainsOnlyInstancesOf(ItemTransfer::class, $itemCollectionTransfer->items);
- $this->assertEquals($expected, $actual);
+ $this->assertArraysAreEqual($expected, $actual);
}
/**
@@ -255,10 +255,10 @@ public function testDateTimeTransformationFromToArray(array $data, array $expect
$actual = array_filter($actual);
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
- #[TestDox('Enum transformation from and to array')]
+ #[TestDox('Enum transformation fromArray() and toArray()')]
public function testEnumTransformationFromToArray(): void
{
// Arrange
@@ -273,7 +273,7 @@ public function testEnumTransformationFromToArray(): void
$actual = $enumTransfer->toArray();
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
#[TestDox('Transfer serialize')]
@@ -289,7 +289,7 @@ public function testTransferSerialize(): void
// Assert
$this->assertInstanceOf(ItemCollectionTransfer::class, $unserialized);
- $this->assertEquals($itemCollectionTransfer->toArray(), $unserialized->toArray());
+ $this->assertArraysAreEqual($itemCollectionTransfer->toArray(), $unserialized->toArray());
}
#[TestDox('Transfer jsonSerialize')]
@@ -301,13 +301,14 @@ public function testTransferJsonSerialize(): void
// Act
$encoded = json_encode($itemCollectionTransfer, flags: JSON_THROW_ON_ERROR);
+ /** @var array $decoded */
$decoded = json_decode($encoded, true, flags: JSON_THROW_ON_ERROR);
// Assert
- $this->assertEquals($itemCollectionTransfer->toArray(), $decoded);
+ $this->assertArraysAreEqual($itemCollectionTransfer->toArray(), $decoded);
}
- #[TestDox('Transfer count')]
+ #[TestDox('Transfer count()')]
public function testTransferCount(): void
{
// Arrange
@@ -318,11 +319,10 @@ public function testTransferCount(): void
$actual = $itemCollectionTransfer->count();
// Assert
- $this->assertEquals(2, $actual);
- $this->assertCount(2, $itemCollectionTransfer);
+ $this->assertSame(2, $actual);
}
- #[TestDox('Transfer debugInfo')]
+ #[TestDox('Transfer debugInfo()')]
public function testTransferDebugInfo(): void
{
// Arrange
@@ -333,11 +333,11 @@ public function testTransferDebugInfo(): void
$actual = $itemCollectionTransfer->__debugInfo();
// Assert
- $this->assertEquals($itemCollectionTransfer->toArray(), $actual);
+ $this->assertArraysAreEqual($itemCollectionTransfer->toArray(), $actual);
}
#[WithoutErrorHandler]
- #[TestDox('Type mismatch fromArray should fail with error')]
+ #[TestDox('Type mismatch fromArray() should fail with error')]
public function testTypeMismatchFromArrayShouldFailWithError(): void
{
// Arrange
@@ -352,8 +352,8 @@ public function testTypeMismatchFromArrayShouldFailWithError(): void
]);
}
- #[TestDox('Access required property before initialising should throw exception')]
- public function testAccessRequiredPropertyBeforeInitialisingShouldThrowException(): void
+ #[TestDox('Access required property before initializing should throw exception')]
+ public function testAccessRequiredPropertyBeforeInitializingShouldThrowException(): void
{
// Arrange
$requiredTransfer = new RequiredTransfer();
@@ -531,7 +531,7 @@ public function testTransformationBcMathFromToArrayWithInvalidTypeShouldThrowExc
#[RequiresPhpExtension('bcmath')]
#[Depends('testGenerateBcMathTransfer')]
- #[TestDox('Transformation transfer object BcMath fromArray to toArray with BcMath')]
+ #[TestDox('Transformation transfer object fromArray() and toArray() with BcMath')]
public function testTransformationBcMathFromToArrayWhereArrayHasBcMath(): void
{
// Arrange
diff --git a/tests/integration/TransferGenerator/Config/Loader/ConfigLoaderTest.php b/tests/integration/TransferGenerator/Config/Loader/ConfigLoaderTest.php
index 7d1b9815..fd2afe75 100644
--- a/tests/integration/TransferGenerator/Config/Loader/ConfigLoaderTest.php
+++ b/tests/integration/TransferGenerator/Config/Loader/ConfigLoaderTest.php
@@ -45,11 +45,11 @@ public static function invalidConfigDataProvider(): Generator
{
yield 'config file does not exist' => ['config-file-does-not-exist.config.yml'];
- yield 'missed required keys' => ['missed-required-keys.config.yml'];
+ yield 'missing required keys' => ['missed-required-keys.config.yml'];
- yield 'definition path is not local' => ['definition-path-is-not-exist.config.yml'];
+ yield 'definition path does not exist' => ['definition-path-does-not-exist.config.yml'];
- yield 'definition path is not exist' => ['definition-path-is-not-local.config.yml'];
+ yield 'definition path is not local' => ['definition-path-is-not-local.config.yml'];
yield 'invalid namespace' => ['invalid-transfer-namespace.config.yml'];
@@ -59,6 +59,6 @@ public static function invalidConfigDataProvider(): Generator
yield 'invalid definition root key' => ['invalid-definition-root-key.config.yml'];
- yield 'transfer path is not exist' => ['transfer-path-is-not-local.config.yml'];
+ yield 'transfer path is not local' => ['transfer-path-is-not-local.config.yml'];
}
}
diff --git a/tests/integration/TransferGenerator/TransferGeneratorFacadeErrorTest.php b/tests/integration/TransferGenerator/TransferGeneratorFacadeErrorTest.php
index 22505bb8..40964251 100644
--- a/tests/integration/TransferGenerator/TransferGeneratorFacadeErrorTest.php
+++ b/tests/integration/TransferGenerator/TransferGeneratorFacadeErrorTest.php
@@ -113,7 +113,7 @@ public static function invalidDefinitionDataProvider(): Generator
'expectedMessage' => 'Invalid class name',
];
- yield 'missed property type should return error' => [
+ yield 'missing property type should return error' => [
'configCaseName' => 'missed-type',
'expectedMessage' => 'Property "addressUuid" type definition is missing or set multiple times.',
];
@@ -140,12 +140,12 @@ public static function invalidDefinitionDataProvider(): Generator
yield 'definition file include class without properties should return error' => [
'configCaseName' => 'empty-property-definition',
- 'expectedMessage' => 'Class "AddressStatisticsTransfer" properties were not defined.',
+ 'expectedMessage' => 'Properties for class "AddressStatisticsTransfer" are not defined.',
];
- yield 'definitions not found should return error' => [
+ yield 'definitions were not found should return error' => [
'configCaseName' => 'empty-definition-directory',
- 'expectedMessage' => 'Missed Transfer Object definitions.',
+ 'expectedMessage' => 'Missing Transfer Object definitions.',
];
yield 'definition file is empty' => [
@@ -189,8 +189,8 @@ public static function invalidDefinitionDataProvider(): Generator
];
}
- #[TestDox('Fail generate transfer objects')]
- public function testFailGenerateTransferObjects(): void
+ #[TestDox('Failed to generate transfer objects')]
+ public function testFailedToGenerateTransferObjects(): void
{
// Arrange
$configPath = $this->getConfigPath('invalid-class-name');
diff --git a/tests/integration/TransferGenerator/data/config/error/definition-path-is-not-exist.config.yml b/tests/integration/TransferGenerator/data/config/error/definition-path-does-not-exist.config.yml
similarity index 100%
rename from tests/integration/TransferGenerator/data/config/error/definition-path-is-not-exist.config.yml
rename to tests/integration/TransferGenerator/data/config/error/definition-path-does-not-exist.config.yml
diff --git a/tests/unit/DefinitionGenerator/Content/Expander/TransferTypeBuilderExpanderTest.php b/tests/unit/DefinitionGenerator/Content/Expander/TransferTypeBuilderExpanderTest.php
index a2ea09a4..49143f47 100644
--- a/tests/unit/DefinitionGenerator/Content/Expander/TransferTypeBuilderExpanderTest.php
+++ b/tests/unit/DefinitionGenerator/Content/Expander/TransferTypeBuilderExpanderTest.php
@@ -58,7 +58,7 @@ public function testApplicableTransferType(GetTypeEnum $type, array $propertyVal
*/
public static function applicableTransferTypeDataProvider(): Generator
{
- yield 'type is array and property value is an array with key valid variable name should expect true' => [
+ yield 'type is array and property value is an array with a valid variable name key should expect true' => [
'type' => GetTypeEnum::array,
'propertyValue' => [
'product' => ['sku' => 123],
@@ -86,7 +86,7 @@ public static function applicableTransferTypeDataProvider(): Generator
'expected' => false,
];
- yield 'type is array and property value is an array with key is invalid variable name should expect false' => [
+ yield 'type is array and property value is an array with an invalid variable name key should expect false' => [
'type' => GetTypeEnum::array,
'propertyValue' => [
'2024-12-26' => ['sku' => 123],
diff --git a/tests/unit/DefinitionGenerator/Generator/Builder/DefinitionGeneratorBuilderTest.php b/tests/unit/DefinitionGenerator/Generator/Builder/DefinitionGeneratorBuilderTest.php
index e99bbc47..83cfb1d7 100644
--- a/tests/unit/DefinitionGenerator/Generator/Builder/DefinitionGeneratorBuilderTest.php
+++ b/tests/unit/DefinitionGenerator/Generator/Builder/DefinitionGeneratorBuilderTest.php
@@ -57,16 +57,20 @@ public function testDefinitionFileIsNotLocalShouldThrowException(): void
$this->pathValidatorMock->expects($this->once())
->method('validate')
->with($definitionPath)
- ->willReturn($messageTransfer);
+ ->willReturn($messageTransfer)
+ ->seal();
$this->fileSizeValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->classNameValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->jsonReaderMock->expects($this->never())
- ->method('getJsonContent');
+ ->method('getJsonContent')
+ ->seal();
$this->expectException(DefinitionGeneratorException::class);
@@ -84,18 +88,22 @@ public function testDefinitionFileExceedsMaxSizeLimitShouldThrowException(): voi
// Expect
$this->pathValidatorMock->expects($this->once())
->method('validate')
- ->with($definitionPath);
+ ->with($definitionPath)
+ ->seal();
$this->fileSizeValidatorMock->expects($this->once())
->method('validate')
->with($definitionPath)
- ->willReturn($messageTransfer);
+ ->willReturn($messageTransfer)
+ ->seal();
$this->classNameValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->jsonReaderMock->expects($this->never())
- ->method('getJsonContent');
+ ->method('getJsonContent')
+ ->seal();
$this->expectException(DefinitionGeneratorException::class);
@@ -114,16 +122,20 @@ public function testInvalidClassNameShouldThrowException(): void
$this->classNameValidatorMock->expects($this->once())
->method('validate')
->with($className)
- ->willReturn($messageTransfer);
+ ->willReturn($messageTransfer)
+ ->seal();
$this->pathValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->fileSizeValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->jsonReaderMock->expects($this->never())
- ->method('getJsonContent');
+ ->method('getJsonContent')
+ ->seal();
$this->expectException(DefinitionGeneratorException::class);
$this->expectExceptionMessage($messageTransfer->errorMessage);
@@ -143,16 +155,20 @@ public function testInvalidJsonPathShouldThrowException(): void
$this->jsonReaderMock->expects($this->once())
->method('getJsonContent')
->with($jsonPath)
- ->willThrowException(new JsonReaderException($messageTransfer->errorMessage));
+ ->willThrowException(new JsonReaderException($messageTransfer->errorMessage))
+ ->seal();
$this->classNameValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->pathValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->fileSizeValidatorMock->expects($this->never())
- ->method('validate');
+ ->method('validate')
+ ->seal();
$this->expectException(JsonReaderException::class);
$this->expectExceptionMessage($messageTransfer->errorMessage);
diff --git a/tests/unit/DefinitionGenerator/Generator/Render/DefinitionRenderTest.php b/tests/unit/DefinitionGenerator/Generator/Render/DefinitionRenderTest.php
index 46641eb1..3bba5d74 100644
--- a/tests/unit/DefinitionGenerator/Generator/Render/DefinitionRenderTest.php
+++ b/tests/unit/DefinitionGenerator/Generator/Render/DefinitionRenderTest.php
@@ -63,7 +63,7 @@ public static function successfulRenderTestDoxFormatter(array $propertyData, str
public static function successfulRenderDataProvider(): Generator
{
- yield 'transfer object with build in property type' => [
+ yield 'transfer object with built-in property type' => [
'propertyData' => [
DefinitionPropertyTransfer::PROPERTY_NAME_PROP => 'testProperty',
DefinitionPropertyTransfer::BUILT_IN_TYPE_PROP => [
diff --git a/tests/unit/Shared/Filesystem/FileAppenderTest.php b/tests/unit/Shared/Filesystem/FileAppenderTest.php
index fd59eeef..05d2cd10 100644
--- a/tests/unit/Shared/Filesystem/FileAppenderTest.php
+++ b/tests/unit/Shared/Filesystem/FileAppenderTest.php
@@ -37,14 +37,15 @@ public static function tearDownAfterClass(): void
self::closeFile();
}
- #[TestDox('Failed open file should throw exception')]
- public function testFailedOpenFileShouldThrowException(): void
+ #[TestDox('Failed to open file should throw exception')]
+ public function testFailedToOpenFileShouldThrowException(): void
{
// Expect
$this->fileAppenderMock->expects($this->once())
->method('fopen')
->with(self::FILE_NAME)
- ->willReturn(false);
+ ->willReturn(false)
+ ->seal();
$this->expectException(FileAppenderException::class);
@@ -52,8 +53,8 @@ public function testFailedOpenFileShouldThrowException(): void
$this->fileAppenderMock->appendToFile(self::FILE_NAME, self::FILE_CONTENT);
}
- #[TestDox('Failed write file should throw exception')]
- public function testFailedWriteFileShouldThrowException(): void
+ #[TestDox('Failed to write file should throw exception')]
+ public function testFailedToWriteFileShouldThrowException(): void
{
// Arrange
$file = self::openFile();
@@ -66,7 +67,9 @@ public function testFailedWriteFileShouldThrowException(): void
$this->fileAppenderMock->expects($this->once())
->method('fwrite')
- ->willReturn(false);
+ ->with($this->isResource(), self::FILE_CONTENT)
+ ->willReturn(false)
+ ->seal();
$this->expectException(FileAppenderException::class);
@@ -88,7 +91,9 @@ public function testSuccessfulWriteFile(): void
$this->fileAppenderMock->expects($this->exactly(2))
->method('fwrite')
- ->willReturn(1);
+ ->with($this->isResource(), self::FILE_CONTENT)
+ ->willReturn(1)
+ ->seal();
// Act
$this->fileAppenderMock->appendToFile(self::FILE_NAME, self::FILE_CONTENT);
@@ -109,26 +114,29 @@ public function testCloseFile(): void
$this->fileAppenderMock->expects($this->once())
->method('fwrite')
+ ->with($this->isResource(), self::FILE_CONTENT)
->willReturn(1);
$this->fileAppenderMock->expects($this->once())
->method('fclose')
- ->willReturn(true);
+ ->willReturn(true)
+ ->seal();
// Act
$this->fileAppenderMock->appendToFile(self::FILE_NAME, self::FILE_CONTENT);
$this->fileAppenderMock->closeFile(self::FILE_NAME);
}
- #[TestDox('File is not exist in the cache should skip closing file')]
- public function testFileIsNotExistInTheCacheShouldSkipCloseFile(): void
+ #[TestDox('File does not exist in the cache should skip closing file')]
+ public function testFileDoesNotExistInTheCacheShouldSkipClosingFile(): void
{
// Arrange
$fileName = 'some-name.txt';
// Expect
$this->fileAppenderMock->expects($this->never())
- ->method('fclose');
+ ->method('fclose')
+ ->seal();
// Act
$this->fileAppenderMock->closeFile($fileName);
@@ -148,11 +156,13 @@ public function testFailedCloseFile(): void
$this->fileAppenderMock->expects($this->once())
->method('fwrite')
+ ->with($this->isResource(), self::FILE_CONTENT)
->willReturn(1);
$this->fileAppenderMock->expects($this->once())
->method('fclose')
- ->willReturn(false);
+ ->willReturn(false)
+ ->seal();
$this->expectException(FileAppenderException::class);
diff --git a/tests/unit/Shared/Filesystem/FileReaderTest.php b/tests/unit/Shared/Filesystem/FileReaderTest.php
index bd5f735e..0712c7d0 100644
--- a/tests/unit/Shared/Filesystem/FileReaderTest.php
+++ b/tests/unit/Shared/Filesystem/FileReaderTest.php
@@ -37,12 +37,13 @@ public static function tearDownAfterClass(): void
self::closeFile();
}
- #[TestDox('Failed open file should throw exception')]
- public function testFailOpenFileShouldThrowException(): void
+ #[TestDox('Failed to open file should throw exception')]
+ public function testFailedToOpenFileShouldThrowException(): void
{
// Expect
$this->fileReaderMock->expects($this->once())
->method('fopen')
+ ->with(self::FILE_NAME)
->willReturn(false);
$this->fileReaderMock->expects($this->never())
@@ -52,7 +53,8 @@ public function testFailOpenFileShouldThrowException(): void
->method('feof');
$this->fileReaderMock->expects($this->never())
- ->method('fclose');
+ ->method('fclose')
+ ->seal();
$this->expectException(FileReaderException::class);
@@ -60,8 +62,8 @@ public function testFailOpenFileShouldThrowException(): void
$this->fileReaderMock->readFile(self::FILE_NAME)->current();
}
- #[TestDox('Failed read file should throw exception')]
- public function testFailedReadFileShouldThrowException(): void
+ #[TestDox('Failed to read file should throw exception')]
+ public function testFailedToReadFileShouldThrowException(): void
{
// Arrange
$file = self::openFile();
@@ -69,19 +71,24 @@ public function testFailedReadFileShouldThrowException(): void
// Expect
$this->fileReaderMock->expects($this->once())
->method('fopen')
+ ->with(self::FILE_NAME)
->willReturn($file);
$this->fileReaderMock->expects($this->once())
->method('fgets')
+ ->with($this->isResource())
->willReturn(false);
$this->fileReaderMock->expects($this->once())
->method('feof')
+ ->with($this->isResource())
->willReturn(false);
$this->fileReaderMock->expects($this->once())
->method('fclose')
- ->willReturn(true);
+ ->with($this->isResource())
+ ->willReturn(true)
+ ->seal();
$this->expectException(FileReaderException::class);
@@ -89,8 +96,8 @@ public function testFailedReadFileShouldThrowException(): void
$this->fileReaderMock->readFile(self::FILE_NAME)->current();
}
- #[TestDox('Failed close file should throw exception')]
- public function testFailedCloseFileShouldThrowException(): void
+ #[TestDox('Failed to close file should throw exception')]
+ public function testFailedToCloseFileShouldThrowException(): void
{
// Arrange
$file = self::openFile();
@@ -98,19 +105,24 @@ public function testFailedCloseFileShouldThrowException(): void
// Expect
$this->fileReaderMock->expects($this->once())
->method('fopen')
+ ->with(self::FILE_NAME)
->willReturn($file);
$this->fileReaderMock->expects($this->once())
->method('fgets')
+ ->with($this->isResource())
->willReturn(false);
$this->fileReaderMock->expects($this->once())
->method('feof')
+ ->with($this->isResource())
->willReturn(true);
$this->fileReaderMock->expects($this->once())
->method('fclose')
- ->willReturn(false);
+ ->with($this->isResource())
+ ->willReturn(false)
+ ->seal();
$this->expectException(FileReaderException::class);
@@ -128,24 +140,29 @@ public function testReadFileShouldSkipEmptyLines(): void
// Expect
$this->fileReaderMock->expects($this->once())
->method('fopen')
+ ->with(self::FILE_NAME)
->willReturn($file);
$this->fileReaderMock->expects($this->exactly(3))
->method('fgets')
- ->willReturnOnConsecutiveCalls('', $expected[0], false);
+ ->with($this->isResource())
+ ->willReturn('', $expected[0], false);
$this->fileReaderMock->expects($this->once())
->method('feof')
+ ->with($this->isResource())
->willReturn(true);
$this->fileReaderMock->expects($this->once())
->method('fclose')
- ->willReturn(true);
+ ->with($this->isResource())
+ ->willReturn(true)
+ ->seal();
// Act
$actual = $this->fileReaderMock->readFile(self::FILE_NAME);
// Assert
- $this->assertSame($expected, iterator_to_array($actual));
+ $this->assertArraysAreIdentical($expected, iterator_to_array($actual));
}
}
diff --git a/tests/unit/Shared/Reader/FileReaderProgressTest.php b/tests/unit/Shared/Reader/FileReaderProgressTest.php
index d5e80e08..ac0ae555 100644
--- a/tests/unit/Shared/Reader/FileReaderProgressTest.php
+++ b/tests/unit/Shared/Reader/FileReaderProgressTest.php
@@ -52,7 +52,8 @@ public function testReadFile(): void
$this->fileReaderMock->expects($this->once())
->method('readFile')
->with($filename)
- ->willReturn($contentGenerator());
+ ->willReturn($contentGenerator())
+ ->seal();
$this->fileReaderProgressMock->expects($this->once())
->method('fileExists')
@@ -62,7 +63,8 @@ public function testReadFile(): void
$this->fileReaderProgressMock->expects($this->once())
->method('filesize')
->with($filename)
- ->willReturn($filesize);
+ ->willReturn($filesize)
+ ->seal();
// Act
$actual = $this->fileReaderProgressMock->readFile($filename)->current();
@@ -76,7 +78,7 @@ public function testReadFile(): void
#[TestWith([0])]
#[TestWith([false])]
- #[TestDox('Empty file size "$filesize" should throw exception')]
+ #[TestDox('Empty file "$filesize" should throw exception')]
public function testEmptyFileShouldThrowException(int|false $filesize): void
{
// Arrange
@@ -84,7 +86,8 @@ public function testEmptyFileShouldThrowException(int|false $filesize): void
// Expect
$this->fileReaderMock->expects($this->never())
- ->method('readFile');
+ ->method('readFile')
+ ->seal();
$this->fileReaderProgressMock->expects($this->once())
->method('fileExists')
@@ -94,7 +97,8 @@ public function testEmptyFileShouldThrowException(int|false $filesize): void
$this->fileReaderProgressMock->expects($this->once())
->method('filesize')
->with($filename)
- ->willReturn($filesize);
+ ->willReturn($filesize)
+ ->seal();
// Expect
$this->expectException(FileReaderException::class);
@@ -103,15 +107,16 @@ public function testEmptyFileShouldThrowException(int|false $filesize): void
$this->fileReaderProgressMock->readFile($filename)->current();
}
- #[TestDox('File not exist should throw exception')]
- public function testFileNotExistShouldThrowException(): void
+ #[TestDox('File does not exist should throw exception')]
+ public function testFileDoesNotExistShouldThrowException(): void
{
// Arrange
$filename = 'some-path/test.txt';
// Expect
$this->fileReaderMock->expects($this->never())
- ->method('readFile');
+ ->method('readFile')
+ ->seal();
$this->fileReaderProgressMock->expects($this->once())
->method('fileExists')
@@ -119,7 +124,8 @@ public function testFileNotExistShouldThrowException(): void
->willReturn(false);
$this->fileReaderProgressMock->expects($this->never())
- ->method('filesize');
+ ->method('filesize')
+ ->seal();
// Expect
$this->expectException(FileReaderException::class);
diff --git a/tests/unit/Shared/Reader/JsonReaderTest.php b/tests/unit/Shared/Reader/JsonReaderTest.php
index cba35ec8..2a98095c 100644
--- a/tests/unit/Shared/Reader/JsonReaderTest.php
+++ b/tests/unit/Shared/Reader/JsonReaderTest.php
@@ -30,14 +30,14 @@ protected function setUp(): void
$this->reader = new JsonReader($this->filesystemStub);
}
- #[TestDox('Failed getJsonContent should throw exception')]
- public function testFailedGetJsonContentShouldThrowException(): void
+ #[TestDox('Failed to getJsonContent should throw exception')]
+ public function testFailedToGetJsonContentShouldThrowException(): void
{
// Expect
$this->filesystemStub
->method('readFile')
- ->with(self::FILE_PATH)
- ->willThrowException(new FilesystemException());
+ ->willThrowException(new FilesystemException())
+ ->seal();
$this->expectException(JsonReaderException::class);
@@ -55,13 +55,13 @@ public function testSuccessfulGetJsonContent(): void
// Expect
$this->filesystemStub
->method('readFile')
- ->with(self::FILE_PATH)
- ->willReturn($jsonString);
+ ->willReturn($jsonString)
+ ->seal();
// Act
$actual = $this->reader->getJsonContent(self::FILE_PATH);
// Assert
- $this->assertSame($expected, $actual);
+ $this->assertArraysAreIdentical($expected, $actual);
}
}
diff --git a/tests/unit/Shared/Validator/FileSizeValidatorTest.php b/tests/unit/Shared/Validator/FileSizeValidatorTest.php
index a4bd2ef6..1f0995f7 100644
--- a/tests/unit/Shared/Validator/FileSizeValidatorTest.php
+++ b/tests/unit/Shared/Validator/FileSizeValidatorTest.php
@@ -34,7 +34,9 @@ public function testUnknownFileSize(): void
// Expect
$this->validatorMock->expects($this->once())
->method('filesize')
- ->willReturn(false);
+ ->with($path)
+ ->willReturn(false)
+ ->seal();
// Act
$actual = $this->validatorMock->validate($path);
@@ -53,7 +55,9 @@ public function testMaxFileSizeExceeded(): void
// Expect
$this->validatorMock->expects($this->once())
->method('filesize')
- ->willReturn(self::MAX_FILE_SIZE_BYTES + 10);
+ ->with($path)
+ ->willReturn(self::MAX_FILE_SIZE_BYTES + 10)
+ ->seal();
// Act
$actual = $this->validatorMock->validate($path);
diff --git a/tests/unit/TransferGenerator/Config/Config/ConfigProxyTest.php b/tests/unit/TransferGenerator/Config/Config/ConfigProxyTest.php
index 64fb4c35..f050bcb1 100644
--- a/tests/unit/TransferGenerator/Config/Config/ConfigProxyTest.php
+++ b/tests/unit/TransferGenerator/Config/Config/ConfigProxyTest.php
@@ -21,8 +21,8 @@ protected function setUp(): void
$this->proxy = new ConfigProxy();
}
- #[TestDox('Get transfer namespace without loading config first should throw exception')]
- public function testGetTransferNamespaceWithoutLoadingConfigFirstShouldThrowException(): void
+ #[TestDox('Get transfer namespace without loading the config first should throw exception')]
+ public function testGetTransferNamespaceWithoutLoadingTheConfigFirstShouldThrowException(): void
{
// Arrange
ConfigProxy::resetConfig();
diff --git a/tests/unit/TransferGenerator/Config/Environment/ConfigEnvironmentRenderTest.php b/tests/unit/TransferGenerator/Config/Environment/ConfigEnvironmentRenderTest.php
index 32367357..76d45f30 100644
--- a/tests/unit/TransferGenerator/Config/Environment/ConfigEnvironmentRenderTest.php
+++ b/tests/unit/TransferGenerator/Config/Environment/ConfigEnvironmentRenderTest.php
@@ -39,7 +39,8 @@ public function testEnvironmentVariableIsSet(): void
->willReturn($envProjectRoot);
$this->renderMock->expects($this->never())
- ->method('getWorkingDir');
+ ->method('getWorkingDir')
+ ->seal();
// Act
$this->renderMock->renderProjectRoot($configPath);
@@ -64,7 +65,8 @@ public function testEnvironmentVariableIsNotSetShouldFallbackToWorkingDirectory(
$this->renderMock->expects($this->once())
->method('getWorkingDir')
- ->willReturn($workingDirectory);
+ ->willReturn($workingDirectory)
+ ->seal();
// Act
$actual = $this->renderMock->renderProjectRoot($configPath);
diff --git a/tests/unit/TransferGenerator/Definition/Parser/Expander/Builder/NamespaceBuilderTest.php b/tests/unit/TransferGenerator/Definition/Parser/Expander/Builder/NamespaceBuilderTest.php
index 984fc42f..6563383f 100644
--- a/tests/unit/TransferGenerator/Definition/Parser/Expander/Builder/NamespaceBuilderTest.php
+++ b/tests/unit/TransferGenerator/Definition/Parser/Expander/Builder/NamespaceBuilderTest.php
@@ -34,7 +34,7 @@ public function testCreateDefinitionNamespaceTransfer(string $namespace, array $
$actual = $this->builder->createNamespaceTransfer($namespace);
// Assert
- $this->assertEquals($expected, $actual->toArray());
+ $this->assertArraysAreEqual($expected, $actual->toArray());
}
/**
diff --git a/tests/unit/TransferGenerator/Definition/Validator/Content/Property/NumberTypePropertyValidatorTest.php b/tests/unit/TransferGenerator/Definition/Validator/Content/Property/NumberTypePropertyValidatorTest.php
index 6c7a27e7..db8162a1 100644
--- a/tests/unit/TransferGenerator/Definition/Validator/Content/Property/NumberTypePropertyValidatorTest.php
+++ b/tests/unit/TransferGenerator/Definition/Validator/Content/Property/NumberTypePropertyValidatorTest.php
@@ -36,7 +36,8 @@ public function testBcMathIsNotLoadedShouldReturnError(): void
// Expect
$this->validatorMock->expects($this->once())
->method('isBcMathLoaded')
- ->willReturn(false);
+ ->willReturn(false)
+ ->seal();
// Act
$actual = $this->validatorMock->validate($propertyTransfer);
@@ -69,7 +70,8 @@ public function testInvalidBcMathTypeShouldReturnError(): void
// Expect
$this->validatorMock->expects($this->once())
->method('isBcMathLoaded')
- ->willReturn(true);
+ ->willReturn(true)
+ ->seal();
// Act
$actual = $this->validatorMock->validate($propertyTransfer);
diff --git a/tests/unit/TransferGenerator/Generator/Filesystem/GeneratorFilesystemTest.php b/tests/unit/TransferGenerator/Generator/Filesystem/GeneratorFilesystemTest.php
index b2821e3d..56812abf 100644
--- a/tests/unit/TransferGenerator/Generator/Filesystem/GeneratorFilesystemTest.php
+++ b/tests/unit/TransferGenerator/Generator/Filesystem/GeneratorFilesystemTest.php
@@ -40,8 +40,8 @@ protected function setUp(): void
);
}
- #[TestDox('Duplication file write should throw exception')]
- public function testDuplicationFileWriteShouldThrowException(): void
+ #[TestDox('Duplicate file write should throw exception')]
+ public function testDuplicateFileWriteShouldThrowException(): void
{
// Arrange
$contentTransfer = new TransferGeneratorContentTransfer([
@@ -53,11 +53,13 @@ public function testDuplicationFileWriteShouldThrowException(): void
$this->configStub
->method('getTransferPath')
- ->willReturn($transferPath);
+ ->willReturn($transferPath)
+ ->seal();
$this->filesystemStub
->method('exists')
- ->willReturn(true);
+ ->willReturn(true)
+ ->seal();
// Expect
$this->expectException(TransferGeneratorException::class);
diff --git a/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PostProcessCommandTest.php b/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PostProcessCommandTest.php
index d610a2e9..b7406f8f 100644
--- a/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PostProcessCommandTest.php
+++ b/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PostProcessCommandTest.php
@@ -39,7 +39,8 @@ public function testFilesystemExceptionShouldBeHandledOnPostProcessSuccess(): vo
// Arrange
$this->filesystemStub
->method('rotateTempDir')
- ->willThrowException(new FilesystemException());
+ ->willThrowException(new FilesystemException())
+ ->seal();
// Act
$actual = $this->command->postProcess(true);
@@ -54,7 +55,8 @@ public function testFilesystemExceptionShouldBeHandledOnPostProcessError(): void
// Arrange
$this->filesystemStub
->method('deleteTempDir')
- ->willThrowException(new FilesystemException());
+ ->willThrowException(new FilesystemException())
+ ->seal();
// Act
$actual = $this->command->postProcess(false);
diff --git a/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PreProcessCommandTest.php b/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PreProcessCommandTest.php
index 8caca898..c7ecb92d 100644
--- a/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PreProcessCommandTest.php
+++ b/tests/unit/TransferGenerator/Generator/Generator/Processor/Command/PreProcessCommandTest.php
@@ -53,12 +53,13 @@ public function testFilesystemExceptionShouldBeHandledOnCommand(): void
$this->configLoaderStub
->method('loadConfig')
- ->with($configPath)
- ->willReturn($configTransfer);
+ ->willReturn($configTransfer)
+ ->seal();
$this->filesystemStub
->method('createTempDir')
- ->willThrowException(new FilesystemException());
+ ->willThrowException(new FilesystemException())
+ ->seal();
// Act
$actual = $this->command->preProcess($configPath);
diff --git a/tests/unit/TransferGenerator/Generator/Generator/ServiceTransferGeneratorTest.php b/tests/unit/TransferGenerator/Generator/Generator/ServiceTransferGeneratorTest.php
index 8c68b193..ef3ddef7 100644
--- a/tests/unit/TransferGenerator/Generator/Generator/ServiceTransferGeneratorTest.php
+++ b/tests/unit/TransferGenerator/Generator/Generator/ServiceTransferGeneratorTest.php
@@ -38,7 +38,8 @@ public function testGeneratorIteratesInvalidItemShouldThrowException(): void
$this->generatorStub
->method('generateTransfers')
- ->willReturnCallback(fn() => yield $generatorTransfer);
+ ->willReturnCallback(fn() => yield $generatorTransfer)
+ ->seal();
// Expect
$this->expectException(TransferGeneratorException::class);
diff --git a/tests/unit/TransferGenerator/Generator/Render/Template/TemplateHelperTest.php b/tests/unit/TransferGenerator/Generator/Render/Template/TemplateHelperTest.php
index a4edf028..d57dd0ab 100644
--- a/tests/unit/TransferGenerator/Generator/Render/Template/TemplateHelperTest.php
+++ b/tests/unit/TransferGenerator/Generator/Render/Template/TemplateHelperTest.php
@@ -64,7 +64,7 @@ public static function getRequiredDataProvider(): Generator
'expected' => '',
];
- yield 'property is nullable but with intersection type should return empty string' => [
+ yield 'property is nullable but with an intersection type should return an empty string' => [
'templateData' => [
TemplateTransfer::PROPERTIES_PROP => [
'test' => 'TestTransfer&TTransferInterface',
@@ -90,7 +90,7 @@ public static function getRequiredDataProvider(): Generator
'expected' => 'null|',
];
- yield 'property is nullable without intersection or union should return null type' => [
+ yield 'property is nullable without intersection or union should return the null type' => [
'templateData' => [
TemplateTransfer::PROPERTIES_PROP => [
'test' => 'TestTransfer',
diff --git a/tests/unit/TransferGenerator/Generator/Render/TemplateRenderTest.php b/tests/unit/TransferGenerator/Generator/Render/TemplateRenderTest.php
index 5a20bd8f..9128f157 100644
--- a/tests/unit/TransferGenerator/Generator/Render/TemplateRenderTest.php
+++ b/tests/unit/TransferGenerator/Generator/Render/TemplateRenderTest.php
@@ -50,7 +50,8 @@ public function testRenderEmptyTemplate(): void
$this->builderStub
->method('createTemplateTransfer')
- ->willReturn($templateTransfer);
+ ->willReturn($templateTransfer)
+ ->seal();
// Act
$actual = $this->render->renderTemplate($definitionTransfer);