diff --git a/composer.json b/composer.json index efbd4a0..db3fe75 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,7 @@ "require-dev": { "ext-sqlite3": "*", "phpstan/phpstan": "^v1.10", - "phpunit/phpunit": "^10.1", + "phpunit/phpunit": "^10.1 || ^12.0", "phpmd/phpmd": "^2.13", "squizlabs/php_codesniffer": "^3.7 || ^4.0" }, diff --git a/composer.lock b/composer.lock index 0626661..bdefa3f 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": "57e551e69565db7ecbf791b59877863c", + "content-hash": "9550657384725499f5d4d13f02fa6727", "packages": [ { "name": "greenlion/php-sql-parser", @@ -961,35 +961,33 @@ }, { "name": "phpunit/php-code-coverage", - "version": "10.1.16", + "version": "12.5.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "7e308268858ed6baedc8704a304727d20bc07c77" + "reference": "7440368d94738d54f2c1de24dbd3871793bbb0dd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/7e308268858ed6baedc8704a304727d20bc07c77", - "reference": "7e308268858ed6baedc8704a304727d20bc07c77", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/7440368d94738d54f2c1de24dbd3871793bbb0dd", + "reference": "7440368d94738d54f2c1de24dbd3871793bbb0dd", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.19.1 || ^5.1.0", - "php": ">=8.1", - "phpunit/php-file-iterator": "^4.1.0", - "phpunit/php-text-template": "^3.0.1", - "sebastian/code-unit-reverse-lookup": "^3.0.0", - "sebastian/complexity": "^3.2.0", - "sebastian/environment": "^6.1.0", - "sebastian/lines-of-code": "^2.0.2", - "sebastian/version": "^4.0.1", - "theseer/tokenizer": "^1.2.3" + "nikic/php-parser": "^5.9.0", + "php": ">=8.3", + "phpunit/php-text-template": "^5.0.1", + "sebastian/complexity": "^5.0", + "sebastian/environment": "^8.1.2", + "sebastian/lines-of-code": "^4.0.1", + "sebastian/version": "^6.0", + "theseer/tokenizer": "^2.0.1" }, "require-dev": { - "phpunit/phpunit": "^10.1" + "phpunit/phpunit": "^12.5.37" }, "suggest": { "ext-pcov": "PHP extension that provides line coverage", @@ -998,7 +996,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "10.1.x-dev" + "dev-main": "12.5.x-dev" } }, "autoload": { @@ -1027,40 +1025,52 @@ "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/10.1.16" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/12.5.8" }, "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-code-coverage", + "type": "tidelift" } ], - "time": "2024-08-22T04:31:57+00:00" + "time": "2026-10-03T14:03:50+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "4.1.0", + "version": "6.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "a95037b6d9e608ba092da1b23931e537cadc3c3c" + "reference": "a248d1640ab059b075f53a2ef0f9856e864e06b5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/a95037b6d9e608ba092da1b23931e537cadc3c3c", - "reference": "a95037b6d9e608ba092da1b23931e537cadc3c3c", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/a248d1640ab059b075f53a2ef0f9856e864e06b5", + "reference": "a248d1640ab059b075f53a2ef0f9856e864e06b5", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.33" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -1088,36 +1098,48 @@ "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/4.1.0" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/6.0.2" }, "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-file-iterator", + "type": "tidelift" } ], - "time": "2023-08-31T06:24:48+00:00" + "time": "2026-08-25T14:40:53+00:00" }, { "name": "phpunit/php-invoker", - "version": "4.0.0", + "version": "6.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-invoker.git", - "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7" + "reference": "12b54e689b07a25a9b41e57736dfab6ec9ae5406" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", - "reference": "f5e568ba02fa5ba0ddd0f618391d5a9ea50b06d7", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/12b54e689b07a25a9b41e57736dfab6ec9ae5406", + "reference": "12b54e689b07a25a9b41e57736dfab6ec9ae5406", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { "ext-pcntl": "*", - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.0" }, "suggest": { "ext-pcntl": "*" @@ -1125,7 +1147,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -1151,7 +1173,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-invoker/issues", - "source": "https://github.com/sebastianbergmann/php-invoker/tree/4.0.0" + "security": "https://github.com/sebastianbergmann/php-invoker/security/policy", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/6.0.0" }, "funding": [ { @@ -1159,32 +1182,32 @@ "type": "github" } ], - "time": "2023-02-03T06:56:09+00:00" + "time": "2025-02-07T04:58:58+00:00" }, { "name": "phpunit/php-text-template", - "version": "3.0.1", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "0c7b06ff49e3d5072f057eb1fa59258bf287a748" + "reference": "babab73b7ef9fae406f2eb3ee11323a61caa63d5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/0c7b06ff49e3d5072f057eb1fa59258bf287a748", - "reference": "0c7b06ff49e3d5072f057eb1fa59258bf287a748", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/babab73b7ef9fae406f2eb3ee11323a61caa63d5", + "reference": "babab73b7ef9fae406f2eb3ee11323a61caa63d5", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.37" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -1211,40 +1234,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/3.0.1" + "source": "https://github.com/sebastianbergmann/php-text-template/tree/5.0.1" }, "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": "2023-08-31T14:07:24+00:00" + "time": "2026-10-03T04:51:29+00:00" }, { "name": "phpunit/php-timer", - "version": "6.0.0", + "version": "8.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d" + "reference": "f258ce36aa457f3aa3339f9ed4c81fc66dc8c2cc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/e2a2d67966e740530f4a3343fe2e030ffdc1161d", - "reference": "e2a2d67966e740530f4a3343fe2e030ffdc1161d", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/f258ce36aa457f3aa3339f9ed4c81fc66dc8c2cc", + "reference": "f258ce36aa457f3aa3339f9ed4c81fc66dc8c2cc", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.0" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "6.0-dev" + "dev-main": "8.0-dev" } }, "autoload": { @@ -1270,7 +1305,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-timer/issues", - "source": "https://github.com/sebastianbergmann/php-timer/tree/6.0.0" + "security": "https://github.com/sebastianbergmann/php-timer/security/policy", + "source": "https://github.com/sebastianbergmann/php-timer/tree/8.0.0" }, "funding": [ { @@ -1278,20 +1314,20 @@ "type": "github" } ], - "time": "2023-02-03T06:57:52+00:00" + "time": "2025-02-07T04:59:38+00:00" }, { "name": "phpunit/phpunit", - "version": "10.5.66", + "version": "12.5.38", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "747c9889613d0b3ffa08b74272e50ed3b8fa6d72" + "reference": "1e87ad87fe57665a7f6e99a6e467329c11e851cc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/747c9889613d0b3ffa08b74272e50ed3b8fa6d72", - "reference": "747c9889613d0b3ffa08b74272e50ed3b8fa6d72", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/1e87ad87fe57665a7f6e99a6e467329c11e851cc", + "reference": "1e87ad87fe57665a7f6e99a6e467329c11e851cc", "shasum": "" }, "require": { @@ -1304,26 +1340,23 @@ "myclabs/deep-copy": "^1.14.0", "phar-io/manifest": "^2.0.4", "phar-io/version": "^3.2.1", - "php": ">=8.1", - "phpunit/php-code-coverage": "^10.1.16", - "phpunit/php-file-iterator": "^4.1.0", - "phpunit/php-invoker": "^4.0.0", - "phpunit/php-text-template": "^3.0.1", - "phpunit/php-timer": "^6.0.0", - "sebastian/cli-parser": "^2.0.1", - "sebastian/code-unit": "^2.0.0", - "sebastian/comparator": "^5.0.5", - "sebastian/diff": "^5.1.1", - "sebastian/environment": "^6.1.0", - "sebastian/exporter": "^5.1.4", - "sebastian/global-state": "^6.0.2", - "sebastian/object-enumerator": "^5.0.0", - "sebastian/recursion-context": "^5.0.2", - "sebastian/type": "^4.0.0", - "sebastian/version": "^4.0.1" - }, - "suggest": { - "ext-soap": "To be able to generate mocks based on WSDL files" + "php": ">=8.3", + "phpunit/php-code-coverage": "^12.5.8", + "phpunit/php-file-iterator": "^6.0.2", + "phpunit/php-invoker": "^6.0.0", + "phpunit/php-text-template": "^5.0.1", + "phpunit/php-timer": "^8.0.0", + "sebastian/cli-parser": "^4.2.1", + "sebastian/comparator": "^7.1.8", + "sebastian/diff": "^7.0.1", + "sebastian/environment": "^8.1.2", + "sebastian/exporter": "^7.0.3", + "sebastian/global-state": "^8.0.3", + "sebastian/object-enumerator": "^7.0.0", + "sebastian/recursion-context": "^7.0.1", + "sebastian/type": "^6.0.4", + "sebastian/version": "^6.0.1", + "staabm/side-effects-detector": "^1.0.5" }, "bin": [ "phpunit" @@ -1331,7 +1364,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "10.5-dev" + "dev-main": "12.5-dev" } }, "autoload": { @@ -1363,7 +1396,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.66" + "source": "https://github.com/sebastianbergmann/phpunit/tree/12.5.38" }, "funding": [ { @@ -1371,7 +1404,7 @@ "type": "other" } ], - "time": "2026-10-05T05:46:26+00:00" + "time": "2026-10-05T05:49:30+00:00" }, { "name": "psr/container", @@ -1478,28 +1511,28 @@ }, { "name": "sebastian/cli-parser", - "version": "2.0.1", + "version": "4.2.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/cli-parser.git", - "reference": "c34583b87e7b7a8055bf6c450c2c77ce32a24084" + "reference": "7d05781b13f7dec9043a629a21d086ed74582a15" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/c34583b87e7b7a8055bf6c450c2c77ce32a24084", - "reference": "c34583b87e7b7a8055bf6c450c2c77ce32a24084", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/7d05781b13f7dec9043a629a21d086ed74582a15", + "reference": "7d05781b13f7dec9043a629a21d086ed74582a15", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.25" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "2.0-dev" + "dev-main": "4.2-dev" } }, "autoload": { @@ -1523,155 +1556,59 @@ "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/2.0.1" + "source": "https://github.com/sebastianbergmann/cli-parser/tree/4.2.1" }, "funding": [ { "url": "https://github.com/sebastianbergmann", "type": "github" - } - ], - "time": "2024-03-02T07:12:49+00:00" - }, - { - "name": "sebastian/code-unit", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit.git", - "reference": "a81fee9eef0b7a76af11d121767abc44c104e503" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/a81fee9eef0b7a76af11d121767abc44c104e503", - "reference": "a81fee9eef0b7a76af11d121767abc44c104e503", - "shasum": "" - }, - "require": { - "php": ">=8.1" - }, - "require-dev": { - "phpunit/phpunit": "^10.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "2.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" - } - ], - "description": "Collection of value objects that represent the PHP code units", - "homepage": "https://github.com/sebastianbergmann/code-unit", - "support": { - "issues": "https://github.com/sebastianbergmann/code-unit/issues", - "source": "https://github.com/sebastianbergmann/code-unit/tree/2.0.0" - }, - "funding": [ + }, { - "url": "https://github.com/sebastianbergmann", - "type": "github" - } - ], - "time": "2023-02-03T06:58:43+00:00" - }, - { - "name": "sebastian/code-unit-reverse-lookup", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", - "reference": "5e3a687f7d8ae33fb362c5c0743794bbb2420a1d", - "shasum": "" - }, - "require": { - "php": ">=8.1" - }, - "require-dev": { - "phpunit/phpunit": "^10.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "3.0-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Looks up which function or method a line of code belongs to", - "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "support": { - "issues": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/issues", - "source": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/tree/3.0.0" - }, - "funding": [ + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, { - "url": "https://github.com/sebastianbergmann", - "type": "github" + "url": "https://tidelift.com/funding/github/packagist/sebastian/cli-parser", + "type": "tidelift" } ], - "time": "2023-02-03T06:59:15+00:00" + "time": "2026-05-17T05:29:34+00:00" }, { "name": "sebastian/comparator", - "version": "5.0.5", + "version": "7.1.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "55dfef806eb7dfeb6e7a6935601fef866f8ca48d" + "reference": "7c65c1e79836812819705b473a90c12399542485" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55dfef806eb7dfeb6e7a6935601fef866f8ca48d", - "reference": "55dfef806eb7dfeb6e7a6935601fef866f8ca48d", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/7c65c1e79836812819705b473a90c12399542485", + "reference": "7c65c1e79836812819705b473a90c12399542485", "shasum": "" }, "require": { "ext-dom": "*", "ext-mbstring": "*", - "php": ">=8.1", - "sebastian/diff": "^5.0", - "sebastian/exporter": "^5.0" + "php": ">=8.3", + "sebastian/diff": "^7.0", + "sebastian/exporter": "^7.0.3" }, "require-dev": { - "phpunit/phpunit": "^10.5" + "phpunit/phpunit": "^12.5.25" + }, + "suggest": { + "ext-bcmath": "For comparing BcMath\\Number objects" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "7.1-dev" } }, "autoload": { @@ -1711,7 +1648,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", "security": "https://github.com/sebastianbergmann/comparator/security/policy", - "source": "https://github.com/sebastianbergmann/comparator/tree/5.0.5" + "source": "https://github.com/sebastianbergmann/comparator/tree/7.1.8" }, "funding": [ { @@ -1731,33 +1668,33 @@ "type": "tidelift" } ], - "time": "2026-01-24T09:25:16+00:00" + "time": "2026-05-21T04:45:25+00:00" }, { "name": "sebastian/complexity", - "version": "3.2.0", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "68ff824baeae169ec9f2137158ee529584553799" + "reference": "bad4316aba5303d0221f43f8cee37eb58d384bbb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68ff824baeae169ec9f2137158ee529584553799", - "reference": "68ff824baeae169ec9f2137158ee529584553799", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/bad4316aba5303d0221f43f8cee37eb58d384bbb", + "reference": "bad4316aba5303d0221f43f8cee37eb58d384bbb", "shasum": "" }, "require": { - "nikic/php-parser": "^4.18 || ^5.0", - "php": ">=8.1" + "nikic/php-parser": "^5.0", + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.0" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "3.2-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -1781,7 +1718,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", "security": "https://github.com/sebastianbergmann/complexity/security/policy", - "source": "https://github.com/sebastianbergmann/complexity/tree/3.2.0" + "source": "https://github.com/sebastianbergmann/complexity/tree/5.0.0" }, "funding": [ { @@ -1789,33 +1726,33 @@ "type": "github" } ], - "time": "2023-12-21T08:37:17+00:00" + "time": "2025-02-07T04:55:25+00:00" }, { "name": "sebastian/diff", - "version": "5.1.1", + "version": "7.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "c41e007b4b62af48218231d6c2275e4c9b975b2e" + "reference": "cd4cabe39f8a4e8ee6818ba99f10a05561ea4ad6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/c41e007b4b62af48218231d6c2275e4c9b975b2e", - "reference": "c41e007b4b62af48218231d6c2275e4c9b975b2e", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/cd4cabe39f8a4e8ee6818ba99f10a05561ea4ad6", + "reference": "cd4cabe39f8a4e8ee6818ba99f10a05561ea4ad6", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0", - "symfony/process": "^6.4" + "phpunit/phpunit": "^12.5.33", + "symfony/process": "^7.4.17" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "5.1-dev" + "dev-main": "7.0-dev" } }, "autoload": { @@ -1848,35 +1785,47 @@ "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", "security": "https://github.com/sebastianbergmann/diff/security/policy", - "source": "https://github.com/sebastianbergmann/diff/tree/5.1.1" + "source": "https://github.com/sebastianbergmann/diff/tree/7.0.1" }, "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": "2024-03-02T07:15:17+00:00" + "time": "2026-08-25T15:35:54+00:00" }, { "name": "sebastian/environment", - "version": "6.1.0", + "version": "8.1.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "8074dbcd93529b357029f5cc5058fd3e43666984" + "reference": "9d32c685773823b1983e256ae4ecd48a10d6e439" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/8074dbcd93529b357029f5cc5058fd3e43666984", - "reference": "8074dbcd93529b357029f5cc5058fd3e43666984", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/9d32c685773823b1983e256ae4ecd48a10d6e439", + "reference": "9d32c685773823b1983e256ae4ecd48a10d6e439", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.26" }, "suggest": { "ext-posix": "*" @@ -1884,7 +1833,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "6.1-dev" + "dev-main": "8.1-dev" } }, "autoload": { @@ -1912,42 +1861,54 @@ "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", "security": "https://github.com/sebastianbergmann/environment/security/policy", - "source": "https://github.com/sebastianbergmann/environment/tree/6.1.0" + "source": "https://github.com/sebastianbergmann/environment/tree/8.1.2" }, "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/environment", + "type": "tidelift" } ], - "time": "2024-03-23T08:47:14+00:00" + "time": "2026-05-25T13:40:20+00:00" }, { "name": "sebastian/exporter", - "version": "5.1.4", + "version": "7.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "0735b90f4da94969541dac1da743446e276defa6" + "reference": "c5e21b5de653ce0a769fb36f5cdfcb5e7a32cf23" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/0735b90f4da94969541dac1da743446e276defa6", - "reference": "0735b90f4da94969541dac1da743446e276defa6", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/c5e21b5de653ce0a769fb36f5cdfcb5e7a32cf23", + "reference": "c5e21b5de653ce0a769fb36f5cdfcb5e7a32cf23", "shasum": "" }, "require": { "ext-mbstring": "*", - "php": ">=8.1", - "sebastian/recursion-context": "^5.0" + "php": ">=8.3", + "sebastian/recursion-context": "^7.0.1" }, "require-dev": { - "phpunit/phpunit": "^10.5" + "phpunit/phpunit": "^12.5.25" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "5.1-dev" + "dev-main": "7.0-dev" } }, "autoload": { @@ -1990,7 +1951,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", "security": "https://github.com/sebastianbergmann/exporter/security/policy", - "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.4" + "source": "https://github.com/sebastianbergmann/exporter/tree/7.0.3" }, "funding": [ { @@ -2010,35 +1971,35 @@ "type": "tidelift" } ], - "time": "2025-09-24T06:09:11+00:00" + "time": "2026-05-20T04:37:17+00:00" }, { "name": "sebastian/global-state", - "version": "6.0.2", + "version": "8.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "987bafff24ecc4c9ac418cab1145b96dd6e9cbd9" + "reference": "b164d3274d6537ab462591c5755f76a8f5b1aae9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/987bafff24ecc4c9ac418cab1145b96dd6e9cbd9", - "reference": "987bafff24ecc4c9ac418cab1145b96dd6e9cbd9", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/b164d3274d6537ab462591c5755f76a8f5b1aae9", + "reference": "b164d3274d6537ab462591c5755f76a8f5b1aae9", "shasum": "" }, "require": { - "php": ">=8.1", - "sebastian/object-reflector": "^3.0", - "sebastian/recursion-context": "^5.0" + "php": ">=8.3", + "sebastian/object-reflector": "^5.0", + "sebastian/recursion-context": "^7.0.1" }, "require-dev": { "ext-dom": "*", - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.28" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "6.0-dev" + "dev-main": "8.0-dev" } }, "autoload": { @@ -2064,41 +2025,53 @@ "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/6.0.2" + "source": "https://github.com/sebastianbergmann/global-state/tree/8.0.3" }, "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/global-state", + "type": "tidelift" } ], - "time": "2024-03-02T07:19:19+00:00" + "time": "2026-06-01T15:10:33+00:00" }, { "name": "sebastian/lines-of-code", - "version": "2.0.2", + "version": "4.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/lines-of-code.git", - "reference": "856e7f6a75a84e339195d48c556f23be2ebf75d0" + "reference": "d543b8ef219dcd8da262cbb958639a96bedba10e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/856e7f6a75a84e339195d48c556f23be2ebf75d0", - "reference": "856e7f6a75a84e339195d48c556f23be2ebf75d0", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/d543b8ef219dcd8da262cbb958639a96bedba10e", + "reference": "d543b8ef219dcd8da262cbb958639a96bedba10e", "shasum": "" }, "require": { - "nikic/php-parser": "^4.18 || ^5.0", - "php": ">=8.1" + "nikic/php-parser": "^5.7.0", + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.25" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "2.0-dev" + "dev-main": "4.0-dev" } }, "autoload": { @@ -2122,42 +2095,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/2.0.2" + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/4.0.1" }, "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": "2023-12-21T08:38:20+00:00" + "time": "2026-05-19T16:22:07+00:00" }, { "name": "sebastian/object-enumerator", - "version": "5.0.0", + "version": "7.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906" + "reference": "1effe8e9b8e068e9ae228e542d5d11b5d16db894" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/202d0e344a580d7f7d04b3fafce6933e59dae906", - "reference": "202d0e344a580d7f7d04b3fafce6933e59dae906", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/1effe8e9b8e068e9ae228e542d5d11b5d16db894", + "reference": "1effe8e9b8e068e9ae228e542d5d11b5d16db894", "shasum": "" }, "require": { - "php": ">=8.1", - "sebastian/object-reflector": "^3.0", - "sebastian/recursion-context": "^5.0" + "php": ">=8.3", + "sebastian/object-reflector": "^5.0", + "sebastian/recursion-context": "^7.0" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.0" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "7.0-dev" } }, "autoload": { @@ -2179,7 +2164,8 @@ "homepage": "https://github.com/sebastianbergmann/object-enumerator/", "support": { "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", - "source": "https://github.com/sebastianbergmann/object-enumerator/tree/5.0.0" + "security": "https://github.com/sebastianbergmann/object-enumerator/security/policy", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/7.0.0" }, "funding": [ { @@ -2187,32 +2173,32 @@ "type": "github" } ], - "time": "2023-02-03T07:08:32+00:00" + "time": "2025-02-07T04:57:48+00:00" }, { "name": "sebastian/object-reflector", - "version": "3.0.0", + "version": "5.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "24ed13d98130f0e7122df55d06c5c4942a577957" + "reference": "4bfa827c969c98be1e527abd576533293c634f6a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/24ed13d98130f0e7122df55d06c5c4942a577957", - "reference": "24ed13d98130f0e7122df55d06c5c4942a577957", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/4bfa827c969c98be1e527abd576533293c634f6a", + "reference": "4bfa827c969c98be1e527abd576533293c634f6a", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.0" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "5.0-dev" } }, "autoload": { @@ -2234,7 +2220,8 @@ "homepage": "https://github.com/sebastianbergmann/object-reflector/", "support": { "issues": "https://github.com/sebastianbergmann/object-reflector/issues", - "source": "https://github.com/sebastianbergmann/object-reflector/tree/3.0.0" + "security": "https://github.com/sebastianbergmann/object-reflector/security/policy", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/5.0.0" }, "funding": [ { @@ -2242,32 +2229,32 @@ "type": "github" } ], - "time": "2023-02-03T07:06:18+00:00" + "time": "2025-02-07T04:58:17+00:00" }, { "name": "sebastian/recursion-context", - "version": "5.0.2", + "version": "7.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "5d32fe257a9b39cb63146924d6b4e32a22d4502a" + "reference": "0b01998a7d5b1f122911a66bebcb8d46f0c82d8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/5d32fe257a9b39cb63146924d6b4e32a22d4502a", - "reference": "5d32fe257a9b39cb63146924d6b4e32a22d4502a", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/0b01998a7d5b1f122911a66bebcb8d46f0c82d8c", + "reference": "0b01998a7d5b1f122911a66bebcb8d46f0c82d8c", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.5" + "phpunit/phpunit": "^12.0" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "7.0-dev" } }, "autoload": { @@ -2298,7 +2285,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/5.0.2" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/7.0.1" }, "funding": [ { @@ -2318,32 +2305,32 @@ "type": "tidelift" } ], - "time": "2026-08-11T05:27:39+00:00" + "time": "2025-08-13T04:44:59+00:00" }, { "name": "sebastian/type", - "version": "4.0.0", + "version": "6.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "462699a16464c3944eefc02ebdd77882bd3925bf" + "reference": "82ff822c2edc46724be9f7411d3163021f602773" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/462699a16464c3944eefc02ebdd77882bd3925bf", - "reference": "462699a16464c3944eefc02ebdd77882bd3925bf", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/82ff822c2edc46724be9f7411d3163021f602773", + "reference": "82ff822c2edc46724be9f7411d3163021f602773", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^12.5.25" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -2366,37 +2353,50 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/4.0.0" + "security": "https://github.com/sebastianbergmann/type/security/policy", + "source": "https://github.com/sebastianbergmann/type/tree/6.0.4" }, "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/type", + "type": "tidelift" } ], - "time": "2023-02-03T07:10:45+00:00" + "time": "2026-05-20T06:45:45+00:00" }, { "name": "sebastian/version", - "version": "4.0.1", + "version": "6.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/version.git", - "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17" + "reference": "9e935a16187e14f39b0e79910dabd614972cdb26" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c51fa83a5d8f43f1402e3f32a005e6262244ef17", - "reference": "c51fa83a5d8f43f1402e3f32a005e6262244ef17", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/9e935a16187e14f39b0e79910dabd614972cdb26", + "reference": "9e935a16187e14f39b0e79910dabd614972cdb26", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.3" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "4.0-dev" + "dev-main": "6.0-dev" } }, "autoload": { @@ -2419,15 +2419,28 @@ "homepage": "https://github.com/sebastianbergmann/version", "support": { "issues": "https://github.com/sebastianbergmann/version/issues", - "source": "https://github.com/sebastianbergmann/version/tree/4.0.1" + "security": "https://github.com/sebastianbergmann/version/security/policy", + "source": "https://github.com/sebastianbergmann/version/tree/6.0.1" }, "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": "2023-02-07T11:34:05+00:00" + "time": "2026-10-04T05:50:08+00:00" }, { "name": "squizlabs/php_codesniffer", @@ -2513,6 +2526,58 @@ ], "time": "2026-08-06T02:45:27+00:00" }, + { + "name": "staabm/side-effects-detector", + "version": "1.0.5", + "source": { + "type": "git", + "url": "https://github.com/staabm/side-effects-detector.git", + "reference": "d8334211a140ce329c13726d4a715adbddd0a163" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/staabm/side-effects-detector/zipball/d8334211a140ce329c13726d4a715adbddd0a163", + "reference": "d8334211a140ce329c13726d4a715adbddd0a163", + "shasum": "" + }, + "require": { + "ext-tokenizer": "*", + "php": "^7.4 || ^8.0" + }, + "require-dev": { + "phpstan/extension-installer": "^1.4.3", + "phpstan/phpstan": "^1.12.6", + "phpunit/phpunit": "^9.6.21", + "symfony/var-dumper": "^5.4.43", + "tomasvotruba/type-coverage": "1.0.0", + "tomasvotruba/unused-public": "1.0.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "lib/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "A static analysis tool to detect side effects in PHP code", + "keywords": [ + "static analysis" + ], + "support": { + "issues": "https://github.com/staabm/side-effects-detector/issues", + "source": "https://github.com/staabm/side-effects-detector/tree/1.0.5" + }, + "funding": [ + { + "url": "https://github.com/staabm", + "type": "github" + } + ], + "time": "2024-10-20T05:08:20+00:00" + }, { "name": "symfony/config", "version": "v7.4.17", @@ -3154,23 +3219,23 @@ }, { "name": "theseer/tokenizer", - "version": "1.3.1", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "b7489ce515e168639d17feec34b8847c326b0b3c" + "reference": "7989e43bf381af0eac72e4f0ca5bcbfa81658be4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b7489ce515e168639d17feec34b8847c326b0b3c", - "reference": "b7489ce515e168639d17feec34b8847c326b0b3c", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/7989e43bf381af0eac72e4f0ca5bcbfa81658be4", + "reference": "7989e43bf381af0eac72e4f0ca5bcbfa81658be4", "shasum": "" }, "require": { "ext-dom": "*", "ext-tokenizer": "*", "ext-xmlwriter": "*", - "php": "^7.2 || ^8.0" + "php": "^8.1" }, "type": "library", "autoload": { @@ -3192,7 +3257,7 @@ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "support": { "issues": "https://github.com/theseer/tokenizer/issues", - "source": "https://github.com/theseer/tokenizer/tree/1.3.1" + "source": "https://github.com/theseer/tokenizer/tree/2.0.1" }, "funding": [ { @@ -3200,7 +3265,7 @@ "type": "github" } ], - "time": "2025-11-17T20:03:58+00:00" + "time": "2025-12-08T11:19:18+00:00" } ], "aliases": [], diff --git a/test/phpunit/Connection/DefaultSettingsTest.php b/test/phpunit/Connection/DefaultSettingsTest.php index 52220e6..4a9992b 100644 --- a/test/phpunit/Connection/DefaultSettingsTest.php +++ b/test/phpunit/Connection/DefaultSettingsTest.php @@ -40,7 +40,7 @@ public function testDefaults() { ); } - /** @dataProvider getDrivers */ + #[\PHPUnit\Framework\Attributes\DataProvider("getDrivers")] public function testDefaultPort(string $dsn, int $port) { // NOTE: Have to use a Settings object here as it's not possible to use anything other // than the default_driver otherwise @@ -64,7 +64,7 @@ public function testDefaultPort(string $dsn, int $port) { ], $settings->getConnectionSettings()); } - /** @dataProvider getDrivers */ + #[\PHPUnit\Framework\Attributes\DataProvider("getDrivers")] public function testGetConnectionSettings(string $dsn, int $port) { $settings = new DefaultSettings(); $connectionSettings = $settings->getConnectionSettings(); diff --git a/test/phpunit/DatabaseTest.php b/test/phpunit/DatabaseTest.php index 382d7b6..0fb64c8 100644 --- a/test/phpunit/DatabaseTest.php +++ b/test/phpunit/DatabaseTest.php @@ -45,7 +45,7 @@ public function testInterface() { static::assertInstanceOf(Database::class, $db); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryCollectionPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryCollectionPathExistsProvider")] public function testQueryCollectionPathExists(string $name, string $path) { $basePath = dirname($path); $settings = new Settings( @@ -59,8 +59,8 @@ public function testQueryCollectionPathExists(string $name, string $path) { static::assertInstanceOf(QueryCollection::class, $queryCollection); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider */ - public function testQueryCollectionPathNotExists(string $name, string $path) { + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] + public function testQueryCollectionPathNotExists(string $name, string $path, string $queryBase) { $basePath = dirname($path); $settings = new Settings( @@ -74,7 +74,7 @@ public function testQueryCollectionPathNotExists(string $name, string $path) { $db->queryCollection($name); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathNestedProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNestedProvider")] public function testQueryCollectionDots( array $nameParts, string $path, @@ -93,7 +93,8 @@ public function testQueryCollectionDots( self::assertInstanceOf(QueryCollection::class, $queryCollection); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryCollectionPathNotExistsProvider() */ + /* */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryCollectionPathNotExistsProvider")] public function testQueryCollectionPhp( string $name, string $path, diff --git a/test/phpunit/Migration/MigratorTest.php b/test/phpunit/Migration/MigratorTest.php index 983b68a..f380e2f 100644 --- a/test/phpunit/Migration/MigratorTest.php +++ b/test/phpunit/Migration/MigratorTest.php @@ -64,7 +64,7 @@ public function testMigrationZeroAtStartWithTable() { self::assertEquals(0, $migrator->getMigrationCount()); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testGetMigrationFileList(array $fileList) { $path = $this->getMigrationDirectory(); $this->createFiles($fileList, $path); @@ -85,7 +85,7 @@ public function testGetMigrationFileListNotExists() { $migrator->getMigrationFileList(); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testCheckFileListOrder(array $fileList) { $path = $this->getMigrationDirectory(); $this->createFiles($fileList, $path); @@ -106,7 +106,7 @@ public function testCheckFileListOrder(array $fileList) { ); } - /** @dataProvider dataMigrationFileListMissing */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileListMissing")] public function testCheckFileListOrderMissing(array $fileList) { $path = self::getMigrationDirectory(); $this->createFiles($fileList, $path); @@ -119,7 +119,7 @@ public function testCheckFileListOrderMissing(array $fileList) { $migrator->checkFileListOrder($actualFileList); } - /** @dataProvider dataMigrationFileListDuplicate */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileListDuplicate")] public function testCheckFileListOrderDuplicate(array $fileList) { $path = $this->getMigrationDirectory(); $this->createFiles($fileList, $path); @@ -176,7 +176,7 @@ public function testCheckFileListOrderIgnoresNonNumericFilesAndThrowsOnResulting $migrator->checkFileListOrder($actualFileList); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testCheckIntegrityGood(array $fileList) { $path = $this->getMigrationDirectory(); @@ -198,7 +198,7 @@ public function testCheckIntegrityGood(array $fileList) { ); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testCheckIntegrityBad(array $fileList) { $path = $this->getMigrationDirectory(); @@ -239,7 +239,7 @@ public function testMigrationCountZeroAtStart() { self::assertEquals(0, $migrator->getMigrationCount()); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationCountNotZeroAfterMigration(array $fileList) { $path = $this->getMigrationDirectory(); @@ -261,7 +261,7 @@ public function testMigrationCountNotZeroAfterMigration(array $fileList) { ); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationCountReturnsZeroOnException(array $fileList) { $path = $this->getMigrationDirectory(); @@ -271,9 +271,7 @@ public function testMigrationCountReturnsZeroOnException(array $fileList) { self::assertEquals(0, $migrator->getMigrationCount()); } - /** - * @dataProvider dataMigrationFileList - */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationFileNameFormat(array $fileList) { $path = $this->getMigrationDirectory(); @@ -300,9 +298,7 @@ public function testMigrationFileNameFormat(array $fileList) { $migrator->checkFileListOrder($absoluteFileList); } - /** - * @dataProvider dataMigrationFileList - */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testForcedMigration(array $fileList) { $path = $this->getMigrationDirectory(); @@ -325,7 +321,7 @@ public function testForcedMigration(array $fileList) { self::assertNull($exception,"Exception should not be thrown"); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testHashMismatchAfterEditingFirstFile(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -377,8 +373,8 @@ public function testHashMismatchAfterEditingFirstFile(array $fileList) { * none of the files in fileList are migrated yet, we should only see * 1 migration take place. * - * @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testResetMigration(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -418,9 +414,7 @@ public function testResetMigration(array $fileList) { self::assertSame(1, $migrationsExecuted); } - /** - * @dataProvider dataMigrationFileList - */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testPerformMigrationGood(array $fileList):void { $path = $this->getMigrationDirectory(); @@ -456,7 +450,7 @@ public function testPerformMigrationGood(array $fileList):void { ); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testPerformMigrationBad(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -479,7 +473,7 @@ public function testPerformMigrationBad(array $fileList) { $migrator->performMigration($absoluteFileList); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testPerformMigrationAlreadyCompleted(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -512,9 +506,7 @@ public function testPerformMigrationAlreadyCompleted(array $fileList) { } - /** - * @dataProvider dataMigrationFileList - */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testNonSqlExtensions(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -747,7 +739,7 @@ public function testGetDefaultTableNameReturnsMigration():void { self::assertSame("_migration", $method->invoke($migrator)); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationThrowsExceptionWhenNoMigrationTable(array $fileList) { $path = $this->getMigrationDirectory(); @@ -776,7 +768,7 @@ public function testMigrationNoOutputEmpty() { self::assertEmpty($output); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationNoOutput(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -800,7 +792,7 @@ public function testMigrationNoOutput(array $fileList) { self::assertEmpty($output); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationOutputToStream(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -828,7 +820,7 @@ public function testMigrationOutputToStream(array $fileList) { self::assertStringContainsString("$expectedCount migrations were completed successfully.", $output); } - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testMigrationErrorOutputToStream(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -1037,7 +1029,7 @@ protected function createSettings(string $path):Settings { /** * New tests for migrating from a specific file number. */ - /** @dataProvider dataMigrationFileList */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileList")] public function testPerformMigrationFromSpecificNumber(array $fileList) { $path = $this->getMigrationDirectory(); $this->createMigrationFiles($fileList, $path); @@ -1078,7 +1070,7 @@ public function testPerformMigrationFromSpecificNumber(array $fileList) { self::assertSame($expected, $migrator->getMigrationCount()); } - /** @dataProvider dataMigrationFileListMissing */ + #[\PHPUnit\Framework\Attributes\DataProvider("dataMigrationFileListMissing")] public function testCheckFileListOrderThrowsOnGapsWhenMigratingFromSpecificNumber(array $fileList) { $path = $this->getMigrationDirectory(); $this->createFiles($fileList, $path); diff --git a/test/phpunit/Query/QueryFactoryTest.php b/test/phpunit/Query/QueryFactoryTest.php index e57c261..e6f2dbc 100644 --- a/test/phpunit/Query/QueryFactoryTest.php +++ b/test/phpunit/Query/QueryFactoryTest.php @@ -15,12 +15,11 @@ use PHPUnit\Framework\TestCase; class QueryFactoryTest extends TestCase { - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testFindQueryFilePathExists( string $queryName, - string $directoryOfQueries + string $directoryOfQueries, + string $queryBase, ) { $queryFactory = new QueryFactory( $directoryOfQueries, @@ -30,10 +29,11 @@ public function testFindQueryFilePathExists( static::assertFileExists($queryFilePath); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testFindQueryFilePathNotExists( string $queryName, - string $directoryOfQueries + string $directoryOfQueries, + string $queryBase, ) { $queryFactory = new QueryFactory( $directoryOfQueries, @@ -44,10 +44,11 @@ public function testFindQueryFilePathNotExists( $queryFactory->findQueryFilePath($queryName); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExtensionNotValidProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExtensionNotValidProvider")] public function testFindQueryFilePathWithInvalidExtension( string $queryName, - string $directoryOfQueries + string $directoryOfQueries, + string $queryBase, ) { $queryFactory = new QueryFactory( $directoryOfQueries, @@ -58,10 +59,11 @@ public function testFindQueryFilePathWithInvalidExtension( $queryFactory->findQueryFilePath($queryName); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testQueryCreated( string $queryName, - string $directoryOfQueries + string $directoryOfQueries, + string $queryBase, ) { $queryFactory = new QueryFactory( $directoryOfQueries, @@ -97,10 +99,11 @@ public function testSelectsCorrectFile() { } } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testCreatePhp( string $queryName, string $directoryOfQueries, + string $queryBase, ) { $classPath = "$directoryOfQueries.php"; if(!is_dir($directoryOfQueries)) { diff --git a/test/phpunit/Query/QueryTest.php b/test/phpunit/Query/QueryTest.php index d3be1ab..f2be4d5 100644 --- a/test/phpunit/Query/QueryTest.php +++ b/test/phpunit/Query/QueryTest.php @@ -10,7 +10,7 @@ use PHPUnit\Framework\TestCase; class QueryTest extends TestCase { - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testConstructionQueryPathNotExists( string $queryName, string $queryCollectionPath, @@ -20,9 +20,7 @@ public function testConstructionQueryPathNotExists( new SqlQuery($queryPath, new Driver(new DefaultSettings())); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testConstructionQueryPathExists( string $queryName, string $queryCollectionPath, @@ -36,7 +34,7 @@ public function testConstructionQueryPathExists( } } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testExecDoesNotConnect( string $queryName, string $queryCollectionPath, diff --git a/test/phpunit/Query/SqlQueryTest.php b/test/phpunit/Query/SqlQueryTest.php index 7cd659d..9360e0e 100644 --- a/test/phpunit/Query/SqlQueryTest.php +++ b/test/phpunit/Query/SqlQueryTest.php @@ -30,7 +30,7 @@ protected function setUp():void { static::assertTrue($success, "Success inserting fake data"); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testQueryNotFound( string $queryName, string $queryCollectionPath, @@ -40,9 +40,7 @@ public function testQueryNotFound( new SqlQuery($queryPath, $this->driverSingleton()); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testQueryFound( string $queryName, string $queryCollectionPath, @@ -52,7 +50,7 @@ public function testQueryFound( static::assertFileExists($query->getFilePath()); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testBadPreparedStatementThrowsException( string $queryName, string $queryCollectionPath, @@ -64,9 +62,7 @@ public function testBadPreparedStatementThrowsException( $query->execute(); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testPreparedStatement( string $queryName, string $queryCollectionPath, @@ -83,9 +79,7 @@ public function testPreparedStatement( } } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testLastInsertId( string $queryName, string $queryCollectionPath, @@ -140,9 +134,7 @@ public function testSubsequentCalls() { } } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testPlaceholderReplacement( string $queryName, string $queryCollectionPath, @@ -159,9 +151,7 @@ public function testPlaceholderReplacement( static::assertEquals($uuid, $row->testValue); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testPlaceholderReplacementInComments( string $queryName, string $queryCollectionPath, @@ -218,7 +208,7 @@ public function testPlaceholderReplacementSubsequentCalls() { } } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testMissingIndexedParametersThrowsHelpfulException( string $queryName, string $queryCollectionPath, @@ -237,7 +227,7 @@ public function testMissingIndexedParametersThrowsHelpfulException( $query->execute([1, "one"]); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testMissingNamedParametersThrowsHelpfulException( string $queryName, string $queryCollectionPath, @@ -258,7 +248,7 @@ public function testMissingNamedParametersThrowsHelpfulException( ]); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testMissingNamedParametersIgnoreCommentsAndStrings( string $queryName, string $queryCollectionPath, @@ -280,9 +270,7 @@ public function testMissingNamedParametersIgnoreCommentsAndStrings( ]); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testSpecialBindingsNoAscDesc( string $queryName, string $queryCollectionPath, @@ -306,9 +294,7 @@ public function testSpecialBindingsNoAscDesc( self::assertStringContainsString("offset 25", $injectedSql); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testSpecialBindingsAscDesc( string $queryName, string $queryCollectionPath, @@ -326,9 +312,7 @@ public function testSpecialBindingsAscDesc( self::assertStringContainsString("order by `sortColumn` desc", $injectedSql); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testSpecialBindingsInClause( string $queryName, string $queryCollectionPath, @@ -364,9 +348,7 @@ public function testSpecialBindingsInClause( ); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testDynamicBindingsInsertMultiple( string $queryName, string $queryCollectionPath, @@ -404,9 +386,7 @@ public function testDynamicBindingsInsertMultiple( self::assertArrayNotHasKey("__dynamicValueSet", $data); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testDynamicBindingsWhereIn( string $queryName, string $queryCollectionPath, @@ -429,9 +409,7 @@ public function testDynamicBindingsWhereIn( self::assertSame("2020-01-01", $data["startDate"]); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testDynamicBindingsWhereInStrings( string $queryName, string $queryCollectionPath, @@ -453,9 +431,7 @@ public function testDynamicBindingsWhereInStrings( self::assertSame("2020-01-01", $data["startDate"]); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testDynamicBindingsOr( string $queryName, string $queryCollectionPath, @@ -480,9 +456,7 @@ public function testDynamicBindingsOr( self::assertStringContainsString("where ( (`customerId` = 'cust_105' and `productId` = 1) or (`customerId` = 'cust_450' and `productId` = 941) or (`customerId` = 'cust_450' and `productId` = 433) ) limit 10", $injectedSql); } - /** - * @dataProvider \GT\Database\Test\Helper\Helper::queryPathNotExistsProvider() - */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathNotExistsProvider")] public function testPrepareBindingsWithArray( string $queryName, string $queryCollectionPath, @@ -519,7 +493,8 @@ public function testPrepareBindingsWithArray( ); } - /** @dataProvider \GT\Database\Test\Helper\Helper::queryPathExistsProvider() */ + /* */ + #[\PHPUnit\Framework\Attributes\DataProviderExternal(\GT\Database\Test\Helper\Helper::class, "queryPathExistsProvider")] public function testMultipleStatements( string $queryName, string $queryCollectionPath, diff --git a/test/phpunit/Result/ResultSetTest.php b/test/phpunit/Result/ResultSetTest.php index 6838cfb..e7c47a7 100644 --- a/test/phpunit/Result/ResultSetTest.php +++ b/test/phpunit/Result/ResultSetTest.php @@ -178,7 +178,7 @@ public function testAsDateTime() { private function getStatementMock(bool $withMetadata = true):PDOStatement { $statement = $this->createMock(PDOStatement::class); $statement->method("fetch") - ->will(self::returnCallback([$this, "getNextFakeData"])); + ->willReturnCallback([$this, "getNextFakeData"]); $statement->method("execute") ->willReturnCallback([$this, "rewindFakeData"]); if($withMetadata) { diff --git a/test/phpunit/Result/RowTest.php b/test/phpunit/Result/RowTest.php index 306a251..03e15ba 100644 --- a/test/phpunit/Result/RowTest.php +++ b/test/phpunit/Result/RowTest.php @@ -7,7 +7,7 @@ use PHPUnit\Framework\TestCase; class RowTest extends TestCase { - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testFieldAccess(array $data) { $row = new Row($data); @@ -69,7 +69,7 @@ public function testGetFieldList() { ); } - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testIteration(array $data) { $row = new Row($data); @@ -83,7 +83,7 @@ public function testIteration(array $data) { } } - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testGetString(array $data) { $row = new Row($data); foreach($data as $key => $expected) { @@ -93,7 +93,7 @@ public function testGetString(array $data) { } } - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testGetInt(array $data) { $row = new Row($data); $id = $row->getInt("id"); @@ -101,7 +101,7 @@ public function testGetInt(array $data) { self::assertSame((int)$data["id"], $id); } - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testGetFloat(array $data) { $row = new Row($data); $float = $row->getFloat("exampleFloat"); @@ -109,7 +109,7 @@ public function testGetFloat(array $data) { self::assertSame(round($data["exampleFloat"], 4), round($float, 4)); } - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testGetBool(array $data) { $row = new Row($data); $bool = $row->getBool("exampleBool"); @@ -117,7 +117,7 @@ public function testGetBool(array $data) { self::assertSame((bool)$data["exampleBool"], $bool); } - /** @dataProvider data_getTestRow */ + #[\PHPUnit\Framework\Attributes\DataProvider("data_getTestRow")] public function testGetDateTime(array $data) { $row = new Row($data); $dateTime = $row->getDateTime("exampleDateTime");