diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index c89dfccb..ad5c5a56 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -13,7 +13,7 @@ jobs: strategy: fail-fast: false matrix: - php-versions: ['7.0', '7.1', '7.2', '7.3', '7.4'] + php-versions: ['8.2', '8.3'] steps: - uses: actions/checkout@v2 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 38823a09..0890e1a2 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -13,7 +13,7 @@ jobs: strategy: fail-fast: false matrix: - php-versions: ['7.0', '7.1', '7.2', '7.3', '7.4'] + php-versions: ['8.2', '8.3'] steps: - uses: actions/checkout@v2 diff --git a/.php_cs b/.php-cs-fixer.php similarity index 69% rename from .php_cs rename to .php-cs-fixer.php index 1280456e..5fb6a082 100644 --- a/.php_cs +++ b/.php-cs-fixer.php @@ -5,9 +5,9 @@ ->in(__DIR__ . '/tests') ; -return PhpCsFixer\Config::create() - ->setUsingCache(false) - ->setRules([ +$config = new PhpCsFixer\Config(); +$config->setUsingCache(false); +return $config->setRules([ '@PSR2' => true, 'array_syntax' => ['syntax' => 'short'], ]) diff --git a/Makefile b/Makefile index 5d2917df..3b72d89f 100644 --- a/Makefile +++ b/Makefile @@ -6,7 +6,7 @@ fix: php vendor/bin/php-cs-fixer fix --config=.php_cs lint: - php vendor/bin/php-cs-fixer fix --config=.php_cs --dry-run + php vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.php --dry-run php vendor/bin/phpmd src/ text cleancode,codesize,controversial,design,naming,unusedcode php vendor/bin/phpmd tests/ text cleancode,codesize,controversial,design,naming,unusedcode diff --git a/composer.json b/composer.json index 81112ad0..5eaf9575 100644 --- a/composer.json +++ b/composer.json @@ -3,15 +3,15 @@ "description": "PHP binding for v4 of the Cloudflare Client API.", "type": "library", "require": { - "guzzlehttp/guzzle": "^7.0.1", - "php": ">=7.2.5", + "guzzlehttp/guzzle": "^7.3.0", + "php": ">=8.2", "psr/http-message": "~1.0", "ext-json": "*" }, "require-dev": { - "phpunit/phpunit": "^5.7", + "phpunit/phpunit": "^9.1.2", "phpmd/phpmd" : "@stable", - "friendsofphp/php-cs-fixer": "^2.6" + "friendsofphp/php-cs-fixer": "^3.13" }, "license": "BSD-3-Clause", "authors": [ diff --git a/composer.lock b/composer.lock index 633000df..33341050 100644 --- a/composer.lock +++ b/composer.lock @@ -4,182 +4,300 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "dfd011c55474ffaab84b7a0a6d164049", + "content-hash": "d156286686d1b25bdc513fedeb5caf40", "packages": [ { "name": "guzzlehttp/guzzle", - "version": "6.5.2", + "version": "7.8.1", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "43ece0e75098b7ecd8d13918293029e555a50f82" + "reference": "41042bc7ab002487b876a0683fc8dce04ddce104" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/43ece0e75098b7ecd8d13918293029e555a50f82", - "reference": "43ece0e75098b7ecd8d13918293029e555a50f82", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/41042bc7ab002487b876a0683fc8dce04ddce104", + "reference": "41042bc7ab002487b876a0683fc8dce04ddce104", "shasum": "" }, "require": { "ext-json": "*", - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.6.1", - "php": ">=5.5" + "guzzlehttp/promises": "^1.5.3 || ^2.0.1", + "guzzlehttp/psr7": "^1.9.1 || ^2.5.1", + "php": "^7.2.5 || ^8.0", + "psr/http-client": "^1.0", + "symfony/deprecation-contracts": "^2.2 || ^3.0" + }, + "provide": { + "psr/http-client-implementation": "1.0" }, "require-dev": { + "bamarni/composer-bin-plugin": "^1.8.2", "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr/log": "^1.1" + "php-http/client-integration-tests": "dev-master#2c025848417c1135031fdf9c728ee53d0a7ceaee as 3.0.999", + "php-http/message-factory": "^1.1", + "phpunit/phpunit": "^8.5.36 || ^9.6.15", + "psr/log": "^1.1 || ^2.0 || ^3.0" }, "suggest": { + "ext-curl": "Required for CURL handler support", "ext-intl": "Required for Internationalized Domain Name (IDN) support", "psr/log": "Required for using the Log middleware" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "6.5-dev" + "bamarni-bin": { + "bin-links": true, + "forward-command": false } }, "autoload": { - "psr-4": { - "GuzzleHttp\\": "src/" - }, "files": [ "src/functions_include.php" - ] + ], + "psr-4": { + "GuzzleHttp\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, { "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Jeremy Lindblom", + "email": "jeremeamia@gmail.com", + "homepage": "https://github.com/jeremeamia" + }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" } ], "description": "Guzzle is a PHP HTTP client library", - "homepage": "http://guzzlephp.org/", "keywords": [ "client", "curl", "framework", "http", "http client", + "psr-18", + "psr-7", "rest", "web service" ], - "time": "2019-12-23T11:57:10+00:00" + "support": { + "issues": "https://github.com/guzzle/guzzle/issues", + "source": "https://github.com/guzzle/guzzle/tree/7.8.1" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/guzzle", + "type": "tidelift" + } + ], + "time": "2023-12-03T20:35:24+00:00" }, { "name": "guzzlehttp/promises", - "version": "v1.3.1", + "version": "2.0.2", "source": { "type": "git", "url": "https://github.com/guzzle/promises.git", - "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646" + "reference": "bbff78d96034045e58e13dedd6ad91b5d1253223" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/promises/zipball/a59da6cf61d80060647ff4d3eb2c03a2bc694646", - "reference": "a59da6cf61d80060647ff4d3eb2c03a2bc694646", + "url": "https://api.github.com/repos/guzzle/promises/zipball/bbff78d96034045e58e13dedd6ad91b5d1253223", + "reference": "bbff78d96034045e58e13dedd6ad91b5d1253223", "shasum": "" }, "require": { - "php": ">=5.5.0" + "php": "^7.2.5 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "^4.0" + "bamarni/composer-bin-plugin": "^1.8.2", + "phpunit/phpunit": "^8.5.36 || ^9.6.15" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.4-dev" + "bamarni-bin": { + "bin-links": true, + "forward-command": false } }, "autoload": { "psr-4": { "GuzzleHttp\\Promise\\": "src/" - }, - "files": [ - "src/functions_include.php" - ] + } }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, { "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", + "homepage": "https://github.com/Tobion" } ], "description": "Guzzle promises library", "keywords": [ "promise" ], - "time": "2016-12-20T10:07:11+00:00" + "support": { + "issues": "https://github.com/guzzle/promises/issues", + "source": "https://github.com/guzzle/promises/tree/2.0.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/promises", + "type": "tidelift" + } + ], + "time": "2023-12-03T20:19:20+00:00" }, { "name": "guzzlehttp/psr7", - "version": "1.6.1", + "version": "2.6.2", "source": { "type": "git", "url": "https://github.com/guzzle/psr7.git", - "reference": "239400de7a173fe9901b9ac7c06497751f00727a" + "reference": "45b30f99ac27b5ca93cb4831afe16285f57b8221" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/psr7/zipball/239400de7a173fe9901b9ac7c06497751f00727a", - "reference": "239400de7a173fe9901b9ac7c06497751f00727a", + "url": "https://api.github.com/repos/guzzle/psr7/zipball/45b30f99ac27b5ca93cb4831afe16285f57b8221", + "reference": "45b30f99ac27b5ca93cb4831afe16285f57b8221", "shasum": "" }, "require": { - "php": ">=5.4.0", - "psr/http-message": "~1.0", - "ralouphie/getallheaders": "^2.0.5 || ^3.0.0" + "php": "^7.2.5 || ^8.0", + "psr/http-factory": "^1.0", + "psr/http-message": "^1.1 || ^2.0", + "ralouphie/getallheaders": "^3.0" }, "provide": { + "psr/http-factory-implementation": "1.0", "psr/http-message-implementation": "1.0" }, "require-dev": { - "ext-zlib": "*", - "phpunit/phpunit": "~4.8.36 || ^5.7.27 || ^6.5.8" + "bamarni/composer-bin-plugin": "^1.8.2", + "http-interop/http-factory-tests": "^0.9", + "phpunit/phpunit": "^8.5.36 || ^9.6.15" }, "suggest": { - "zendframework/zend-httphandlerrunner": "Emit PSR-7 responses" + "laminas/laminas-httphandlerrunner": "Emit PSR-7 responses" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.6-dev" + "bamarni-bin": { + "bin-links": true, + "forward-command": false } }, "autoload": { "psr-4": { "GuzzleHttp\\Psr7\\": "src/" - }, - "files": [ - "src/functions_include.php" - ] + } }, "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "authors": [ + { + "name": "Graham Campbell", + "email": "hello@gjcampbell.co.uk", + "homepage": "https://github.com/GrahamCampbell" + }, { "name": "Michael Dowling", "email": "mtdowling@gmail.com", "homepage": "https://github.com/mtdowling" }, + { + "name": "George Mponos", + "email": "gmponos@gmail.com", + "homepage": "https://github.com/gmponos" + }, + { + "name": "Tobias Nyholm", + "email": "tobias.nyholm@gmail.com", + "homepage": "https://github.com/Nyholm" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://github.com/sagikazarmark" + }, { "name": "Tobias Schultze", + "email": "webmaster@tubo-world.de", "homepage": "https://github.com/Tobion" + }, + { + "name": "Márk Sági-Kazár", + "email": "mark.sagikazar@gmail.com", + "homepage": "https://sagikazarmark.hu" } ], "description": "PSR-7 message implementation that also provides common utility methods", @@ -193,24 +311,43 @@ "uri", "url" ], - "time": "2019-07-01T23:21:34+00:00" + "support": { + "issues": "https://github.com/guzzle/psr7/issues", + "source": "https://github.com/guzzle/psr7/tree/2.6.2" + }, + "funding": [ + { + "url": "https://github.com/GrahamCampbell", + "type": "github" + }, + { + "url": "https://github.com/Nyholm", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/guzzlehttp/psr7", + "type": "tidelift" + } + ], + "time": "2023-12-03T20:05:35+00:00" }, { - "name": "psr/http-message", - "version": "1.0.1", + "name": "psr/http-client", + "version": "1.0.3", "source": { "type": "git", - "url": "https://github.com/php-fig/http-message.git", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + "url": "https://github.com/php-fig/http-client.git", + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "url": "https://api.github.com/repos/php-fig/http-client/zipball/bb5906edc1c324c9a05aa0873d40117941e5fa90", + "reference": "bb5906edc1c324c9a05aa0873d40117941e5fa90", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "^7.0 || ^8.0", + "psr/http-message": "^1.0 || ^2.0" }, "type": "library", "extra": { @@ -220,7 +357,7 @@ }, "autoload": { "psr-4": { - "Psr\\Http\\Message\\": "src/" + "Psr\\Http\\Client\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -230,47 +367,50 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], - "description": "Common interface for HTTP messages", - "homepage": "https://github.com/php-fig/http-message", + "description": "Common interface for HTTP clients", + "homepage": "https://github.com/php-fig/http-client", "keywords": [ "http", - "http-message", + "http-client", "psr", - "psr-7", - "request", - "response" + "psr-18" ], - "time": "2016-08-06T14:39:51+00:00" + "support": { + "source": "https://github.com/php-fig/http-client" + }, + "time": "2023-09-23T14:17:50+00:00" }, { - "name": "ralouphie/getallheaders", - "version": "3.0.3", + "name": "psr/http-factory", + "version": "1.0.2", "source": { "type": "git", - "url": "https://github.com/ralouphie/getallheaders.git", - "reference": "120b605dfeb996808c31b6477290a714d356e822" + "url": "https://github.com/php-fig/http-factory.git", + "reference": "e616d01114759c4c489f93b099585439f795fe35" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", - "reference": "120b605dfeb996808c31b6477290a714d356e822", + "url": "https://api.github.com/repos/php-fig/http-factory/zipball/e616d01114759c4c489f93b099585439f795fe35", + "reference": "e616d01114759c4c489f93b099585439f795fe35", "shasum": "" }, "require": { - "php": ">=5.6" - }, - "require-dev": { - "php-coveralls/php-coveralls": "^2.1", - "phpunit/phpunit": "^5 || ^6.5" + "php": ">=7.0.0", + "psr/http-message": "^1.0 || ^2.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } + }, "autoload": { - "files": [ - "src/getallheaders.php" - ] + "psr-4": { + "Psr\\Http\\Message\\": "src/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -278,44 +418,52 @@ ], "authors": [ { - "name": "Ralph Khattar", - "email": "ralph.khattar@gmail.com" + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" } ], - "description": "A polyfill for getallheaders.", - "time": "2019-03-08T08:55:37+00:00" - } - ], - "packages-dev": [ + "description": "Common interfaces for PSR-7 HTTP message factories", + "keywords": [ + "factory", + "http", + "message", + "psr", + "psr-17", + "psr-7", + "request", + "response" + ], + "support": { + "source": "https://github.com/php-fig/http-factory/tree/1.0.2" + }, + "time": "2023-04-10T20:10:41+00:00" + }, { - "name": "composer/semver", - "version": "1.5.1", + "name": "psr/http-message", + "version": "1.1", "source": { "type": "git", - "url": "https://github.com/composer/semver.git", - "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de" + "url": "https://github.com/php-fig/http-message.git", + "reference": "cb6ce4845ce34a8ad9e68117c10ee90a29919eba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/c6bea70230ef4dd483e6bbcab6005f682ed3a8de", - "reference": "c6bea70230ef4dd483e6bbcab6005f682ed3a8de", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/cb6ce4845ce34a8ad9e68117c10ee90a29919eba", + "reference": "cb6ce4845ce34a8ad9e68117c10ee90a29919eba", "shasum": "" }, "require": { - "php": "^5.3.2 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.5 || ^5.0.5" + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.x-dev" + "dev-master": "1.1.x-dev" } }, "autoload": { "psr-4": { - "Composer\\Semver\\": "src" + "Psr\\Http\\Message\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -324,56 +472,51 @@ ], "authors": [ { - "name": "Nils Adermann", - "email": "naderman@naderman.de", - "homepage": "http://www.naderman.de" - }, - { - "name": "Jordi Boggiano", - "email": "j.boggiano@seld.be", - "homepage": "http://seld.be" - }, - { - "name": "Rob Bast", - "email": "rob.bast@gmail.com", - "homepage": "http://robbast.nl" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "Semver library that offers utilities, version constraint parsing and validation.", + "description": "Common interface for HTTP messages", + "homepage": "https://github.com/php-fig/http-message", "keywords": [ - "semantic", - "semver", - "validation", - "versioning" + "http", + "http-message", + "psr", + "psr-7", + "request", + "response" ], - "time": "2020-01-13T12:06:48+00:00" + "support": { + "source": "https://github.com/php-fig/http-message/tree/1.1" + }, + "time": "2023-04-04T09:50:52+00:00" }, { - "name": "composer/xdebug-handler", - "version": "1.4.1", + "name": "ralouphie/getallheaders", + "version": "3.0.3", "source": { "type": "git", - "url": "https://github.com/composer/xdebug-handler.git", - "reference": "1ab9842d69e64fb3a01be6b656501032d1b78cb7" + "url": "https://github.com/ralouphie/getallheaders.git", + "reference": "120b605dfeb996808c31b6477290a714d356e822" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/1ab9842d69e64fb3a01be6b656501032d1b78cb7", - "reference": "1ab9842d69e64fb3a01be6b656501032d1b78cb7", + "url": "https://api.github.com/repos/ralouphie/getallheaders/zipball/120b605dfeb996808c31b6477290a714d356e822", + "reference": "120b605dfeb996808c31b6477290a714d356e822", "shasum": "" }, "require": { - "php": "^5.3.2 || ^7.0 || ^8.0", - "psr/log": "^1.0" + "php": ">=5.6" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8" + "php-coveralls/php-coveralls": "^2.1", + "phpunit/phpunit": "^5 || ^6.5" }, "type": "library", "autoload": { - "psr-4": { - "Composer\\XdebugHandler\\": "src" - } + "files": [ + "src/getallheaders.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -381,49 +524,48 @@ ], "authors": [ { - "name": "John Stevenson", - "email": "john-stevenson@blueyonder.co.uk" + "name": "Ralph Khattar", + "email": "ralph.khattar@gmail.com" } ], - "description": "Restarts a process without Xdebug.", - "keywords": [ - "Xdebug", - "performance" - ], - "time": "2020-03-01T12:26:26+00:00" + "description": "A polyfill for getallheaders.", + "support": { + "issues": "https://github.com/ralouphie/getallheaders/issues", + "source": "https://github.com/ralouphie/getallheaders/tree/develop" + }, + "time": "2019-03-08T08:55:37+00:00" }, { - "name": "doctrine/annotations", - "version": "v1.4.0", + "name": "symfony/deprecation-contracts", + "version": "v3.4.0", "source": { "type": "git", - "url": "https://github.com/doctrine/annotations.git", - "reference": "54cacc9b81758b14e3ce750f205a393d52339e97" + "url": "https://github.com/symfony/deprecation-contracts.git", + "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/54cacc9b81758b14e3ce750f205a393d52339e97", - "reference": "54cacc9b81758b14e3ce750f205a393d52339e97", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/7c3aff79d10325257a001fcf92d991f24fc967cf", + "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf", "shasum": "" }, "require": { - "doctrine/lexer": "1.*", - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "doctrine/cache": "1.*", - "phpunit/phpunit": "^5.7" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-main": "3.4-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { - "psr-4": { - "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations" - } + "files": [ + "function.php" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -431,68 +573,68 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "A generic function and convention to trigger deprecation notices", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.4.0" + }, + "funding": [ { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" + "url": "https://symfony.com/sponsor", + "type": "custom" }, { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" + "url": "https://github.com/fabpot", + "type": "github" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" } ], - "description": "Docblock Annotations Parser", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "docblock", - "parser" - ], - "time": "2017-02-24T16:22:25+00:00" - }, + "time": "2023-05-23T14:45:45+00:00" + } + ], + "packages-dev": [ { - "name": "doctrine/instantiator", - "version": "1.0.5", + "name": "composer/pcre", + "version": "3.1.3", "source": { "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d" + "url": "https://github.com/composer/pcre.git", + "reference": "5b16e25a5355f1f3afdfc2f954a0a80aec4826a8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/8e884e78f9f0eb1329e445619e04456e64d8051d", - "reference": "8e884e78f9f0eb1329e445619e04456e64d8051d", + "url": "https://api.github.com/repos/composer/pcre/zipball/5b16e25a5355f1f3afdfc2f954a0a80aec4826a8", + "reference": "5b16e25a5355f1f3afdfc2f954a0a80aec4826a8", "shasum": "" }, "require": { - "php": ">=5.3,<8.0-DEV" + "php": "^7.4 || ^8.0" }, "require-dev": { - "athletic/athletic": "~0.1.8", - "ext-pdo": "*", - "ext-phar": "*", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "~2.0" + "phpstan/phpstan": "^1.3", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { "psr-4": { - "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" + "Composer\\Pcre\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -501,48 +643,68 @@ ], "authors": [ { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "homepage": "http://ocramius.github.com/" + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" } ], - "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", - "homepage": "https://github.com/doctrine/instantiator", + "description": "PCRE wrapping library that offers type-safe preg_* replacements.", "keywords": [ - "constructor", - "instantiate" + "PCRE", + "preg", + "regex", + "regular expression" + ], + "support": { + "issues": "https://github.com/composer/pcre/issues", + "source": "https://github.com/composer/pcre/tree/3.1.3" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } ], - "time": "2015-06-14T21:17:01+00:00" + "time": "2024-03-19T10:26:25+00:00" }, { - "name": "doctrine/lexer", - "version": "1.0.2", + "name": "composer/semver", + "version": "3.4.0", "source": { "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "1febd6c3ef84253d7c815bed85fc622ad207a9f8" + "url": "https://github.com/composer/semver.git", + "reference": "35e8d0af4486141bc745f23a29cc2091eb624a32" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/1febd6c3ef84253d7c815bed85fc622ad207a9f8", - "reference": "1febd6c3ef84253d7c815bed85fc622ad207a9f8", + "url": "https://api.github.com/repos/composer/semver/zipball/35e8d0af4486141bc745f23a29cc2091eb624a32", + "reference": "35e8d0af4486141bc745f23a29cc2091eb624a32", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": "^5.3.2 || ^7.0 || ^8.0" }, "require-dev": { - "phpunit/phpunit": "^4.5" + "phpstan/phpstan": "^1.4", + "symfony/phpunit-bridge": "^4.2 || ^5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { "psr-4": { - "Doctrine\\Common\\Lexer\\": "lib/Doctrine/Common/Lexer" + "Composer\\Semver\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -551,80 +713,235 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" + "name": "Nils Adermann", + "email": "naderman@naderman.de", + "homepage": "http://www.naderman.de" }, { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" }, { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } + "name": "Rob Bast", + "email": "rob.bast@gmail.com", + "homepage": "http://robbast.nl" + } ], - "description": "PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.", - "homepage": "https://www.doctrine-project.org/projects/lexer.html", + "description": "Semver library that offers utilities, version constraint parsing and validation.", "keywords": [ - "annotations", - "docblock", - "lexer", - "parser", - "php" + "semantic", + "semver", + "validation", + "versioning" + ], + "support": { + "irc": "ircs://irc.libera.chat:6697/composer", + "issues": "https://github.com/composer/semver/issues", + "source": "https://github.com/composer/semver/tree/3.4.0" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2023-08-31T09:50:34+00:00" + }, + { + "name": "composer/xdebug-handler", + "version": "3.0.4", + "source": { + "type": "git", + "url": "https://github.com/composer/xdebug-handler.git", + "reference": "4f988f8fdf580d53bdb2d1278fe93d1ed5462255" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/4f988f8fdf580d53bdb2d1278fe93d1ed5462255", + "reference": "4f988f8fdf580d53bdb2d1278fe93d1ed5462255", + "shasum": "" + }, + "require": { + "composer/pcre": "^1 || ^2 || ^3", + "php": "^7.2.5 || ^8.0", + "psr/log": "^1 || ^2 || ^3" + }, + "require-dev": { + "phpstan/phpstan": "^1.0", + "phpstan/phpstan-strict-rules": "^1.1", + "phpunit/phpunit": "^8.5 || ^9.6 || ^10.5" + }, + "type": "library", + "autoload": { + "psr-4": { + "Composer\\XdebugHandler\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "John Stevenson", + "email": "john-stevenson@blueyonder.co.uk" + } + ], + "description": "Restarts a process without Xdebug.", + "keywords": [ + "Xdebug", + "performance" + ], + "support": { + "irc": "ircs://irc.libera.chat:6697/composer", + "issues": "https://github.com/composer/xdebug-handler/issues", + "source": "https://github.com/composer/xdebug-handler/tree/3.0.4" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2024-03-26T18:29:49+00:00" + }, + { + "name": "doctrine/instantiator", + "version": "2.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/instantiator.git", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "shasum": "" + }, + "require": { + "php": "^8.1" + }, + "require-dev": { + "doctrine/coding-standard": "^11", + "ext-pdo": "*", + "ext-phar": "*", + "phpbench/phpbench": "^1.2", + "phpstan/phpstan": "^1.9.4", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5.27", + "vimeo/psalm": "^5.4" + }, + "type": "library", + "autoload": { + "psr-4": { + "Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Marco Pivetta", + "email": "ocramius@gmail.com", + "homepage": "https://ocramius.github.io/" + } + ], + "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", + "homepage": "https://www.doctrine-project.org/projects/instantiator.html", + "keywords": [ + "constructor", + "instantiate" + ], + "support": { + "issues": "https://github.com/doctrine/instantiator/issues", + "source": "https://github.com/doctrine/instantiator/tree/2.0.0" + }, + "funding": [ + { + "url": "https://www.doctrine-project.org/sponsorship.html", + "type": "custom" + }, + { + "url": "https://www.patreon.com/phpdoctrine", + "type": "patreon" + }, + { + "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", + "type": "tidelift" + } ], - "time": "2019-06-08T11:03:04+00:00" + "time": "2022-12-30T00:23:10+00:00" }, { "name": "friendsofphp/php-cs-fixer", - "version": "v2.16.1", + "version": "v3.53.0", "source": { "type": "git", - "url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git", - "reference": "c8afb599858876e95e8ebfcd97812d383fa23f02" + "url": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer.git", + "reference": "69a19093a9ded8d1baac62ed6c009b8bc148d008" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/c8afb599858876e95e8ebfcd97812d383fa23f02", - "reference": "c8afb599858876e95e8ebfcd97812d383fa23f02", + "url": "https://api.github.com/repos/PHP-CS-Fixer/PHP-CS-Fixer/zipball/69a19093a9ded8d1baac62ed6c009b8bc148d008", + "reference": "69a19093a9ded8d1baac62ed6c009b8bc148d008", "shasum": "" }, "require": { - "composer/semver": "^1.4", - "composer/xdebug-handler": "^1.2", - "doctrine/annotations": "^1.2", + "composer/semver": "^3.4", + "composer/xdebug-handler": "^3.0.3", + "ext-filter": "*", "ext-json": "*", "ext-tokenizer": "*", - "php": "^5.6 || ^7.0", - "php-cs-fixer/diff": "^1.3", - "symfony/console": "^3.4.17 || ^4.1.6 || ^5.0", - "symfony/event-dispatcher": "^3.0 || ^4.0 || ^5.0", - "symfony/filesystem": "^3.0 || ^4.0 || ^5.0", - "symfony/finder": "^3.0 || ^4.0 || ^5.0", - "symfony/options-resolver": "^3.0 || ^4.0 || ^5.0", - "symfony/polyfill-php70": "^1.0", - "symfony/polyfill-php72": "^1.4", - "symfony/process": "^3.0 || ^4.0 || ^5.0", - "symfony/stopwatch": "^3.0 || ^4.0 || ^5.0" + "php": "^7.4 || ^8.0", + "sebastian/diff": "^4.0 || ^5.0 || ^6.0", + "symfony/console": "^5.4 || ^6.0 || ^7.0", + "symfony/event-dispatcher": "^5.4 || ^6.0 || ^7.0", + "symfony/filesystem": "^5.4 || ^6.0 || ^7.0", + "symfony/finder": "^5.4 || ^6.0 || ^7.0", + "symfony/options-resolver": "^5.4 || ^6.0 || ^7.0", + "symfony/polyfill-mbstring": "^1.28", + "symfony/polyfill-php80": "^1.28", + "symfony/polyfill-php81": "^1.28", + "symfony/process": "^5.4 || ^6.0 || ^7.0", + "symfony/stopwatch": "^5.4 || ^6.0 || ^7.0" }, "require-dev": { - "johnkary/phpunit-speedtrap": "^1.1 || ^2.0 || ^3.0", - "justinrainbow/json-schema": "^5.0", - "keradus/cli-executor": "^1.2", - "mikey179/vfsstream": "^1.6", - "php-coveralls/php-coveralls": "^2.1", - "php-cs-fixer/accessible-object": "^1.0", - "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.1", - "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.1", - "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.1", - "phpunitgoodpractices/traits": "^1.8", - "symfony/phpunit-bridge": "^4.3 || ^5.0", - "symfony/yaml": "^3.0 || ^4.0 || ^5.0" + "facile-it/paraunit": "^1.3 || ^2.0", + "infection/infection": "^0.27.11", + "justinrainbow/json-schema": "^5.2", + "keradus/cli-executor": "^2.1", + "mikey179/vfsstream": "^1.6.11", + "php-coveralls/php-coveralls": "^2.7", + "php-cs-fixer/accessible-object": "^1.1", + "php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.4", + "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.4", + "phpunit/phpunit": "^9.6 || ^10.5.5 || ^11.0.2", + "symfony/var-dumper": "^5.4 || ^6.0 || ^7.0", + "symfony/yaml": "^5.4 || ^6.0 || ^7.0" }, "suggest": { - "ext-mbstring": "For handling non-UTF8 characters in cache signature.", - "php-cs-fixer/phpunit-constraint-isidenticalstring": "For IsIdenticalString constraint.", - "php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "For XmlMatchesXsd constraint.", - "symfony/polyfill-mbstring": "When enabling `ext-mbstring` is not possible." + "ext-dom": "For handling output formats in XML", + "ext-mbstring": "For handling non-UTF8 characters." }, "bin": [ "php-cs-fixer" @@ -633,18 +950,7 @@ "autoload": { "psr-4": { "PhpCsFixer\\": "src/" - }, - "classmap": [ - "tests/Test/AbstractFixerTestCase.php", - "tests/Test/AbstractIntegrationCaseFactory.php", - "tests/Test/AbstractIntegrationTestCase.php", - "tests/Test/Assert/AssertTokensTrait.php", - "tests/Test/IntegrationCase.php", - "tests/Test/IntegrationCaseFactory.php", - "tests/Test/IntegrationCaseFactoryInterface.php", - "tests/Test/InternalIntegrationCaseFactory.php", - "tests/TestCase.php" - ] + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -661,38 +967,58 @@ } ], "description": "A tool to automatically fix PHP code style", - "time": "2019-11-25T22:10:32+00:00" + "keywords": [ + "Static code analysis", + "fixer", + "standards", + "static analysis" + ], + "support": { + "issues": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/issues", + "source": "https://github.com/PHP-CS-Fixer/PHP-CS-Fixer/tree/v3.53.0" + }, + "funding": [ + { + "url": "https://github.com/keradus", + "type": "github" + } + ], + "time": "2024-04-08T15:03:00+00:00" }, { "name": "myclabs/deep-copy", - "version": "1.7.0", + "version": "1.11.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "3b8a3a99ba1f6a3952ac2747d989303cbd6b7a3e" + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3b8a3a99ba1f6a3952ac2747d989303cbd6b7a3e", - "reference": "3b8a3a99ba1f6a3952ac2747d989303cbd6b7a3e", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": "^7.1 || ^8.0" + }, + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3,<3.2.2" }, "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^4.1" + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" }, "type": "library", "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - }, "files": [ "src/DeepCopy/deep_copy.php" - ] + ], + "psr-4": { + "DeepCopy\\": "src/DeepCopy/" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -706,77 +1032,100 @@ "object", "object graph" ], - "time": "2017-10-19T19:58:43+00:00" + "support": { + "issues": "https://github.com/myclabs/DeepCopy/issues", + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.1" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/myclabs/deep-copy", + "type": "tidelift" + } + ], + "time": "2023-03-08T13:26:56+00:00" }, { - "name": "paragonie/random_compat", - "version": "v9.99.99", + "name": "nikic/php-parser", + "version": "v5.0.2", "source": { "type": "git", - "url": "https://github.com/paragonie/random_compat.git", - "reference": "84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95" + "url": "https://github.com/nikic/PHP-Parser.git", + "reference": "139676794dc1e9231bf7bcd123cfc0c99182cb13" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95", - "reference": "84b4dfb120c6f9b4ff7b3685f9b8f1aa365a0c95", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/139676794dc1e9231bf7bcd123cfc0c99182cb13", + "reference": "139676794dc1e9231bf7bcd123cfc0c99182cb13", "shasum": "" }, "require": { - "php": "^7" + "ext-ctype": "*", + "ext-json": "*", + "ext-tokenizer": "*", + "php": ">=7.4" }, "require-dev": { - "phpunit/phpunit": "4.*|5.*", - "vimeo/psalm": "^1" - }, - "suggest": { - "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0" }, + "bin": [ + "bin/php-parse" + ], "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.0-dev" + } + }, + "autoload": { + "psr-4": { + "PhpParser\\": "lib/PhpParser" + } + }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Paragon Initiative Enterprises", - "email": "security@paragonie.com", - "homepage": "https://paragonie.com" + "name": "Nikita Popov" } ], - "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "description": "A PHP parser written in PHP", "keywords": [ - "csprng", - "polyfill", - "pseudorandom", - "random" + "parser", + "php" ], - "time": "2018-07-02T15:55:56+00:00" + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v5.0.2" + }, + "time": "2024-03-05T20:51:40+00:00" }, { "name": "pdepend/pdepend", - "version": "2.7.1", + "version": "2.16.2", "source": { "type": "git", "url": "https://github.com/pdepend/pdepend.git", - "reference": "daba1cf0a6edaf172fa02a17807ae29f4c1c7471" + "reference": "f942b208dc2a0868454d01b29f0c75bbcfc6ed58" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/pdepend/pdepend/zipball/daba1cf0a6edaf172fa02a17807ae29f4c1c7471", - "reference": "daba1cf0a6edaf172fa02a17807ae29f4c1c7471", + "url": "https://api.github.com/repos/pdepend/pdepend/zipball/f942b208dc2a0868454d01b29f0c75bbcfc6ed58", + "reference": "f942b208dc2a0868454d01b29f0c75bbcfc6ed58", "shasum": "" }, "require": { "php": ">=5.3.7", - "symfony/config": "^2.3.0|^3|^4|^5", - "symfony/dependency-injection": "^2.3.0|^3|^4|^5", - "symfony/filesystem": "^2.3.0|^3|^4|^5" + "symfony/config": "^2.3.0|^3|^4|^5|^6.0|^7.0", + "symfony/dependency-injection": "^2.3.0|^3|^4|^5|^6.0|^7.0", + "symfony/filesystem": "^2.3.0|^3|^4|^5|^6.0|^7.0", + "symfony/polyfill-mbstring": "^1.19" }, "require-dev": { - "easy-doc/easy-doc": "0.0.0 || ^1.2.3", + "easy-doc/easy-doc": "0.0.0|^1.2.3", "gregwar/rst": "^1.0", - "phpunit/phpunit": "^4.8.35|^5.7", "squizlabs/php_codesniffer": "^2.0.0" }, "bin": [ @@ -798,30 +1147,52 @@ "BSD-3-Clause" ], "description": "Official version of pdepend to be handled with Composer", - "time": "2020-02-08T12:06:13+00:00" + "keywords": [ + "PHP Depend", + "PHP_Depend", + "dev", + "pdepend" + ], + "support": { + "issues": "https://github.com/pdepend/pdepend/issues", + "source": "https://github.com/pdepend/pdepend/tree/2.16.2" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/pdepend/pdepend", + "type": "tidelift" + } + ], + "time": "2023-12-17T18:09:59+00:00" }, { - "name": "php-cs-fixer/diff", - "version": "v1.3.0", + "name": "phar-io/manifest", + "version": "2.0.4", "source": { "type": "git", - "url": "https://github.com/PHP-CS-Fixer/diff.git", - "reference": "78bb099e9c16361126c86ce82ec4405ebab8e756" + "url": "https://github.com/phar-io/manifest.git", + "reference": "54750ef60c58e43759730615a392c31c80e23176" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/78bb099e9c16361126c86ce82ec4405ebab8e756", - "reference": "78bb099e9c16361126c86ce82ec4405ebab8e756", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176", + "reference": "54750ef60c58e43759730615a392c31c80e23176", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7.23 || ^6.4.3", - "symfony/process": "^3.3" + "ext-dom": "*", + "ext-libxml": "*", + "ext-phar": "*", + "ext-xmlwriter": "*", + "phar-io/version": "^3.0.1", + "php": "^7.2 || ^8.0" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -833,161 +1204,616 @@ ], "authors": [ { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" }, { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" }, { - "name": "SpacePossum" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" } ], - "description": "sebastian/diff v2 backport support for PHP5.6", - "homepage": "https://github.com/PHP-CS-Fixer", - "keywords": [ - "diff" + "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", + "support": { + "issues": "https://github.com/phar-io/manifest/issues", + "source": "https://github.com/phar-io/manifest/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } ], - "time": "2018-02-15T16:58:55+00:00" + "time": "2024-03-03T12:33:53+00:00" }, { - "name": "phpdocumentor/reflection-common", - "version": "1.0.1", + "name": "phar-io/version", + "version": "3.2.1", "source": { "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6" + "url": "https://github.com/phar-io/version.git", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", - "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", "shasum": "" }, "require": { - "php": ">=5.5" - }, - "require-dev": { - "phpunit/phpunit": "^4.6" + "php": "^7.2 || ^8.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src" - ] - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Jaap van Otterdijk", - "email": "opensource@ijaap.nl" + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + }, + { + "name": "Sebastian Heuer", + "email": "sebastian@phpeople.de", + "role": "Developer" + }, + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "Developer" } ], - "description": "Common reflection classes used by phpdocumentor to reflect the code structure", - "homepage": "http://www.phpdoc.org", - "keywords": [ - "FQSEN", - "phpDocumentor", - "phpdoc", - "reflection", - "static analysis" - ], - "time": "2017-09-11T18:02:19+00:00" + "description": "Library for handling version information and constraints", + "support": { + "issues": "https://github.com/phar-io/version/issues", + "source": "https://github.com/phar-io/version/tree/3.2.1" + }, + "time": "2022-02-21T01:04:05+00:00" }, { - "name": "phpdocumentor/reflection-docblock", - "version": "4.3.4", + "name": "phpmd/phpmd", + "version": "2.15.0", "source": { "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "da3fd972d6bafd628114f7e7e036f45944b62e9c" + "url": "https://github.com/phpmd/phpmd.git", + "reference": "74a1f56e33afad4128b886e334093e98e1b5e7c0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/da3fd972d6bafd628114f7e7e036f45944b62e9c", - "reference": "da3fd972d6bafd628114f7e7e036f45944b62e9c", + "url": "https://api.github.com/repos/phpmd/phpmd/zipball/74a1f56e33afad4128b886e334093e98e1b5e7c0", + "reference": "74a1f56e33afad4128b886e334093e98e1b5e7c0", "shasum": "" }, "require": { - "php": "^7.0", - "phpdocumentor/reflection-common": "^1.0.0 || ^2.0.0", - "phpdocumentor/type-resolver": "~0.4 || ^1.0.0", - "webmozart/assert": "^1.0" + "composer/xdebug-handler": "^1.0 || ^2.0 || ^3.0", + "ext-xml": "*", + "pdepend/pdepend": "^2.16.1", + "php": ">=5.3.9" }, "require-dev": { - "doctrine/instantiator": "^1.0.5", - "mockery/mockery": "^1.0", - "phpdocumentor/type-resolver": "0.4.*", - "phpunit/phpunit": "^6.4" + "easy-doc/easy-doc": "0.0.0 || ^1.3.2", + "ext-json": "*", + "ext-simplexml": "*", + "gregwar/rst": "^1.0", + "mikey179/vfsstream": "^1.6.8", + "squizlabs/php_codesniffer": "^2.9.2 || ^3.7.2" }, + "bin": [ + "src/bin/phpmd" + ], "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.x-dev" - } - }, "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] + "psr-0": { + "PHPMD\\": "src/main/php" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" + "name": "Manuel Pichler", + "email": "github@manuel-pichler.de", + "homepage": "https://github.com/manuelpichler", + "role": "Project Founder" + }, + { + "name": "Marc Würth", + "email": "ravage@bluewin.ch", + "homepage": "https://github.com/ravage84", + "role": "Project Maintainer" + }, + { + "name": "Other contributors", + "homepage": "https://github.com/phpmd/phpmd/graphs/contributors", + "role": "Contributors" + } + ], + "description": "PHPMD is a spin-off project of PHP Depend and aims to be a PHP equivalent of the well known Java tool PMD.", + "homepage": "https://phpmd.org/", + "keywords": [ + "dev", + "mess detection", + "mess detector", + "pdepend", + "phpmd", + "pmd" + ], + "support": { + "irc": "irc://irc.freenode.org/phpmd", + "issues": "https://github.com/phpmd/phpmd/issues", + "source": "https://github.com/phpmd/phpmd/tree/2.15.0" + }, + "funding": [ + { + "url": "https://tidelift.com/funding/github/packagist/phpmd/phpmd", + "type": "tidelift" } ], - "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2019-12-28T18:55:12+00:00" + "time": "2023-12-11T08:22:20+00:00" }, { - "name": "phpdocumentor/type-resolver", - "version": "0.5.1", + "name": "phpunit/php-code-coverage", + "version": "9.2.31", "source": { "type": "git", - "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "cf842904952e64e703800d094cdf34e715a8a3ae" + "url": "https://github.com/sebastianbergmann/php-code-coverage.git", + "reference": "48c34b5d8d983006bd2adc2d0de92963b9155965" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/cf842904952e64e703800d094cdf34e715a8a3ae", - "reference": "cf842904952e64e703800d094cdf34e715a8a3ae", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/48c34b5d8d983006bd2adc2d0de92963b9155965", + "reference": "48c34b5d8d983006bd2adc2d0de92963b9155965", "shasum": "" }, "require": { - "php": "^7.0", - "phpdocumentor/reflection-common": "^1.0" - }, - "require-dev": { - "mockery/mockery": "^1.0", - "phpunit/phpunit": "^6.4" + "ext-dom": "*", + "ext-libxml": "*", + "ext-xmlwriter": "*", + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3", + "phpunit/php-file-iterator": "^3.0.3", + "phpunit/php-text-template": "^2.0.2", + "sebastian/code-unit-reverse-lookup": "^2.0.2", + "sebastian/complexity": "^2.0", + "sebastian/environment": "^5.1.2", + "sebastian/lines-of-code": "^1.0.3", + "sebastian/version": "^3.0.1", + "theseer/tokenizer": "^1.2.0" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcov": "PHP extension that provides line coverage", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "9.2-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": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", + "homepage": "https://github.com/sebastianbergmann/php-code-coverage", + "keywords": [ + "coverage", + "testing", + "xunit" + ], + "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/9.2.31" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:37:42+00:00" + }, + { + "name": "phpunit/php-file-iterator", + "version": "3.0.6", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-file-iterator.git", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.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": "FilterIterator implementation that filters files based on a list of suffixes.", + "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", + "keywords": [ + "filesystem", + "iterator" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2021-12-02T12:48:52+00:00" + }, + { + "name": "phpunit/php-invoker", + "version": "3.1.1", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-invoker.git", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-invoker/zipball/5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "reference": "5a10147d0aaf65b58940a0b72f71c9ac0423cc67", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "ext-pcntl": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-pcntl": "*" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.1-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": "Invoke callables with a timeout", + "homepage": "https://github.com/sebastianbergmann/php-invoker/", + "keywords": [ + "process" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-invoker/issues", + "source": "https://github.com/sebastianbergmann/php-invoker/tree/3.1.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T05:58:55+00:00" + }, + { + "name": "phpunit/php-text-template", + "version": "2.0.4", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-text-template.git", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "reference": "5da5f67fc95621df9ff4c4e5a84d6a8a2acf7c28", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "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": "Simple template engine.", + "homepage": "https://github.com/sebastianbergmann/php-text-template/", + "keywords": [ + "template" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-text-template/issues", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T05:33:50+00:00" + }, + { + "name": "phpunit/php-timer", + "version": "5.0.3", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/php-timer.git", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "reference": "5a63ce20ed1b5bf577850e2c4e87f4aa902afbd2", + "shasum": "" + }, + "require": { + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "5.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": "Utility class for timing", + "homepage": "https://github.com/sebastianbergmann/php-timer/", + "keywords": [ + "timer" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/php-timer/issues", + "source": "https://github.com/sebastianbergmann/php-timer/tree/5.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-10-26T13:16:10+00:00" + }, + { + "name": "phpunit/phpunit", + "version": "9.6.19", + "source": { + "type": "git", + "url": "https://github.com/sebastianbergmann/phpunit.git", + "reference": "a1a54a473501ef4cdeaae4e06891674114d79db8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a1a54a473501ef4cdeaae4e06891674114d79db8", + "reference": "a1a54a473501ef4cdeaae4e06891674114d79db8", + "shasum": "" + }, + "require": { + "doctrine/instantiator": "^1.3.1 || ^2", + "ext-dom": "*", + "ext-json": "*", + "ext-libxml": "*", + "ext-mbstring": "*", + "ext-xml": "*", + "ext-xmlwriter": "*", + "myclabs/deep-copy": "^1.10.1", + "phar-io/manifest": "^2.0.3", + "phar-io/version": "^3.0.2", + "php": ">=7.3", + "phpunit/php-code-coverage": "^9.2.28", + "phpunit/php-file-iterator": "^3.0.5", + "phpunit/php-invoker": "^3.1.1", + "phpunit/php-text-template": "^2.0.3", + "phpunit/php-timer": "^5.0.2", + "sebastian/cli-parser": "^1.0.1", + "sebastian/code-unit": "^1.0.6", + "sebastian/comparator": "^4.0.8", + "sebastian/diff": "^4.0.3", + "sebastian/environment": "^5.1.3", + "sebastian/exporter": "^4.0.5", + "sebastian/global-state": "^5.0.1", + "sebastian/object-enumerator": "^4.0.3", + "sebastian/resource-operations": "^3.0.3", + "sebastian/type": "^3.2", + "sebastian/version": "^3.0.2" + }, + "suggest": { + "ext-soap": "To be able to generate mocks based on WSDL files", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" + }, + "bin": [ + "phpunit" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "9.6-dev" + } + }, + "autoload": { + "files": [ + "src/Framework/Assert/Functions.php" + ], + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de", + "role": "lead" + } + ], + "description": "The PHP Unit Testing framework.", + "homepage": "https://phpunit.de/", + "keywords": [ + "phpunit", + "testing", + "xunit" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/phpunit/issues", + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.19" + }, + "funding": [ + { + "url": "https://phpunit.de/sponsors.html", + "type": "custom" + }, + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", + "type": "tidelift" + } + ], + "time": "2024-04-05T04:35:58+00:00" + }, + { + "name": "psr/container", + "version": "2.0.2", + "source": { + "type": "git", + "url": "https://github.com/php-fig/container.git", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/container/zipball/c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "reference": "c71ecc56dfe541dbd90c5360474fbc405f8d5963", + "shasum": "" + }, + "require": { + "php": ">=7.4.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": "src" + "Psr\\Container\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -996,112 +1822,101 @@ ], "authors": [ { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" } ], - "time": "2017-12-30T13:23:38+00:00" + "description": "Common Container Interface (PHP FIG PSR-11)", + "homepage": "https://github.com/php-fig/container", + "keywords": [ + "PSR-11", + "container", + "container-interface", + "container-interop", + "psr" + ], + "support": { + "issues": "https://github.com/php-fig/container/issues", + "source": "https://github.com/php-fig/container/tree/2.0.2" + }, + "time": "2021-11-05T16:47:00+00:00" }, { - "name": "phpmd/phpmd", - "version": "2.6.0", + "name": "psr/event-dispatcher", + "version": "1.0.0", "source": { "type": "git", - "url": "https://github.com/phpmd/phpmd.git", - "reference": "4e9924b2c157a3eb64395460fcf56b31badc8374" + "url": "https://github.com/php-fig/event-dispatcher.git", + "reference": "dbefd12671e8a14ec7f180cab83036ed26714bb0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpmd/phpmd/zipball/4e9924b2c157a3eb64395460fcf56b31badc8374", - "reference": "4e9924b2c157a3eb64395460fcf56b31badc8374", + "url": "https://api.github.com/repos/php-fig/event-dispatcher/zipball/dbefd12671e8a14ec7f180cab83036ed26714bb0", + "reference": "dbefd12671e8a14ec7f180cab83036ed26714bb0", "shasum": "" }, "require": { - "ext-xml": "*", - "pdepend/pdepend": "^2.5", - "php": ">=5.3.9" + "php": ">=7.2.0" }, - "require-dev": { - "phpunit/phpunit": "^4.0", - "squizlabs/php_codesniffer": "^2.0" + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.0.x-dev" + } }, - "bin": [ - "src/bin/phpmd" - ], - "type": "project", "autoload": { - "psr-0": { - "PHPMD\\": "src/main/php" + "psr-4": { + "Psr\\EventDispatcher\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Manuel Pichler", - "email": "github@manuel-pichler.de", - "homepage": "https://github.com/manuelpichler", - "role": "Project Founder" - }, - { - "name": "Other contributors", - "homepage": "https://github.com/phpmd/phpmd/graphs/contributors", - "role": "Contributors" - }, - { - "name": "Marc Würth", - "email": "ravage@bluewin.ch", - "homepage": "https://github.com/ravage84", - "role": "Project Maintainer" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "PHPMD is a spin-off project of PHP Depend and aims to be a PHP equivalent of the well known Java tool PMD.", - "homepage": "http://phpmd.org/", + "description": "Standard interfaces for event handling.", "keywords": [ - "mess detection", - "mess detector", - "pdepend", - "phpmd", - "pmd" + "events", + "psr", + "psr-14" ], - "time": "2017-01-20T14:41:10+00:00" + "support": { + "issues": "https://github.com/php-fig/event-dispatcher/issues", + "source": "https://github.com/php-fig/event-dispatcher/tree/1.0.0" + }, + "time": "2019-01-08T18:20:26+00:00" }, { - "name": "phpspec/prophecy", - "version": "v1.10.3", + "name": "psr/log", + "version": "3.0.0", "source": { "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "451c3cd1418cf640de218914901e51b064abb093" + "url": "https://github.com/php-fig/log.git", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/451c3cd1418cf640de218914901e51b064abb093", - "reference": "451c3cd1418cf640de218914901e51b064abb093", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.3|^7.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0|^5.0", - "sebastian/comparator": "^1.2.3|^2.0|^3.0|^4.0", - "sebastian/recursion-context": "^1.0|^2.0|^3.0|^4.0" - }, - "require-dev": { - "phpspec/phpspec": "^2.5 || ^3.2", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5 || ^7.1" + "php": ">=8.0.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.10.x-dev" + "dev-master": "3.x-dev" } }, "autoload": { "psr-4": { - "Prophecy\\": "src/Prophecy" + "Psr\\Log\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -1110,63 +1925,46 @@ ], "authors": [ { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" + "name": "PHP-FIG", + "homepage": "https://www.php-fig.org/" } ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", + "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "time": "2020-03-05T15:02:03+00:00" + "log", + "psr", + "psr-3" + ], + "support": { + "source": "https://github.com/php-fig/log/tree/3.0.0" + }, + "time": "2021-07-14T16:46:02+00:00" }, { - "name": "phpunit/php-code-coverage", - "version": "4.0.8", + "name": "sebastian/cli-parser", + "version": "1.0.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "ef7b2f56815df854e66ceaee8ebe9393ae36a40d" + "url": "https://github.com/sebastianbergmann/cli-parser.git", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/ef7b2f56815df854e66ceaee8ebe9393ae36a40d", - "reference": "ef7b2f56815df854e66ceaee8ebe9393ae36a40d", + "url": "https://api.github.com/repos/sebastianbergmann/cli-parser/zipball/2b56bea83a09de3ac06bb18b92f068e60cc6f50b", + "reference": "2b56bea83a09de3ac06bb18b92f068e60cc6f50b", "shasum": "" }, "require": { - "ext-dom": "*", - "ext-xmlwriter": "*", - "php": "^5.6 || ^7.0", - "phpunit/php-file-iterator": "^1.3", - "phpunit/php-text-template": "^1.2", - "phpunit/php-token-stream": "^1.4.2 || ^2.0", - "sebastian/code-unit-reverse-lookup": "^1.0", - "sebastian/environment": "^1.3.2 || ^2.0", - "sebastian/version": "^1.0 || ^2.0" + "php": ">=7.3" }, "require-dev": { - "ext-xdebug": "^2.1.4", - "phpunit/phpunit": "^5.7" - }, - "suggest": { - "ext-xdebug": "^2.5.1" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "4.0.x-dev" + "dev-master": "1.0-dev" } }, "autoload": { @@ -1181,40 +1979,48 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", + "email": "sebastian@phpunit.de", "role": "lead" } ], - "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", - "homepage": "https://github.com/sebastianbergmann/php-code-coverage", - "keywords": [ - "coverage", - "testing", - "xunit" + "description": "Library for parsing CLI options", + "homepage": "https://github.com/sebastianbergmann/cli-parser", + "support": { + "issues": "https://github.com/sebastianbergmann/cli-parser/issues", + "source": "https://github.com/sebastianbergmann/cli-parser/tree/1.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-04-02T07:44:40+00:00" + "time": "2024-03-02T06:27:43+00:00" }, { - "name": "phpunit/php-file-iterator", - "version": "1.4.5", + "name": "sebastian/code-unit", + "version": "1.0.8", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4" + "url": "https://github.com/sebastianbergmann/code-unit.git", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/730b01bc3e867237eaac355e06a36b85dd93a8b4", - "reference": "730b01bc3e867237eaac355e06a36b85dd93a8b4", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit/zipball/1fc9f64c0927627ef78ba436c9b17d967e68e120", + "reference": "1fc9f64c0927627ef78ba436c9b17d967e68e120", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-master": "1.0-dev" } }, "autoload": { @@ -1229,36 +2035,50 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", + "email": "sebastian@phpunit.de", "role": "lead" } ], - "description": "FilterIterator implementation that filters files based on a list of suffixes.", - "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", - "keywords": [ - "filesystem", - "iterator" + "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/1.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-11-27T13:52:08+00:00" + "time": "2020-10-26T13:08:54+00:00" }, { - "name": "phpunit/php-text-template", - "version": "1.2.1", + "name": "sebastian/code-unit-reverse-lookup", + "version": "2.0.3", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" + "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", + "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", + "reference": "ac91f01ccec49fb77bdc6fd1e548bc70f7faa3e5", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" + }, + "require-dev": { + "phpunit/phpunit": "^9.3" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.0-dev" + } + }, "autoload": { "classmap": [ "src/" @@ -1271,41 +2091,49 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "email": "sebastian@phpunit.de" } ], - "description": "Simple template engine.", - "homepage": "https://github.com/sebastianbergmann/php-text-template/", - "keywords": [ - "template" + "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/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2015-06-21T13:50:34+00:00" + "time": "2020-09-28T05:30:19+00:00" }, { - "name": "phpunit/php-timer", - "version": "1.0.9", + "name": "sebastian/comparator", + "version": "4.0.8", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f" + "url": "https://github.com/sebastianbergmann/comparator.git", + "reference": "fa0f136dd2334583309d32b62544682ee972b51a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/3dcf38ca72b158baf0bc245e9184d3fdffa9c46f", - "reference": "3dcf38ca72b158baf0bc245e9184d3fdffa9c46f", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", + "reference": "fa0f136dd2334583309d32b62544682ee972b51a", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0" + "php": ">=7.3", + "sebastian/diff": "^4.0", + "sebastian/exporter": "^4.0" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1320,37 +2148,60 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@2bepublished.at" } ], - "description": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", + "description": "Provides the functionality to compare PHP values for equality", + "homepage": "https://github.com/sebastianbergmann/comparator", "keywords": [ - "timer" + "comparator", + "compare", + "equality" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/comparator/issues", + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-02-26T11:10:40+00:00" + "time": "2022-09-14T12:41:17+00:00" }, { - "name": "phpunit/php-token-stream", - "version": "2.0.2", + "name": "sebastian/complexity", + "version": "2.0.3", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "791198a2c6254db10131eecfe8c06670700904db" + "url": "https://github.com/sebastianbergmann/complexity.git", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/791198a2c6254db10131eecfe8c06670700904db", - "reference": "791198a2c6254db10131eecfe8c06670700904db", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/25f207c40d62b8b7aa32f5ab026c53561964053a", + "reference": "25f207c40d62b8b7aa32f5ab026c53561964053a", "shasum": "" }, "require": { - "ext-tokenizer": "*", - "php": "^7.0" + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^6.2.4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { @@ -1370,71 +2221,49 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" + "description": "Library for calculating the complexity of PHP code units", + "homepage": "https://github.com/sebastianbergmann/complexity", + "support": { + "issues": "https://github.com/sebastianbergmann/complexity/issues", + "source": "https://github.com/sebastianbergmann/complexity/tree/2.0.3" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-11-27T05:48:46+00:00" + "time": "2023-12-22T06:19:30+00:00" }, { - "name": "phpunit/phpunit", - "version": "5.7.27", + "name": "sebastian/diff", + "version": "4.0.6", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "b7803aeca3ccb99ad0a506fa80b64cd6a56bbc0c" + "url": "https://github.com/sebastianbergmann/diff.git", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/b7803aeca3ccb99ad0a506fa80b64cd6a56bbc0c", - "reference": "b7803aeca3ccb99ad0a506fa80b64cd6a56bbc0c", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/ba01945089c3a293b01ba9badc29ad55b106b0bc", + "reference": "ba01945089c3a293b01ba9badc29ad55b106b0bc", "shasum": "" }, "require": { - "ext-dom": "*", - "ext-json": "*", - "ext-libxml": "*", - "ext-mbstring": "*", - "ext-xml": "*", - "myclabs/deep-copy": "~1.3", - "php": "^5.6 || ^7.0", - "phpspec/prophecy": "^1.6.2", - "phpunit/php-code-coverage": "^4.0.4", - "phpunit/php-file-iterator": "~1.4", - "phpunit/php-text-template": "~1.2", - "phpunit/php-timer": "^1.0.6", - "phpunit/phpunit-mock-objects": "^3.2", - "sebastian/comparator": "^1.2.4", - "sebastian/diff": "^1.4.3", - "sebastian/environment": "^1.3.4 || ^2.0", - "sebastian/exporter": "~2.0", - "sebastian/global-state": "^1.1", - "sebastian/object-enumerator": "~2.0", - "sebastian/resource-operations": "~1.0", - "sebastian/version": "^1.0.6|^2.0.1", - "symfony/yaml": "~2.1|~3.0|~4.0" - }, - "conflict": { - "phpdocumentor/reflection-docblock": "3.0.2" + "php": ">=7.3" }, "require-dev": { - "ext-pdo": "*" - }, - "suggest": { - "ext-xdebug": "*", - "phpunit/php-invoker": "~1.1" + "phpunit/phpunit": "^9.3", + "symfony/process": "^4.2 || ^5" }, - "bin": [ - "phpunit" - ], "type": "library", "extra": { "branch-alias": { - "dev-master": "5.7.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1449,52 +2278,60 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "email": "sebastian@phpunit.de" + }, + { + "name": "Kore Nordmann", + "email": "mail@kore-nordmann.de" } ], - "description": "The PHP Unit Testing framework.", - "homepage": "https://phpunit.de/", + "description": "Diff implementation", + "homepage": "https://github.com/sebastianbergmann/diff", "keywords": [ - "phpunit", - "testing", - "xunit" + "diff", + "udiff", + "unidiff", + "unified diff" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/diff/issues", + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2018-02-01T05:50:59+00:00" + "time": "2024-03-02T06:30:58+00:00" }, { - "name": "phpunit/phpunit-mock-objects", - "version": "3.4.4", + "name": "sebastian/environment", + "version": "5.1.5", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", - "reference": "a23b761686d50a560cc56233b9ecf49597cc9118" + "url": "https://github.com/sebastianbergmann/environment.git", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/a23b761686d50a560cc56233b9ecf49597cc9118", - "reference": "a23b761686d50a560cc56233b9ecf49597cc9118", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.0.2", - "php": "^5.6 || ^7.0", - "phpunit/php-text-template": "^1.2", - "sebastian/exporter": "^1.2 || ^2.0" - }, - "conflict": { - "phpunit/phpunit": "<5.4.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^5.4" + "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-soap": "*" + "ext-posix": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2.x-dev" + "dev-master": "5.1-dev" } }, "autoload": { @@ -1509,139 +2346,194 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" + "email": "sebastian@phpunit.de" } ], - "description": "Mock Object library for PHPUnit", - "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", + "description": "Provides functionality to handle HHVM/PHP environments", + "homepage": "http://www.github.com/sebastianbergmann/environment", "keywords": [ - "mock", - "xunit" + "Xdebug", + "environment", + "hhvm" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/environment/issues", + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "abandoned": true, - "time": "2017-06-30T09:13:00+00:00" + "time": "2023-02-03T06:03:51+00:00" }, { - "name": "psr/container", - "version": "1.0.0", + "name": "sebastian/exporter", + "version": "4.0.6", "source": { "type": "git", - "url": "https://github.com/php-fig/container.git", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" + "url": "https://github.com/sebastianbergmann/exporter.git", + "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/78c00df8f170e02473b682df15bfcdacc3d32d72", + "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=7.3", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "ext-mbstring": "*", + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { - "psr-4": { - "Psr\\Container\\": "src/" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Volker Dusch", + "email": "github@wallbash.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" } ], - "description": "Common Container Interface (PHP FIG PSR-11)", - "homepage": "https://github.com/php-fig/container", + "description": "Provides the functionality to export PHP variables for visualization", + "homepage": "https://www.github.com/sebastianbergmann/exporter", "keywords": [ - "PSR-11", - "container", - "container-interface", - "container-interop", - "psr" + "export", + "exporter" ], - "time": "2017-02-14T16:28:37+00:00" + "support": { + "issues": "https://github.com/sebastianbergmann/exporter/issues", + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.6" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2024-03-02T06:33:00+00:00" }, { - "name": "psr/log", - "version": "1.1.2", + "name": "sebastian/global-state", + "version": "5.0.7", "source": { "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "446d54b4cb6bf489fc9d75f55843658e6f25d801" + "url": "https://github.com/sebastianbergmann/global-state.git", + "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/446d54b4cb6bf489fc9d75f55843658e6f25d801", - "reference": "446d54b4cb6bf489fc9d75f55843658e6f25d801", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", + "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" + }, + "require-dev": { + "ext-dom": "*", + "phpunit/phpunit": "^9.3" + }, + "suggest": { + "ext-uopz": "*" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1.x-dev" + "dev-master": "5.0-dev" } }, "autoload": { - "psr-4": { - "Psr\\Log\\": "Psr/Log/" - } + "classmap": [ + "src/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" } ], - "description": "Common interface for logging libraries", - "homepage": "https://github.com/php-fig/log", + "description": "Snapshotting of global state", + "homepage": "http://www.github.com/sebastianbergmann/global-state", "keywords": [ - "log", - "psr", - "psr-3" + "global state" + ], + "support": { + "issues": "https://github.com/sebastianbergmann/global-state/issues", + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.7" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2019-11-01T11:05:21+00:00" + "time": "2024-03-02T06:35:11+00:00" }, { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", + "name": "sebastian/lines-of-code", + "version": "1.0.4", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" + "url": "https://github.com/sebastianbergmann/lines-of-code.git", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/e1e4a170560925c26d424b6a03aed157e7dcc5c5", + "reference": "e1e4a170560925c26d424b6a03aed157e7dcc5c5", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "nikic/php-parser": "^4.18 || ^5.0", + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.0-dev" } }, "autoload": { @@ -1656,39 +2548,50 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Looks up which function or method a line of code belongs to", - "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" + "description": "Library for counting the lines of code in PHP source code", + "homepage": "https://github.com/sebastianbergmann/lines-of-code", + "support": { + "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/1.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2023-12-22T06:20:34+00:00" }, { - "name": "sebastian/comparator", - "version": "1.2.4", + "name": "sebastian/object-enumerator", + "version": "4.0.4", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be" + "url": "https://github.com/sebastianbergmann/object-enumerator.git", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/2b7424b55f5047b47ac6e5ccb20b2aea4011d9be", - "reference": "2b7424b55f5047b47ac6e5ccb20b2aea4011d9be", + "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/5c9eeac41b290a3712d88851518825ad78f45c71", + "reference": "5c9eeac41b290a3712d88851518825ad78f45c71", "shasum": "" }, "require": { - "php": ">=5.3.3", - "sebastian/diff": "~1.2", - "sebastian/exporter": "~1.2 || ~2.0" + "php": ">=7.3", + "sebastian/object-reflector": "^2.0", + "sebastian/recursion-context": "^4.0" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1701,56 +2604,49 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" } ], - "description": "Provides the functionality to compare PHP values for equality", - "homepage": "http://www.github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" + "description": "Traverses array structures and object graphs to enumerate all referenced objects", + "homepage": "https://github.com/sebastianbergmann/object-enumerator/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-enumerator/issues", + "source": "https://github.com/sebastianbergmann/object-enumerator/tree/4.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-01-29T09:50:25+00:00" + "time": "2020-10-26T13:12:34+00:00" }, { - "name": "sebastian/diff", - "version": "1.4.3", + "name": "sebastian/object-reflector", + "version": "2.0.4", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4" + "url": "https://github.com/sebastianbergmann/object-reflector.git", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/7f066a26a962dbe58ddea9f72a4e82874a3975a4", - "reference": "7f066a26a962dbe58ddea9f72a4e82874a3975a4", + "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", + "reference": "b4f479ebdbf63ac605d183ece17d8d7fe49c15c7", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4-dev" + "dev-master": "2.0-dev" } }, "autoload": { @@ -1763,46 +2659,49 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Kore Nordmann", - "email": "mail@kore-nordmann.de" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" } ], - "description": "Diff implementation", - "homepage": "https://github.com/sebastianbergmann/diff", - "keywords": [ - "diff" + "description": "Allows reflection of object attributes, including inherited and non-public ones", + "homepage": "https://github.com/sebastianbergmann/object-reflector/", + "support": { + "issues": "https://github.com/sebastianbergmann/object-reflector/issues", + "source": "https://github.com/sebastianbergmann/object-reflector/tree/2.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2017-05-22T07:24:03+00:00" + "time": "2020-10-26T13:14:26+00:00" }, { - "name": "sebastian/environment", - "version": "2.0.0", + "name": "sebastian/recursion-context", + "version": "4.0.5", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac" + "url": "https://github.com/sebastianbergmann/recursion-context.git", + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/5795ffe5dc5b02460c3e34222fee8cbe245d8fac", - "reference": "5795ffe5dc5b02460c3e34222fee8cbe245d8fac", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", "shasum": "" }, "require": { - "php": "^5.6 || ^7.0" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^5.0" + "phpunit/phpunit": "^9.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "4.0-dev" } }, "autoload": { @@ -1818,43 +2717,54 @@ { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" + }, + { + "name": "Jeff Welch", + "email": "whatthejeff@gmail.com" + }, + { + "name": "Adam Harvey", + "email": "aharvey@php.net" } ], - "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", - "keywords": [ - "Xdebug", - "environment", - "hhvm" + "description": "Provides functionality to recursively process PHP variables", + "homepage": "https://github.com/sebastianbergmann/recursion-context", + "support": { + "issues": "https://github.com/sebastianbergmann/recursion-context/issues", + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2016-11-26T07:53:53+00:00" + "time": "2023-02-03T06:07:39+00:00" }, { - "name": "sebastian/exporter", - "version": "2.0.0", + "name": "sebastian/resource-operations", + "version": "3.0.4", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4" + "url": "https://github.com/sebastianbergmann/resource-operations.git", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4", - "reference": "ce474bdd1a34744d7ac5d6aad3a46d48d9bac4c4", + "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/05d5692a7993ecccd56a03e40cd7e5b09b1d404e", + "reference": "05d5692a7993ecccd56a03e40cd7e5b09b1d404e", "shasum": "" }, "require": { - "php": ">=5.3.3", - "sebastian/recursion-context": "~2.0" + "php": ">=7.3" }, "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "~4.4" + "phpunit/phpunit": "^9.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-main": "3.0-dev" } }, "autoload": { @@ -1867,62 +2777,48 @@ "BSD-3-Clause" ], "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Volker Dusch", - "email": "github@wallbash.com" - }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, { "name": "Sebastian Bergmann", "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" } ], - "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", - "keywords": [ - "export", - "exporter" + "description": "Provides a list of PHP built-in functions that operate on resources", + "homepage": "https://www.github.com/sebastianbergmann/resource-operations", + "support": { + "source": "https://github.com/sebastianbergmann/resource-operations/tree/3.0.4" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2016-11-19T08:54:04+00:00" + "time": "2024-03-14T16:00:52+00:00" }, { - "name": "sebastian/global-state", - "version": "1.1.1", + "name": "sebastian/type", + "version": "3.2.1", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4" + "url": "https://github.com/sebastianbergmann/type.git", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bc37d50fea7d017d3d340f230811c9f1d7280af4", - "reference": "bc37d50fea7d017d3d340f230811c9f1d7280af4", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "~4.2" - }, - "suggest": { - "ext-uopz": "*" + "phpunit/phpunit": "^9.5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -1937,41 +2833,45 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", - "keywords": [ - "global state" + "description": "Collection of value objects that represent the types of the PHP type system", + "homepage": "https://github.com/sebastianbergmann/type", + "support": { + "issues": "https://github.com/sebastianbergmann/type/issues", + "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } ], - "time": "2015-10-12T03:26:01+00:00" + "time": "2023-02-03T06:13:03+00:00" }, { - "name": "sebastian/object-enumerator", - "version": "2.0.1", + "name": "sebastian/version", + "version": "3.0.2", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "1311872ac850040a79c3c058bea3e22d0f09cbb7" + "url": "https://github.com/sebastianbergmann/version.git", + "reference": "c6c1022351a901512170118436c764e473f6de8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/1311872ac850040a79c3c058bea3e22d0f09cbb7", - "reference": "1311872ac850040a79c3c058bea3e22d0f09cbb7", + "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/c6c1022351a901512170118436c764e473f6de8c", + "reference": "c6c1022351a901512170118436c764e473f6de8c", "shasum": "" }, "require": { - "php": ">=5.6", - "sebastian/recursion-context": "~2.0" - }, - "require-dev": { - "phpunit/phpunit": "~5" + "php": ">=7.3" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0.x-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -1986,192 +2886,312 @@ "authors": [ { "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "email": "sebastian@phpunit.de", + "role": "lead" } ], - "description": "Traverses array structures and object graphs to enumerate all referenced objects", - "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-02-18T15:18:39+00:00" + "description": "Library that helps with managing the version number of Git-hosted PHP projects", + "homepage": "https://github.com/sebastianbergmann/version", + "support": { + "issues": "https://github.com/sebastianbergmann/version/issues", + "source": "https://github.com/sebastianbergmann/version/tree/3.0.2" + }, + "funding": [ + { + "url": "https://github.com/sebastianbergmann", + "type": "github" + } + ], + "time": "2020-09-28T06:39:44+00:00" }, { - "name": "sebastian/recursion-context", - "version": "2.0.0", + "name": "symfony/config", + "version": "v7.0.6", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "2c3ba150cbec723aa057506e73a8d33bdb286c9a" + "url": "https://github.com/symfony/config.git", + "reference": "7fc7e18a73ec8125fd95928c0340470d64760deb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/2c3ba150cbec723aa057506e73a8d33bdb286c9a", - "reference": "2c3ba150cbec723aa057506e73a8d33bdb286c9a", + "url": "https://api.github.com/repos/symfony/config/zipball/7fc7e18a73ec8125fd95928c0340470d64760deb", + "reference": "7fc7e18a73ec8125fd95928c0340470d64760deb", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=8.2", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/filesystem": "^6.4|^7.0", + "symfony/polyfill-ctype": "~1.8" + }, + "conflict": { + "symfony/finder": "<6.4", + "symfony/service-contracts": "<2.5" }, "require-dev": { - "phpunit/phpunit": "~4.4" + "symfony/event-dispatcher": "^6.4|^7.0", + "symfony/finder": "^6.4|^7.0", + "symfony/messenger": "^6.4|^7.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/yaml": "^6.4|^7.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, "autoload": { - "classmap": [ - "src/" + "psr-4": { + "Symfony\\Component\\Config\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Helps you find, load, combine, autofill and validate configuration values of any kind", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/config/tree/v7.0.6" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" }, { - "name": "Adam Harvey", - "email": "aharvey@php.net" + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" } ], - "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2016-11-19T07:33:16+00:00" + "time": "2024-03-27T19:55:25+00:00" }, { - "name": "sebastian/resource-operations", - "version": "1.0.0", + "name": "symfony/console", + "version": "v7.0.6", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52" + "url": "https://github.com/symfony/console.git", + "reference": "fde915cd8e7eb99b3d531d3d5c09531429c3f9e5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/ce990bb21759f94aeafd30209e8cfcdfa8bc3f52", - "reference": "ce990bb21759f94aeafd30209e8cfcdfa8bc3f52", + "url": "https://api.github.com/repos/symfony/console/zipball/fde915cd8e7eb99b3d531d3d5c09531429c3f9e5", + "reference": "fde915cd8e7eb99b3d531d3d5c09531429c3f9e5", "shasum": "" }, "require": { - "php": ">=5.6.0" + "php": ">=8.2", + "symfony/polyfill-mbstring": "~1.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/string": "^6.4|^7.0" }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } + "conflict": { + "symfony/dependency-injection": "<6.4", + "symfony/dotenv": "<6.4", + "symfony/event-dispatcher": "<6.4", + "symfony/lock": "<6.4", + "symfony/process": "<6.4" + }, + "provide": { + "psr/log-implementation": "1.0|2.0|3.0" + }, + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/event-dispatcher": "^6.4|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/lock": "^6.4|^7.0", + "symfony/messenger": "^6.4|^7.0", + "symfony/process": "^6.4|^7.0", + "symfony/stopwatch": "^6.4|^7.0", + "symfony/var-dumper": "^6.4|^7.0" }, + "type": "library", "autoload": { - "classmap": [ - "src/" + "psr-4": { + "Symfony\\Component\\Console\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" + ], + "authors": [ + { + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Eases the creation of beautiful and testable command line interfaces", + "homepage": "https://symfony.com", + "keywords": [ + "cli", + "command-line", + "console", + "terminal" ], - "authors": [ + "support": { + "source": "https://github.com/symfony/console/tree/v7.0.6" + }, + "funding": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" } ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2015-07-28T20:34:47+00:00" + "time": "2024-04-01T11:04:53+00:00" }, { - "name": "sebastian/version", - "version": "2.0.1", + "name": "symfony/dependency-injection", + "version": "v7.0.6", "source": { "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" + "url": "https://github.com/symfony/dependency-injection.git", + "reference": "ff57b5c7d518c39eeb4e69dc0d1ec70723a117b9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", + "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/ff57b5c7d518c39eeb4e69dc0d1ec70723a117b9", + "reference": "ff57b5c7d518c39eeb4e69dc0d1ec70723a117b9", "shasum": "" }, "require": { - "php": ">=5.6" + "php": ">=8.2", + "psr/container": "^1.1|^2.0", + "symfony/deprecation-contracts": "^2.5|^3", + "symfony/service-contracts": "^3.3", + "symfony/var-exporter": "^6.4|^7.0" }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } + "conflict": { + "ext-psr": "<1.1|>=2", + "symfony/config": "<6.4", + "symfony/finder": "<6.4", + "symfony/yaml": "<6.4" + }, + "provide": { + "psr/container-implementation": "1.1|2.0", + "symfony/service-implementation": "1.1|2.0|3.0" + }, + "require-dev": { + "symfony/config": "^6.4|^7.0", + "symfony/expression-language": "^6.4|^7.0", + "symfony/yaml": "^6.4|^7.0" }, + "type": "library", "autoload": { - "classmap": [ - "src/" + "psr-4": { + "Symfony\\Component\\DependencyInjection\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" ] }, "notification-url": "https://packagist.org/downloads/", "license": [ - "BSD-3-Clause" + "MIT" ], "authors": [ { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "lead" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Library that helps with managing the version number of Git-hosted PHP projects", - "homepage": "https://github.com/sebastianbergmann/version", - "time": "2016-10-03T07:35:21+00:00" + "description": "Allows you to standardize and centralize the way objects are constructed in your application", + "homepage": "https://symfony.com", + "support": { + "source": "https://github.com/symfony/dependency-injection/tree/v7.0.6" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-03-28T09:20:36+00:00" }, { - "name": "symfony/config", - "version": "v3.4.38", + "name": "symfony/event-dispatcher", + "version": "v7.0.3", "source": { "type": "git", - "url": "https://github.com/symfony/config.git", - "reference": "03328d6e172ec7384341c622d4c28d350040d021" + "url": "https://github.com/symfony/event-dispatcher.git", + "reference": "834c28d533dd0636f910909d01b9ff45cc094b5e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/config/zipball/03328d6e172ec7384341c622d4c28d350040d021", - "reference": "03328d6e172ec7384341c622d4c28d350040d021", + "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/834c28d533dd0636f910909d01b9ff45cc094b5e", + "reference": "834c28d533dd0636f910909d01b9ff45cc094b5e", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "symfony/filesystem": "~2.8|~3.0|~4.0", - "symfony/polyfill-ctype": "~1.8" + "php": ">=8.2", + "symfony/event-dispatcher-contracts": "^2.5|^3" }, "conflict": { - "symfony/dependency-injection": "<3.3", - "symfony/finder": "<3.3" + "symfony/dependency-injection": "<6.4", + "symfony/service-contracts": "<2.5" }, - "require-dev": { - "symfony/dependency-injection": "~3.3|~4.0", - "symfony/event-dispatcher": "~3.3|~4.0", - "symfony/finder": "~3.3|~4.0", - "symfony/yaml": "~3.0|~4.0" + "provide": { + "psr/event-dispatcher-implementation": "1.0", + "symfony/event-dispatcher-implementation": "2.0|3.0" }, - "suggest": { - "symfony/yaml": "To use the yaml reference dumper" + "require-dev": { + "psr/log": "^1|^2|^3", + "symfony/config": "^6.4|^7.0", + "symfony/dependency-injection": "^6.4|^7.0", + "symfony/error-handler": "^6.4|^7.0", + "symfony/expression-language": "^6.4|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/service-contracts": "^2.5|^3", + "symfony/stopwatch": "^6.4|^7.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, "autoload": { "psr-4": { - "Symfony\\Component\\Config\\": "" + "Symfony\\Component\\EventDispatcher\\": "" }, "exclude-from-classmap": [ "/Tests/" @@ -2191,63 +3211,59 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Config Component", + "description": "Provides tools that allow your application components to communicate with each other by dispatching events and listening to them", "homepage": "https://symfony.com", - "time": "2020-02-03T08:11:57+00:00" + "support": { + "source": "https://github.com/symfony/event-dispatcher/tree/v7.0.3" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-01-23T15:02:46+00:00" }, { - "name": "symfony/console", - "version": "v3.4.38", + "name": "symfony/event-dispatcher-contracts", + "version": "v3.4.2", "source": { "type": "git", - "url": "https://github.com/symfony/console.git", - "reference": "6827023c5872bea44b29d145de693b21981cf4cd" + "url": "https://github.com/symfony/event-dispatcher-contracts.git", + "reference": "4e64b49bf370ade88e567de29465762e316e4224" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/6827023c5872bea44b29d145de693b21981cf4cd", - "reference": "6827023c5872bea44b29d145de693b21981cf4cd", + "url": "https://api.github.com/repos/symfony/event-dispatcher-contracts/zipball/4e64b49bf370ade88e567de29465762e316e4224", + "reference": "4e64b49bf370ade88e567de29465762e316e4224", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "symfony/debug": "~2.8|~3.0|~4.0", - "symfony/polyfill-mbstring": "~1.0" - }, - "conflict": { - "symfony/dependency-injection": "<3.4", - "symfony/process": "<3.3" - }, - "provide": { - "psr/log-implementation": "1.0" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~3.3|~4.0", - "symfony/dependency-injection": "~3.4|~4.0", - "symfony/event-dispatcher": "~2.8|~3.0|~4.0", - "symfony/lock": "~3.4|~4.0", - "symfony/process": "~3.3|~4.0" - }, - "suggest": { - "psr/log": "For using the console logger", - "symfony/event-dispatcher": "", - "symfony/lock": "", - "symfony/process": "" + "php": ">=8.1", + "psr/event-dispatcher": "^1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.4-dev" + "dev-main": "3.4-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { "psr-4": { - "Symfony\\Component\\Console\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] + "Symfony\\Contracts\\EventDispatcher\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -2255,51 +3271,66 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Console Component", + "description": "Generic abstractions related to dispatching event", "homepage": "https://symfony.com", - "time": "2020-02-15T13:27:16+00:00" + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/event-dispatcher-contracts/tree/v3.4.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-01-23T14:51:35+00:00" }, { - "name": "symfony/debug", - "version": "v3.4.38", + "name": "symfony/filesystem", + "version": "v7.0.6", "source": { "type": "git", - "url": "https://github.com/symfony/debug.git", - "reference": "a99278d50af8a9164219da38d61fb161a7f6e0a6" + "url": "https://github.com/symfony/filesystem.git", + "reference": "408105dff4c104454100730bdfd1a9cdd993f04d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/a99278d50af8a9164219da38d61fb161a7f6e0a6", - "reference": "a99278d50af8a9164219da38d61fb161a7f6e0a6", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/408105dff4c104454100730bdfd1a9cdd993f04d", + "reference": "408105dff4c104454100730bdfd1a9cdd993f04d", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "psr/log": "~1.0" - }, - "conflict": { - "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" - }, - "require-dev": { - "symfony/http-kernel": "~2.8|~3.0|~4.0" + "php": ">=8.2", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-mbstring": "~1.8" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, "autoload": { "psr-4": { - "Symfony\\Component\\Debug\\": "" + "Symfony\\Component\\Filesystem\\": "" }, "exclude-from-classmap": [ "/Tests/" @@ -2319,58 +3350,51 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Debug Component", + "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", - "time": "2020-02-03T15:10:40+00:00" + "support": { + "source": "https://github.com/symfony/filesystem/tree/v7.0.6" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-03-21T19:37:36+00:00" }, { - "name": "symfony/dependency-injection", - "version": "v3.4.38", + "name": "symfony/finder", + "version": "v7.0.0", "source": { "type": "git", - "url": "https://github.com/symfony/dependency-injection.git", - "reference": "b06b36883abc61eb8fb576e89102a9ba6c9ee7ee" + "url": "https://github.com/symfony/finder.git", + "reference": "6e5688d69f7cfc4ed4a511e96007e06c2d34ce56" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/dependency-injection/zipball/b06b36883abc61eb8fb576e89102a9ba6c9ee7ee", - "reference": "b06b36883abc61eb8fb576e89102a9ba6c9ee7ee", + "url": "https://api.github.com/repos/symfony/finder/zipball/6e5688d69f7cfc4ed4a511e96007e06c2d34ce56", + "reference": "6e5688d69f7cfc4ed4a511e96007e06c2d34ce56", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "psr/container": "^1.0" - }, - "conflict": { - "symfony/config": "<3.3.7", - "symfony/finder": "<3.3", - "symfony/proxy-manager-bridge": "<3.4", - "symfony/yaml": "<3.4" - }, - "provide": { - "psr/container-implementation": "1.0" + "php": ">=8.2" }, "require-dev": { - "symfony/config": "~3.3|~4.0", - "symfony/expression-language": "~2.8|~3.0|~4.0", - "symfony/yaml": "~3.4|~4.0" - }, - "suggest": { - "symfony/config": "", - "symfony/expression-language": "For using expressions in service container configuration", - "symfony/finder": "For using double-star glob patterns or when GLOB_BRACE portability is required", - "symfony/proxy-manager-bridge": "Generate service proxies to lazy load them", - "symfony/yaml": "" + "symfony/filesystem": "^6.4|^7.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, "autoload": { "psr-4": { - "Symfony\\Component\\DependencyInjection\\": "" + "Symfony\\Component\\Finder\\": "" }, "exclude-from-classmap": [ "/Tests/" @@ -2390,50 +3414,49 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony DependencyInjection Component", + "description": "Finds files and directories via an intuitive fluent interface", "homepage": "https://symfony.com", - "time": "2020-02-19T17:19:43+00:00" + "support": { + "source": "https://github.com/symfony/finder/tree/v7.0.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-10-31T17:59:56+00:00" }, { - "name": "symfony/event-dispatcher", - "version": "v3.4.38", + "name": "symfony/options-resolver", + "version": "v7.0.0", "source": { "type": "git", - "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "2f67a869aef3eecf42e7f8be4a8b86c92308686c" + "url": "https://github.com/symfony/options-resolver.git", + "reference": "700ff4096e346f54cb628ea650767c8130f1001f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/2f67a869aef3eecf42e7f8be4a8b86c92308686c", - "reference": "2f67a869aef3eecf42e7f8be4a8b86c92308686c", + "url": "https://api.github.com/repos/symfony/options-resolver/zipball/700ff4096e346f54cb628ea650767c8130f1001f", + "reference": "700ff4096e346f54cb628ea650767c8130f1001f", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8" - }, - "conflict": { - "symfony/dependency-injection": "<3.3" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/config": "~2.8|~3.0|~4.0", - "symfony/dependency-injection": "~3.3|~4.0", - "symfony/expression-language": "~2.8|~3.0|~4.0", - "symfony/stopwatch": "~2.8|~3.0|~4.0" - }, - "suggest": { - "symfony/dependency-injection": "", - "symfony/http-kernel": "" + "php": ">=8.2", + "symfony/deprecation-contracts": "^2.5|^3" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, "autoload": { "psr-4": { - "Symfony\\Component\\EventDispatcher\\": "" + "Symfony\\Component\\OptionsResolver\\": "" }, "exclude-from-classmap": [ "/Tests/" @@ -2453,41 +3476,69 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony EventDispatcher Component", + "description": "Provides an improved replacement for the array_replace PHP function", "homepage": "https://symfony.com", - "time": "2020-02-04T08:04:52+00:00" + "keywords": [ + "config", + "configuration", + "options" + ], + "support": { + "source": "https://github.com/symfony/options-resolver/tree/v7.0.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-08-08T10:20:21+00:00" }, { - "name": "symfony/filesystem", - "version": "v3.4.38", + "name": "symfony/polyfill-ctype", + "version": "v1.29.0", "source": { "type": "git", - "url": "https://github.com/symfony/filesystem.git", - "reference": "0a0d3b4bda11aa3a0464531c40e681e184e75628" + "url": "https://github.com/symfony/polyfill-ctype.git", + "reference": "ef4d7e442ca910c4764bce785146269b30cb5fc4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/0a0d3b4bda11aa3a0464531c40e681e184e75628", - "reference": "0a0d3b4bda11aa3a0464531c40e681e184e75628", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ef4d7e442ca910c4764bce785146269b30cb5fc4", + "reference": "ef4d7e442ca910c4764bce785146269b30cb5fc4", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "symfony/polyfill-ctype": "~1.8" + "php": ">=7.1" + }, + "provide": { + "ext-ctype": "*" + }, + "suggest": { + "ext-ctype": "For best performance" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "3.4-dev" + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { + "files": [ + "bootstrap.php" + ], "psr-4": { - "Symfony\\Component\\Filesystem\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] + "Symfony\\Polyfill\\Ctype\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -2495,48 +3546,75 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Filesystem Component", + "description": "Symfony polyfill for ctype functions", "homepage": "https://symfony.com", - "time": "2020-01-17T08:50:08+00:00" + "keywords": [ + "compatibility", + "ctype", + "polyfill", + "portable" + ], + "support": { + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.29.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-01-29T20:11:03+00:00" }, { - "name": "symfony/finder", - "version": "v3.4.38", + "name": "symfony/polyfill-intl-grapheme", + "version": "v1.29.0", "source": { "type": "git", - "url": "https://github.com/symfony/finder.git", - "reference": "5ec813ccafa8164ef21757e8c725d3a57da59200" + "url": "https://github.com/symfony/polyfill-intl-grapheme.git", + "reference": "32a9da87d7b3245e09ac426c83d334ae9f06f80f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/5ec813ccafa8164ef21757e8c725d3a57da59200", - "reference": "5ec813ccafa8164ef21757e8c725d3a57da59200", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/32a9da87d7b3245e09ac426c83d334ae9f06f80f", + "reference": "32a9da87d7b3245e09ac426c83d334ae9f06f80f", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8" + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "3.4-dev" + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { + "files": [ + "bootstrap.php" + ], "psr-4": { - "Symfony\\Component\\Finder\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] + "Symfony\\Polyfill\\Intl\\Grapheme\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -2544,47 +3622,79 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for intl's grapheme_* functions", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "grapheme", + "intl", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.29.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" }, { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" } ], - "description": "Symfony Finder Component", - "homepage": "https://symfony.com", - "time": "2020-02-14T07:34:21+00:00" + "time": "2024-01-29T20:11:03+00:00" }, { - "name": "symfony/options-resolver", - "version": "v3.4.38", + "name": "symfony/polyfill-intl-normalizer", + "version": "v1.29.0", "source": { "type": "git", - "url": "https://github.com/symfony/options-resolver.git", - "reference": "730ef56164ed6c9356c159e9f5ff2b84d753b9ed" + "url": "https://github.com/symfony/polyfill-intl-normalizer.git", + "reference": "bc45c394692b948b4d383a08d7753968bed9a83d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/options-resolver/zipball/730ef56164ed6c9356c159e9f5ff2b84d753b9ed", - "reference": "730ef56164ed6c9356c159e9f5ff2b84d753b9ed", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/bc45c394692b948b4d383a08d7753968bed9a83d", + "reference": "bc45c394692b948b4d383a08d7753968bed9a83d", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8" + "php": ">=7.1" + }, + "suggest": { + "ext-intl": "For best performance" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "3.4-dev" + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { + "files": [ + "bootstrap.php" + ], "psr-4": { - "Symfony\\Component\\OptionsResolver\\": "" + "Symfony\\Polyfill\\Intl\\Normalizer\\": "" }, - "exclude-from-classmap": [ - "/Tests/" + "classmap": [ + "Resources/stubs" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2593,56 +3703,80 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony OptionsResolver Component", + "description": "Symfony polyfill for intl's Normalizer class and related functions", "homepage": "https://symfony.com", "keywords": [ - "config", - "configuration", - "options" + "compatibility", + "intl", + "normalizer", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.29.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } ], - "time": "2020-01-01T11:03:25+00:00" + "time": "2024-01-29T20:11:03+00:00" }, { - "name": "symfony/polyfill-ctype", - "version": "v1.14.0", + "name": "symfony/polyfill-mbstring", + "version": "v1.29.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "fbdeaec0df06cf3d51c93de80c7eb76e271f5a38" + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/fbdeaec0df06cf3d51c93de80c7eb76e271f5a38", - "reference": "fbdeaec0df06cf3d51c93de80c7eb76e271f5a38", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9773676c8a1bb1f8d4340a62efe641cf76eda7ec", + "reference": "9773676c8a1bb1f8d4340a62efe641cf76eda7ec", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=7.1" + }, + "provide": { + "ext-mbstring": "*" }, "suggest": { - "ext-ctype": "For best performance" + "ext-mbstring": "For best performance" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.14-dev" + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -2650,56 +3784,75 @@ ], "authors": [ { - "name": "Gert de Pagter", - "email": "BackEndTea@gmail.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill for ctype functions", + "description": "Symfony polyfill for the Mbstring extension", "homepage": "https://symfony.com", "keywords": [ "compatibility", - "ctype", + "mbstring", "polyfill", - "portable" + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.29.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } ], - "time": "2020-01-13T11:15:53+00:00" + "time": "2024-01-29T20:11:03+00:00" }, { - "name": "symfony/polyfill-mbstring", - "version": "v1.14.0", + "name": "symfony/polyfill-php80", + "version": "v1.29.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "34094cfa9abe1f0f14f48f490772db7a775559f2" + "url": "https://github.com/symfony/polyfill-php80.git", + "reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/34094cfa9abe1f0f14f48f490772db7a775559f2", - "reference": "34094cfa9abe1f0f14f48f490772db7a775559f2", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/87b68208d5c1188808dd7839ee1e6c8ec3b02f1b", + "reference": "87b68208d5c1188808dd7839ee1e6c8ec3b02f1b", "shasum": "" }, "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-mbstring": "For best performance" + "php": ">=7.1" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.14-dev" + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, "files": [ "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Php80\\": "" + }, + "classmap": [ + "Resources/stubs" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2707,6 +3860,10 @@ "MIT" ], "authors": [ + { + "name": "Ion Bazan", + "email": "ion.bazan@gmail.com" + }, { "name": "Nicolas Grekas", "email": "p@tchwork.com" @@ -2716,48 +3873,64 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill for the Mbstring extension", + "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", "homepage": "https://symfony.com", "keywords": [ "compatibility", - "mbstring", "polyfill", "portable", "shim" ], - "time": "2020-01-13T11:15:53+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-php80/tree/v1.29.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-01-29T20:11:03+00:00" }, { - "name": "symfony/polyfill-php70", - "version": "v1.14.0", + "name": "symfony/polyfill-php81", + "version": "v1.29.0", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-php70.git", - "reference": "419c4940024c30ccc033650373a1fe13890d3255" + "url": "https://github.com/symfony/polyfill-php81.git", + "reference": "c565ad1e63f30e7477fc40738343c62b40bc672d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/419c4940024c30ccc033650373a1fe13890d3255", - "reference": "419c4940024c30ccc033650373a1fe13890d3255", + "url": "https://api.github.com/repos/symfony/polyfill-php81/zipball/c565ad1e63f30e7477fc40738343c62b40bc672d", + "reference": "c565ad1e63f30e7477fc40738343c62b40bc672d", "shasum": "" }, "require": { - "paragonie/random_compat": "~1.0|~2.0|~9.99", - "php": ">=5.3.3" + "php": ">=7.1" }, "type": "library", "extra": { - "branch-alias": { - "dev-master": "1.14-dev" + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php70\\": "" - }, "files": [ "bootstrap.php" ], + "psr-4": { + "Symfony\\Polyfill\\Php81\\": "" + }, "classmap": [ "Resources/stubs" ] @@ -2776,7 +3949,7 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions", + "description": "Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions", "homepage": "https://symfony.com", "keywords": [ "compatibility", @@ -2784,37 +3957,49 @@ "portable", "shim" ], - "time": "2020-01-13T11:15:53+00:00" + "support": { + "source": "https://github.com/symfony/polyfill-php81/tree/v1.29.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-01-29T20:11:03+00:00" }, { - "name": "symfony/polyfill-php72", - "version": "v1.14.0", + "name": "symfony/process", + "version": "v7.0.4", "source": { "type": "git", - "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "46ecacf4751dd0dc81e4f6bf01dbf9da1dc1dadf" + "url": "https://github.com/symfony/process.git", + "reference": "0e7727191c3b71ebec6d529fa0e50a01ca5679e9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/46ecacf4751dd0dc81e4f6bf01dbf9da1dc1dadf", - "reference": "46ecacf4751dd0dc81e4f6bf01dbf9da1dc1dadf", + "url": "https://api.github.com/repos/symfony/process/zipball/0e7727191c3b71ebec6d529fa0e50a01ca5679e9", + "reference": "0e7727191c3b71ebec6d529fa0e50a01ca5679e9", "shasum": "" }, "require": { - "php": ">=5.3.3" + "php": ">=8.2" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.14-dev" - } - }, "autoload": { "psr-4": { - "Symfony\\Polyfill\\Php72\\": "" + "Symfony\\Component\\Process\\": "" }, - "files": [ - "bootstrap.php" + "exclude-from-classmap": [ + "/Tests/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2823,53 +4008,72 @@ ], "authors": [ { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" + "name": "Fabien Potencier", + "email": "fabien@symfony.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", + "description": "Executes commands in sub-processes", "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" + "support": { + "source": "https://github.com/symfony/process/tree/v7.0.4" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } ], - "time": "2020-01-13T11:15:53+00:00" + "time": "2024-02-22T20:27:20+00:00" }, { - "name": "symfony/process", - "version": "v3.4.38", + "name": "symfony/service-contracts", + "version": "v3.4.2", "source": { "type": "git", - "url": "https://github.com/symfony/process.git", - "reference": "b03b02dcea26ba4c65c16a73bab4f00c186b13da" + "url": "https://github.com/symfony/service-contracts.git", + "reference": "11bbf19a0fb7b36345861e85c5768844c552906e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/process/zipball/b03b02dcea26ba4c65c16a73bab4f00c186b13da", - "reference": "b03b02dcea26ba4c65c16a73bab4f00c186b13da", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/11bbf19a0fb7b36345861e85c5768844c552906e", + "reference": "11bbf19a0fb7b36345861e85c5768844c552906e", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8" + "php": ">=8.1", + "psr/container": "^1.1|^2.0" + }, + "conflict": { + "ext-psr": "<1.1|>=2" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "3.4-dev" + "dev-main": "3.4-dev" + }, + "thanks": { + "name": "symfony/contracts", + "url": "https://github.com/symfony/contracts" } }, "autoload": { "psr-4": { - "Symfony\\Component\\Process\\": "" + "Symfony\\Contracts\\Service\\": "" }, "exclude-from-classmap": [ - "/Tests/" + "/Test/" ] }, "notification-url": "https://packagist.org/downloads/", @@ -2878,41 +4082,62 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Process Component", + "description": "Generic abstractions related to writing services", "homepage": "https://symfony.com", - "time": "2020-02-04T08:04:52+00:00" + "keywords": [ + "abstractions", + "contracts", + "decoupling", + "interfaces", + "interoperability", + "standards" + ], + "support": { + "source": "https://github.com/symfony/service-contracts/tree/v3.4.2" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-12-19T21:51:00+00:00" }, { "name": "symfony/stopwatch", - "version": "v3.4.38", + "version": "v7.0.3", "source": { "type": "git", "url": "https://github.com/symfony/stopwatch.git", - "reference": "e2d954156d4817c9a5c79f519a71516693a4a9c8" + "reference": "983900d6fddf2b0cbaacacbbad07610854bd8112" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/stopwatch/zipball/e2d954156d4817c9a5c79f519a71516693a4a9c8", - "reference": "e2d954156d4817c9a5c79f519a71516693a4a9c8", + "url": "https://api.github.com/repos/symfony/stopwatch/zipball/983900d6fddf2b0cbaacacbbad07610854bd8112", + "reference": "983900d6fddf2b0cbaacacbbad07610854bd8112", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8" + "php": ">=8.2", + "symfony/service-contracts": "^2.5|^3" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, "autoload": { "psr-4": { "Symfony\\Component\\Stopwatch\\": "" @@ -2935,46 +4160,65 @@ "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Stopwatch Component", + "description": "Provides a way to profile code", "homepage": "https://symfony.com", - "time": "2020-01-01T11:03:25+00:00" + "support": { + "source": "https://github.com/symfony/stopwatch/tree/v7.0.3" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-01-23T15:02:46+00:00" }, { - "name": "symfony/yaml", - "version": "v3.4.38", + "name": "symfony/string", + "version": "v7.0.4", "source": { "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "bc63e15160866e8730a1f738541b194c401f72bf" + "url": "https://github.com/symfony/string.git", + "reference": "f5832521b998b0bec40bee688ad5de98d4cf111b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/bc63e15160866e8730a1f738541b194c401f72bf", - "reference": "bc63e15160866e8730a1f738541b194c401f72bf", + "url": "https://api.github.com/repos/symfony/string/zipball/f5832521b998b0bec40bee688ad5de98d4cf111b", + "reference": "f5832521b998b0bec40bee688ad5de98d4cf111b", "shasum": "" }, "require": { - "php": "^5.5.9|>=7.0.8", - "symfony/polyfill-ctype": "~1.8" + "php": ">=8.2", + "symfony/polyfill-ctype": "~1.8", + "symfony/polyfill-intl-grapheme": "~1.0", + "symfony/polyfill-intl-normalizer": "~1.0", + "symfony/polyfill-mbstring": "~1.0" }, "conflict": { - "symfony/console": "<3.4" + "symfony/translation-contracts": "<2.5" }, "require-dev": { - "symfony/console": "~3.4|~4.0" - }, - "suggest": { - "symfony/console": "For validating YAML files using the lint command" + "symfony/error-handler": "^6.4|^7.0", + "symfony/http-client": "^6.4|^7.0", + "symfony/intl": "^6.4|^7.0", + "symfony/translation-contracts": "^2.5|^3.0", + "symfony/var-exporter": "^6.4|^7.0" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.4-dev" - } - }, "autoload": { + "files": [ + "Resources/functions.php" + ], "psr-4": { - "Symfony\\Component\\Yaml\\": "" + "Symfony\\Component\\String\\": "" }, "exclude-from-classmap": [ "/Tests/" @@ -2986,47 +4230,73 @@ ], "authors": [ { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" }, { "name": "Symfony Community", "homepage": "https://symfony.com/contributors" } ], - "description": "Symfony Yaml Component", + "description": "Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way", "homepage": "https://symfony.com", - "time": "2020-01-16T19:04:26+00:00" + "keywords": [ + "grapheme", + "i18n", + "string", + "unicode", + "utf-8", + "utf8" + ], + "support": { + "source": "https://github.com/symfony/string/tree/v7.0.4" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-02-01T13:17:36+00:00" }, { - "name": "webmozart/assert", - "version": "1.7.0", + "name": "symfony/var-exporter", + "version": "v7.0.6", "source": { "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "aed98a490f9a8f78468232db345ab9cf606cf598" + "url": "https://github.com/symfony/var-exporter.git", + "reference": "c74c568d2a15a1d407cf40d61ea82bc2d521e27b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/aed98a490f9a8f78468232db345ab9cf606cf598", - "reference": "aed98a490f9a8f78468232db345ab9cf606cf598", + "url": "https://api.github.com/repos/symfony/var-exporter/zipball/c74c568d2a15a1d407cf40d61ea82bc2d521e27b", + "reference": "c74c568d2a15a1d407cf40d61ea82bc2d521e27b", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "vimeo/psalm": "<3.6.0" + "php": ">=8.2" }, "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" + "symfony/property-access": "^6.4|^7.0", + "symfony/serializer": "^6.4|^7.0", + "symfony/var-dumper": "^6.4|^7.0" }, "type": "library", "autoload": { "psr-4": { - "Webmozart\\Assert\\": "src/" - } + "Symfony\\Component\\VarExporter\\": "" + }, + "exclude-from-classmap": [ + "/Tests/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -3034,27 +4304,107 @@ ], "authors": [ { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], - "description": "Assertions to validate method input/output with nice error messages.", + "description": "Allows exporting any serializable PHP data structure to plain PHP code", + "homepage": "https://symfony.com", "keywords": [ - "assert", - "check", - "validate" + "clone", + "construct", + "export", + "hydrate", + "instantiate", + "lazy-loading", + "proxy", + "serialize" + ], + "support": { + "source": "https://github.com/symfony/var-exporter/tree/v7.0.6" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2024-03-20T21:25:22+00:00" + }, + { + "name": "theseer/tokenizer", + "version": "1.2.3", + "source": { + "type": "git", + "url": "https://github.com/theseer/tokenizer.git", + "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", + "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", + "shasum": "" + }, + "require": { + "ext-dom": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": "^7.2 || ^8.0" + }, + "type": "library", + "autoload": { + "classmap": [ + "src/" + ] + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Arne Blankerts", + "email": "arne@blankerts.de", + "role": "Developer" + } + ], + "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.2.3" + }, + "funding": [ + { + "url": "https://github.com/theseer", + "type": "github" + } ], - "time": "2020-02-14T12:15:55+00:00" + "time": "2024-03-03T12:36:25+00:00" } ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "phpmd/phpmd": 0 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": ">=7.0.0", + "php": ">=7.2.5", "ext-json": "*" }, - "platform-dev": [] + "platform-dev": [], + "plugin-api-version": "2.6.0" } diff --git a/phpunit.xml b/phpunit.xml index 65002f75..7f456f18 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,13 +1,13 @@ - - - - ./tests/ - - - - - ./src/ - - + + + + ./src/ + + + + + ./tests/ + + diff --git a/src/Adapter/Guzzle.php b/src/Adapter/Guzzle.php index 71e7dd75..eeb51ade 100644 --- a/src/Adapter/Guzzle.php +++ b/src/Adapter/Guzzle.php @@ -5,6 +5,7 @@ use Cloudflare\API\Auth\Auth; use GuzzleHttp\Client; use GuzzleHttp\Exception\RequestException; +use InvalidArgumentException; use Psr\Http\Message\ResponseInterface; class Guzzle implements Adapter @@ -76,7 +77,7 @@ public function delete(string $uri, array $data = [], array $headers = []): Resp public function request(string $method, string $uri, array $data = [], array $headers = []) { if (!in_array($method, ['get', 'post', 'put', 'patch', 'delete'])) { - throw new \InvalidArgumentException('Request method must be get, post, put, patch, or delete'); + throw new InvalidArgumentException('Request method must be get, post, put, patch, or delete'); } try { diff --git a/src/Endpoints/WorkersRoute.php b/src/Endpoints/WorkersRoute.php new file mode 100644 index 00000000..efb7df9a --- /dev/null +++ b/src/Endpoints/WorkersRoute.php @@ -0,0 +1,97 @@ + + * User: HemeraOne + * Date: 16/01/2023 + */ + +namespace Cloudflare\API\Endpoints; + +use Cloudflare\API\Adapter\Adapter; +use Cloudflare\API\Traits\BodyAccessorTrait; + +class WorkersRoute implements API +{ + use BodyAccessorTrait; + + private $adapter; + + public function __construct(Adapter $adapter) + { + $this->adapter = $adapter; + } + + /** + * @param string $zoneID + * @return mixed + */ + public function listRoutes(string $zoneID) + { + $workerRoutes = $this->adapter->get('zones/' . $zoneID . '/workers/routes'); + $this->body = json_decode($workerRoutes->getBody()); + + return $this->body->result; + } + + public function getRoute(string $zoneID, string $routeID) + { + $workerRoutes = $this->adapter->get('zones/' . $zoneID . '/workers/routes/' . $routeID); + $this->body = json_decode($workerRoutes->getBody()); + + return $this->body->result; + } + + public function createRoute(string $zoneID, string $pattern, ?string $script = null) + { + $options = [ + 'pattern' => $pattern + ]; + + if($script) { + $options['script'] = $script; + } + + $query = $this->adapter->post('zones/' . $zoneID . '/workers/routes', $options); + + $this->body = json_decode($query->getBody()); + + if (isset($this->body->result->id)) { + return true; + } + + return false; + } + + public function updateRoute(string $zoneID, string $routeID, string $pattern, ?string $script = null) + { + $options = [ + 'pattern' => $pattern + ]; + + if($script) { + $options['script'] = $script; + } + + $query = $this->adapter->put('zones/' . $zoneID . '/workers/routes/' . $routeID, $options); + + $this->body = json_decode($query->getBody()); + + if (isset($this->body->result->id)) { + return true; + } + + return false; + } + + public function deleteRoute(string $zoneID, string $routeID) + { + $workerRoutes = $this->adapter->delete('zones/' . $zoneID . '/workers/routes/' . $routeID); + $this->body = json_decode($workerRoutes->getBody()); + + if (isset($this->body->result->id)) { + return true; + } + + return false; + } +} diff --git a/tests/Adapter/GuzzleTest.php b/tests/Adapter/GuzzleTest.php index 25208df1..b083616c 100644 --- a/tests/Adapter/GuzzleTest.php +++ b/tests/Adapter/GuzzleTest.php @@ -1,21 +1,23 @@ getMockBuilder(\Cloudflare\API\Auth\Auth::class) + $auth = $this->getMockBuilder(Auth::class) ->setMethods(['getHeaders']) ->getMock(); $auth->method('getHeaders') ->willReturn(['X-Testing' => 'Test']); - $this->client = new \Cloudflare\API\Adapter\Guzzle($auth, 'https://httpbin.org/'); + $this->client = new Guzzle($auth, 'https://httpbin.org/'); } public function testGet() diff --git a/tests/Auth/APIKeyTest.php b/tests/Auth/APIKeyTest.php index 10a788bb..36910c21 100644 --- a/tests/Auth/APIKeyTest.php +++ b/tests/Auth/APIKeyTest.php @@ -1,5 +1,7 @@ getHeaders(); $this->assertArrayHasKey('X-Auth-Key', $headers); diff --git a/tests/Auth/APITokenTest.php b/tests/Auth/APITokenTest.php index ea7ec3c3..016af31d 100644 --- a/tests/Auth/APITokenTest.php +++ b/tests/Auth/APITokenTest.php @@ -1,5 +1,7 @@ getHeaders(); $this->assertArrayHasKey('Authorization', $headers); diff --git a/tests/Auth/NoneTest.php b/tests/Auth/NoneTest.php index 7e46b42b..55af9e72 100644 --- a/tests/Auth/NoneTest.php +++ b/tests/Auth/NoneTest.php @@ -1,4 +1,7 @@ getHeaders(); $this->assertEquals([], $headers); diff --git a/tests/Auth/UserServiceKeyTest.php b/tests/Auth/UserServiceKeyTest.php index 53e29b30..f450c5c7 100644 --- a/tests/Auth/UserServiceKeyTest.php +++ b/tests/Auth/UserServiceKeyTest.php @@ -1,5 +1,7 @@ getHeaders(); $this->assertArrayHasKey('X-Auth-User-Service-Key', $headers); diff --git a/tests/Configurations/ConfigurationsUARulesTest.php b/tests/Configurations/ConfigurationsUARulesTest.php index bd6d45b2..03ad4a1e 100644 --- a/tests/Configurations/ConfigurationsUARulesTest.php +++ b/tests/Configurations/ConfigurationsUARulesTest.php @@ -1,5 +1,7 @@ addUA('Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/603.2.4 (KHTML, like Gecko) Version/10.1.1 Safari/603.2.4'); $array = $configuration->getArray(); diff --git a/tests/Configurations/ConfigurationsZoneLockdownTest.php b/tests/Configurations/ConfigurationsZoneLockdownTest.php index 7614042b..4d4daabc 100644 --- a/tests/Configurations/ConfigurationsZoneLockdownTest.php +++ b/tests/Configurations/ConfigurationsZoneLockdownTest.php @@ -1,5 +1,7 @@ addIP('1.2.3.4'); $array = $configuration->getArray(); diff --git a/tests/Configurations/LoadBalancerTest.php b/tests/Configurations/LoadBalancerTest.php index 96b3d1e7..ae2cf44f 100644 --- a/tests/Configurations/LoadBalancerTest.php +++ b/tests/Configurations/LoadBalancerTest.php @@ -11,7 +11,7 @@ class LoadBalancerTest extends TestCase { /** - * @dataProvider testArgumentsDataProvider + * @dataProvider dataProviderTestArguments */ public function testArguments($setFunction, $arguments, $getFunction, $invalid) { @@ -30,7 +30,7 @@ public function testArguments($setFunction, $arguments, $getFunction, $invalid) } } - public function testArgumentsDataProvider() + public function dataProviderTestArguments() { return [ 'steeringPolicy arguments valid' => [ diff --git a/tests/Configurations/PoolTest.php b/tests/Configurations/PoolTest.php index 204b392c..cf6f7a3f 100644 --- a/tests/Configurations/PoolTest.php +++ b/tests/Configurations/PoolTest.php @@ -11,7 +11,7 @@ class PoolTest extends TestCase { /** - * @dataProvider testArgumentsDataProvider + * @dataProvider dataProviderTestArguments */ public function testArguments($setFunction, $arguments, $getFunction, $invalid) { @@ -30,7 +30,7 @@ public function testArguments($setFunction, $arguments, $getFunction, $invalid) } } - public function testArgumentsDataProvider() + public function dataProviderTestArguments() { return [ 'origins arguments valid' => [ diff --git a/tests/Endpoints/AccessRulesTest.php b/tests/Endpoints/AccessRulesTest.php index fbe4bd48..7bec02c7 100644 --- a/tests/Endpoints/AccessRulesTest.php +++ b/tests/Endpoints/AccessRulesTest.php @@ -1,12 +1,16 @@ getPsr7JsonResponseForFixture('Endpoints/listAccessRules.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -20,11 +24,11 @@ public function testListRules() ]) ); - $zones = new \Cloudflare\API\Endpoints\AccessRules($mock); + $zones = new AccessRules($mock); $result = $zones->listRules('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('92f17202ed8bd63d69a66b86a49a8f6b', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -33,12 +37,12 @@ public function testListRules() public function testCreateRule() { - $config = new \Cloudflare\API\Configurations\AccessRules(); + $config = new AccessRulesConfiguration(); $config->setIP('1.2.3.4'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/createAccessRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -52,7 +56,7 @@ public function testCreateRule() ]) ); - $rules = new \Cloudflare\API\Endpoints\AccessRules($mock); + $rules = new AccessRules($mock); $rules->createRule( '023e105f4ecef8ad9ca31a8372d0c353', 'challenge', @@ -66,7 +70,7 @@ public function testUpdateRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateAccessRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -79,7 +83,7 @@ public function testUpdateRule() ]) ); - $rules = new \Cloudflare\API\Endpoints\AccessRules($mock); + $rules = new AccessRules($mock); $rules->updateRule( '023e105f4ecef8ad9ca31a8372d0c353', '92f17202ed8bd63d69a66b86a49a8f6b', @@ -93,7 +97,7 @@ public function testDeleteRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteAccessRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -105,7 +109,7 @@ public function testDeleteRule() ]) ); - $rules = new \Cloudflare\API\Endpoints\AccessRules($mock); + $rules = new AccessRules($mock); $rules->deleteRule('023e105f4ecef8ad9ca31a8372d0c353', '92f17202ed8bd63d69a66b86a49a8f6b'); $this->assertEquals('92f17202ed8bd63d69a66b86a49a8f6b', $rules->getBody()->result->id); } diff --git a/tests/Endpoints/AccountMembersTest.php b/tests/Endpoints/AccountMembersTest.php index 431e2634..e5054849 100644 --- a/tests/Endpoints/AccountMembersTest.php +++ b/tests/Endpoints/AccountMembersTest.php @@ -9,7 +9,7 @@ public function testAddAccountMember() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/createAccountMember.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -34,7 +34,7 @@ public function testListAccountMembers() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listAccountMembers.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -50,7 +50,7 @@ public function testListAccountMembers() $accountMembers = new AccountMembers($mock); $result = $accountMembers->listAccountMembers('023e105f4ecef8ad9ca31a8372d0c353', 1, 20); - $this->assertObjectHasAttribute('result', $result); + $this->assertObjectHasProperty('result', $result); $this->assertEquals('4536bcfad5faccb111b47003c79917fa', $result->result[0]->id); $this->assertEquals(1, $result->result_info->count); diff --git a/tests/Endpoints/AccountRolesTest.php b/tests/Endpoints/AccountRolesTest.php index acb16be8..a9f349cd 100644 --- a/tests/Endpoints/AccountRolesTest.php +++ b/tests/Endpoints/AccountRolesTest.php @@ -12,7 +12,7 @@ public function testListAccountRoles() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listAccountRoles.json'); - $adapter = $this->getMockBuilder(Adapter::class)->getMock(); + $adapter = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $adapter->method('get')->willReturn($response); $adapter->expects($this->once()) @@ -22,8 +22,8 @@ public function testListAccountRoles() $roles = new AccountRoles($adapter); $result = $roles->listAccountRoles('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('3536bcfad5faccb999b47003c79917fb', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); diff --git a/tests/Endpoints/AccountsTest.php b/tests/Endpoints/AccountsTest.php index 24f1f3ca..d7905d15 100644 --- a/tests/Endpoints/AccountsTest.php +++ b/tests/Endpoints/AccountsTest.php @@ -1,5 +1,6 @@ getPsr7JsonResponseForFixture('Endpoints/listAccounts.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -30,8 +31,8 @@ public function testListZones() $accounts = new Accounts($mock); $result = $accounts->listAccounts(1, 20, 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('023e105f4ecef8ad9ca31a8372d0c353', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -42,7 +43,7 @@ public function testAddAccountWithDefaultType() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/createStandardAccount.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -65,7 +66,7 @@ public function testAddAccountWithCustomType() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/createEnterpriseAccount.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) diff --git a/tests/Endpoints/CertificatesTest.php b/tests/Endpoints/CertificatesTest.php index aa6c80d0..95057c7c 100644 --- a/tests/Endpoints/CertificatesTest.php +++ b/tests/Endpoints/CertificatesTest.php @@ -1,5 +1,7 @@ getPsr7JsonResponseForFixture('Endpoints/listCertificates.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -25,7 +27,7 @@ public function testListCertificates() $certEndpoint = new Certificates($mock); $result = $certEndpoint->listCertificates('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('result', $result); + $this->assertObjectHasProperty('result', $result); $cert = $result->result[0]; $this->assertEquals('328578533902268680212849205732770752308931942346', $cert->id); @@ -40,7 +42,7 @@ public function testGetCertificate() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getCertificate.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -57,7 +59,7 @@ public function testGetCertificate() '023e105f4ecef8ad9ca31a8372d0c353' ); - $this->assertObjectHasAttribute('result', $response); + $this->assertObjectHasProperty('result', $response); $cert = $response->result; $this->assertEquals('6666699999996666699999999966666666', $cert->id); $this->assertEquals('origin-ecc', $cert->request_type); @@ -71,7 +73,7 @@ public function testRevokeCertificate() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getCertificate.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -93,15 +95,15 @@ public function testRevokeCertificate() public function testCreateCertificate() { - $certificate = new \Cloudflare\API\Configurations\Certificate(); + $certificate = new Certificate(); $certificate->setHostnames(['foo.example.com', 'bar.exapmle.com']); - $certificate->setRequestType(\Cloudflare\API\Configurations\Certificate::ORIGIN_ECC); + $certificate->setRequestType(Certificate::ORIGIN_ECC); $certificate->setRequestedValidity(365); $certificate->setCsr('some-csr-data-barbar'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/getCertificate.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) diff --git a/tests/Endpoints/CryptoTest.php b/tests/Endpoints/CryptoTest.php index 6f617fdc..af0f058b 100644 --- a/tests/Endpoints/CryptoTest.php +++ b/tests/Endpoints/CryptoTest.php @@ -1,12 +1,15 @@ getPsr7JsonResponseForFixture('Endpoints/getOpportunisticEncryptionSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -15,7 +18,7 @@ public function testGetOpportunisticEncryptionSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/opportunistic_encryption') ); - $cryptoMock = new \Cloudflare\API\Endpoints\Crypto($mock); + $cryptoMock = new Crypto($mock); $result = $cryptoMock->getOpportunisticEncryptionSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('off', $result); @@ -25,7 +28,7 @@ public function testGetOnionRoutingSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getOnionRoutingSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -34,7 +37,7 @@ public function testGetOnionRoutingSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/opportunistic_onion') ); - $cryptoMock = new \Cloudflare\API\Endpoints\Crypto($mock); + $cryptoMock = new Crypto($mock); $result = $cryptoMock->getOnionRoutingSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('off', $result); @@ -44,7 +47,7 @@ public function testUpdateOpportunisticEncryptionSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateOpportunisticEncryptionSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -54,7 +57,7 @@ public function testUpdateOpportunisticEncryptionSetting() $this->equalTo(['value' => 'off']) ); - $cryptoMock = new \Cloudflare\API\Endpoints\Crypto($mock); + $cryptoMock = new Crypto($mock); $result = $cryptoMock->updateOpportunisticEncryptionSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'off'); $this->assertTrue($result); @@ -64,7 +67,7 @@ public function testUpdateOnionRoutingSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateOnionRoutingSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -74,7 +77,7 @@ public function testUpdateOnionRoutingSetting() $this->equalTo(['value' => 'off']) ); - $cryptoMock = new \Cloudflare\API\Endpoints\Crypto($mock); + $cryptoMock = new Crypto($mock); $result = $cryptoMock->updateOnionRoutingSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'off'); $this->assertTrue($result); diff --git a/tests/Endpoints/CustomHostnamesTest.php b/tests/Endpoints/CustomHostnamesTest.php index f8cf990b..6a6f749a 100644 --- a/tests/Endpoints/CustomHostnamesTest.php +++ b/tests/Endpoints/CustomHostnamesTest.php @@ -6,6 +6,7 @@ * Time: 22:23 */ +use Cloudflare\API\Adapter\Adapter; use Cloudflare\API\Endpoints\CustomHostnames; class CustomHostnamesTest extends TestCase @@ -16,7 +17,7 @@ public function testAddHostname() $customSsl = $this->getCustomSsl(); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -67,7 +68,7 @@ public function testListHostnames() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listHostnames.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -85,11 +86,11 @@ public function testListHostnames() ]) ); - $zones = new \Cloudflare\API\Endpoints\CustomHostnames($mock); + $zones = new CustomHostnames($mock); $result = $zones->listHostnames('023e105f4ecef8ad9ca31a8372d0c353', 'app.example.com', '0d89c70d-ad9f-4843-b99f-6cc0252067e9', 1, 20, 'ssl', 'desc', 0); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('0d89c70d-ad9f-4843-b99f-6cc0252067e9', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -100,7 +101,7 @@ public function testGetHostname() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getHostname.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -109,11 +110,11 @@ public function testGetHostname() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/custom_hostnames/0d89c70d-ad9f-4843-b99f-6cc0252067e9') ); - $zones = new \Cloudflare\API\Endpoints\CustomHostnames($mock); + $zones = new CustomHostnames($mock); $result = $zones->getHostname('023e105f4ecef8ad9ca31a8372d0c353', '0d89c70d-ad9f-4843-b99f-6cc0252067e9', '0d89c70d-ad9f-4843-b99f-6cc0252067e9'); - $this->assertObjectHasAttribute('id', $result); - $this->assertObjectHasAttribute('hostname', $result); + $this->assertObjectHasProperty('id', $result); + $this->assertObjectHasProperty('hostname', $result); $this->assertEquals('0d89c70d-ad9f-4843-b99f-6cc0252067e9', $zones->getBody()->result->id); } @@ -123,7 +124,7 @@ public function testUpdateHostname() $customSsl = $this->getCustomSsl(); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -149,7 +150,7 @@ public function testUpdateHostname() ]) ); - $zones = new \Cloudflare\API\Endpoints\CustomHostnames($mock); + $zones = new CustomHostnames($mock); $sslSettings = [ 'http2' => 'on', 'http3' => 'on', @@ -171,8 +172,8 @@ public function testUpdateHostname() ] ); - $this->assertObjectHasAttribute('id', $result); - $this->assertObjectHasAttribute('hostname', $result); + $this->assertObjectHasProperty('id', $result); + $this->assertObjectHasProperty('hostname', $result); $this->assertEquals('0d89c70d-ad9f-4843-b99f-6cc0252067e9', $zones->getBody()->result->id); } @@ -180,7 +181,7 @@ public function testDeleteHostname() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteHostname.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -189,7 +190,7 @@ public function testDeleteHostname() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/custom_hostnames/0d89c70d-ad9f-4843-b99f-6cc0252067e9') ); - $zones = new \Cloudflare\API\Endpoints\CustomHostnames($mock); + $zones = new CustomHostnames($mock); $result = $zones->deleteHostname('023e105f4ecef8ad9ca31a8372d0c353', '0d89c70d-ad9f-4843-b99f-6cc0252067e9'); $this->assertEquals('0d89c70d-ad9f-4843-b99f-6cc0252067e9', $result->id); @@ -200,7 +201,7 @@ public function testGetHostnameFallbackOrigin() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getCustomHostnameFallbackOrigin.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -209,11 +210,11 @@ public function testGetHostnameFallbackOrigin() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/custom_hostnames/fallback_origin') ); - $zones = new \Cloudflare\API\Endpoints\CustomHostnames($mock); + $zones = new CustomHostnames($mock); $result = $zones->getFallbackOrigin('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('origin', $result); - $this->assertObjectHasAttribute('status', $result); + $this->assertObjectHasProperty('origin', $result); + $this->assertObjectHasProperty('status', $result); } private function getCustomSsl(): array diff --git a/tests/Endpoints/DNSAnalyticsTest.php b/tests/Endpoints/DNSAnalyticsTest.php index 6d0a64eb..ea3ca8fa 100644 --- a/tests/Endpoints/DNSAnalyticsTest.php +++ b/tests/Endpoints/DNSAnalyticsTest.php @@ -1,5 +1,8 @@ getMockBuilder( - \Cloudflare\API\Adapter\Adapter::class - )->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock @@ -28,7 +29,7 @@ public function testGetDNSAnalyticsReportTable() ) ); - $analytics = new \Cloudflare\API\Endpoints\DNSAnalytics($mock); + $analytics = new DNSAnalytics($mock); $since = '2020-02-01T00:00:00Z'; $until = '2020-02-28T23:59:59Z'; $filters = 'responseCode==NOERROR AND queryType==A'; @@ -54,9 +55,7 @@ public function testGetDNSAnalyticsReportByTime() 'Endpoints/getDNSAnalyticsReportByTime.json' ); - $mock = $this->getMockBuilder( - \Cloudflare\API\Adapter\Adapter::class - )->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock @@ -68,7 +67,7 @@ public function testGetDNSAnalyticsReportByTime() ) ); - $analytics = new \Cloudflare\API\Endpoints\DNSAnalytics($mock); + $analytics = new DNSAnalytics($mock); $since = '2020-02-01T00:00:00Z'; $until = '2020-02-28T23:59:59Z'; $filters = 'responseCode==NOERROR AND queryType==A'; diff --git a/tests/Endpoints/DNSTest.php b/tests/Endpoints/DNSTest.php index 2eec5536..1a85187e 100644 --- a/tests/Endpoints/DNSTest.php +++ b/tests/Endpoints/DNSTest.php @@ -1,5 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/addRecord.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -28,7 +31,7 @@ public function testAddRecord() ]) ); - $dns = new \Cloudflare\API\Endpoints\DNS($mock); + $dns = new DNS($mock); $dns->addRecord('023e105f4ecef8ad9ca31a8372d0c353', 'A', 'example.com', '127.0.0.1', '120', false); } @@ -36,7 +39,7 @@ public function testAddMXRecordPriority10() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/addRecord.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -53,7 +56,7 @@ public function testAddMXRecordPriority10() ]) ); - $dns = new \Cloudflare\API\Endpoints\DNS($mock); + $dns = new DNS($mock); $dns->addRecord('023e105f4ecef8ad9ca31a8372d0c353', 'MX', 'example.com', '127.0.0.1', '120', false, 10); } @@ -61,7 +64,7 @@ public function testAddMXRecordPriority0() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/addRecord.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -78,7 +81,7 @@ public function testAddMXRecordPriority0() ]) ); - $dns = new \Cloudflare\API\Endpoints\DNS($mock); + $dns = new DNS($mock); $dns->addRecord('023e105f4ecef8ad9ca31a8372d0c353', 'MX', 'example.com', '127.0.0.1', '120', false, 0); } @@ -87,7 +90,7 @@ public function testListRecords() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listRecords.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -106,11 +109,11 @@ public function testListRecords() ]) ); - $zones = new \Cloudflare\API\Endpoints\DNS($mock); + $zones = new DNS($mock); $result = $zones->listRecords('023e105f4ecef8ad9ca31a8372d0c353', 'A', 'example.com', '127.0.0.1', 1, 20, 'type', 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -121,7 +124,7 @@ public function testGetDNSRecordDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getDNSRecordDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -130,7 +133,7 @@ public function testGetDNSRecordDetails() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/dns_records/372e67954025e0ba6aaa6d586b9e0b59') ); - $dns = new \Cloudflare\API\Endpoints\DNS($mock); + $dns = new DNS($mock); $result = $dns->getRecordDetails('023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59'); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->id); @@ -141,7 +144,7 @@ public function testGetRecordID() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getRecordId.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -150,7 +153,7 @@ public function testGetRecordID() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/dns_records') ); - $dns = new \Cloudflare\API\Endpoints\DNS($mock); + $dns = new DNS($mock); $result = $dns->getRecordID('023e105f4ecef8ad9ca31a8372d0c353', 'A', 'example.com'); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result); @@ -160,7 +163,7 @@ public function testUpdateDNSRecord() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateDNSRecord.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $details = [ @@ -178,7 +181,7 @@ public function testUpdateDNSRecord() $this->equalTo($details) ); - $dns = new \Cloudflare\API\Endpoints\DNS($mock); + $dns = new DNS($mock); $result = $dns->updateRecordDetails('023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59', $details); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->result->id); diff --git a/tests/Endpoints/FirewallSettingsTest.php b/tests/Endpoints/FirewallSettingsTest.php index b8bc289e..d136bd0b 100644 --- a/tests/Endpoints/FirewallSettingsTest.php +++ b/tests/Endpoints/FirewallSettingsTest.php @@ -1,12 +1,14 @@ getPsr7JsonResponseForFixture('Endpoints/getSecurityLevelSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -15,7 +17,7 @@ public function testGetSecurityLevelSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/security_level') ); - $firewallSettingsMock = new \Cloudflare\API\Endpoints\FirewallSettings($mock); + $firewallSettingsMock = new FirewallSettings($mock); $result = $firewallSettingsMock->getSecurityLevelSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('medium', $result); @@ -25,7 +27,7 @@ public function testGetChallengeTTLSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getChallengeTTLSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -34,7 +36,7 @@ public function testGetChallengeTTLSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/challenge_ttl') ); - $firewallSettingsMock = new \Cloudflare\API\Endpoints\FirewallSettings($mock); + $firewallSettingsMock = new FirewallSettings($mock); $result = $firewallSettingsMock->getChallengeTTLSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals(1800, $result); @@ -44,7 +46,7 @@ public function testGetBrowserIntegrityCheckSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getBrowserIntegrityCheckSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -53,7 +55,7 @@ public function testGetBrowserIntegrityCheckSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/browser_check') ); - $firewallSettingsMock = new \Cloudflare\API\Endpoints\FirewallSettings($mock); + $firewallSettingsMock = new FirewallSettings($mock); $result = $firewallSettingsMock->getBrowserIntegrityCheckSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('on', $result); @@ -63,7 +65,7 @@ public function testUpdateSecurityLevelSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateSecurityLevelSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -73,7 +75,7 @@ public function testUpdateSecurityLevelSetting() $this->equalTo(['value' => 'medium']) ); - $firewallSettingsMock = new \Cloudflare\API\Endpoints\FirewallSettings($mock); + $firewallSettingsMock = new FirewallSettings($mock); $result = $firewallSettingsMock->updateSecurityLevelSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'medium'); $this->assertTrue($result); @@ -83,7 +85,7 @@ public function testUpdateChallengeTTLSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateChallengeTTLSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -93,7 +95,7 @@ public function testUpdateChallengeTTLSetting() $this->equalTo(['value' => 1800]) ); - $firewallSettingsMock = new \Cloudflare\API\Endpoints\FirewallSettings($mock); + $firewallSettingsMock = new FirewallSettings($mock); $result = $firewallSettingsMock->updateChallengeTTLSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 1800); $this->assertTrue($result); @@ -103,7 +105,7 @@ public function testUpdateBrowserIntegrityCheckSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateBrowserIntegrityCheckSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -113,7 +115,7 @@ public function testUpdateBrowserIntegrityCheckSetting() $this->equalTo(['value' => 'on']) ); - $firewallSettingsMock = new \Cloudflare\API\Endpoints\FirewallSettings($mock); + $firewallSettingsMock = new FirewallSettings($mock); $result = $firewallSettingsMock->updateBrowserIntegrityCheckSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'on'); $this->assertTrue($result); diff --git a/tests/Endpoints/FirewallTest.php b/tests/Endpoints/FirewallTest.php index c2b2ed6c..a1b50fb5 100644 --- a/tests/Endpoints/FirewallTest.php +++ b/tests/Endpoints/FirewallTest.php @@ -1,12 +1,16 @@ getPsr7JsonResponseForFixture('Endpoints/createFirewallRules.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -33,7 +37,7 @@ public function testCreatePageRules() ]) ); - $firewall = new Cloudflare\API\Endpoints\Firewall($mock); + $firewall = new Firewall($mock); $result = $firewall->createFirewallRules( '023e105f4ecef8ad9ca31a8372d0c353', [ @@ -62,7 +66,7 @@ public function testCreatePageRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/createFirewallRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -82,8 +86,8 @@ public function testCreatePageRule() ]) ); - $firewall = new Cloudflare\API\Endpoints\Firewall($mock); - $options = new \Cloudflare\API\Configurations\FirewallRuleOptions(); + $firewall = new Firewall($mock); + $options = new FirewallRuleOptions(); $options->setActionBlock(); $result = $firewall->createFirewallRule( '023e105f4ecef8ad9ca31a8372d0c353', @@ -98,7 +102,7 @@ public function testListFirewallRules() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listFirewallRules.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -111,11 +115,11 @@ public function testListFirewallRules() ]) ); - $firewall = new Cloudflare\API\Endpoints\Firewall($mock); + $firewall = new Firewall($mock); $result = $firewall->listFirewallRules('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('970b10321e3f4adda674c912b5f76591', $result->result[0]->id); } @@ -124,7 +128,7 @@ public function testDeleteFirewallRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteFirewallRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -133,7 +137,7 @@ public function testDeleteFirewallRule() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/rules/970b10321e3f4adda674c912b5f76591') ); - $firewall = new Cloudflare\API\Endpoints\Firewall($mock); + $firewall = new Firewall($mock); $firewall->deleteFirewallRule('023e105f4ecef8ad9ca31a8372d0c353', '970b10321e3f4adda674c912b5f76591'); } @@ -141,7 +145,7 @@ public function testUpdateFirewallRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateFirewallRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -161,8 +165,8 @@ public function testUpdateFirewallRule() ]) ); - $firewall = new Cloudflare\API\Endpoints\Firewall($mock); - $options = new \Cloudflare\API\Configurations\FirewallRuleOptions(); + $firewall = new Firewall($mock); + $options = new FirewallRuleOptions(); $options->setActionBlock(); $result = $firewall->updateFirewallRule( '023e105f4ecef8ad9ca31a8372d0c353', diff --git a/tests/Endpoints/IPsTest.php b/tests/Endpoints/IPsTest.php index 1f92804b..b524b55b 100644 --- a/tests/Endpoints/IPsTest.php +++ b/tests/Endpoints/IPsTest.php @@ -1,4 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/listIPs.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -21,11 +25,11 @@ public function testListIPs() $this->equalTo('ips') ); - $ipsMock = new \Cloudflare\API\Endpoints\IPs($mock); + $ipsMock = new IPs($mock); $ips = $ipsMock->listIPs(); - $this->assertObjectHasAttribute('ipv4_cidrs', $ips); - $this->assertObjectHasAttribute('ipv6_cidrs', $ips); - $this->assertObjectHasAttribute('ipv4_cidrs', $ipsMock->getBody()->result); - $this->assertObjectHasAttribute('ipv6_cidrs', $ipsMock->getBody()->result); + $this->assertObjectHasProperty('ipv4_cidrs', $ips); + $this->assertObjectHasProperty('ipv6_cidrs', $ips); + $this->assertObjectHasProperty('ipv4_cidrs', $ipsMock->getBody()->result); + $this->assertObjectHasProperty('ipv6_cidrs', $ipsMock->getBody()->result); } } diff --git a/tests/Endpoints/LoadBalancersTest.php b/tests/Endpoints/LoadBalancersTest.php index 93418d43..46a11287 100644 --- a/tests/Endpoints/LoadBalancersTest.php +++ b/tests/Endpoints/LoadBalancersTest.php @@ -24,7 +24,7 @@ public function testCreateLoadBalancer() $response = $this->getPsr7JsonResponseForFixture('Endpoints/createLoadBalancer.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -45,7 +45,7 @@ public function testListLoadBalancer() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listLoadBalancers.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -63,7 +63,7 @@ public function testGetLoadBalancerDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getLoadBalancerDetails.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -89,7 +89,7 @@ public function testUpdateLoadBalancer() $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateLoadBalancer.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -110,7 +110,7 @@ public function testDeleteLoadBalancer() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteLoadBalancer.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) diff --git a/tests/Endpoints/MembershipTest.php b/tests/Endpoints/MembershipTest.php index 3f93c1e4..c542094d 100644 --- a/tests/Endpoints/MembershipTest.php +++ b/tests/Endpoints/MembershipTest.php @@ -1,13 +1,16 @@ getPsr7JsonResponseForFixture('Endpoints/listMemberships.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -24,11 +27,11 @@ public function testListMemberships() ]) ); - $zones = new \Cloudflare\API\Endpoints\Membership($mock); + $zones = new Membership($mock); $result = $zones->listMemberships('Demo Account', 'accepted', 1, 20, 'status', 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('4536bcfad5faccb111b47003c79917fa', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -39,15 +42,15 @@ public function testGetMembershipDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getMembershipDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); - $membership = new \Cloudflare\API\Endpoints\Membership($mock); + $membership = new Membership($mock); $details = $membership->getMembershipDetails('4536bcfad5faccb111b47003c79917fa'); - $this->assertObjectHasAttribute('id', $details); + $this->assertObjectHasProperty('id', $details); $this->assertEquals('4536bcfad5faccb111b47003c79917fa', $details->id); - $this->assertObjectHasAttribute('code', $details); + $this->assertObjectHasProperty('code', $details); $this->assertEquals('05dd05cce12bbed97c0d87cd78e89bc2fd41a6cee72f27f6fc84af2e45c0fac0', $details->code); $this->assertEquals('4536bcfad5faccb111b47003c79917fa', $membership->getBody()->result->id); } @@ -56,7 +59,7 @@ public function testUpdateMembershipDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateMembershipStatus.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -68,7 +71,7 @@ public function testUpdateMembershipDetails() ]) ); - $membership = new \Cloudflare\API\Endpoints\Membership($mock); + $membership = new Membership($mock); $membership->updateMembershipStatus('4536bcfad5faccb111b47003c79917fa', 'accepted'); $this->assertEquals('4536bcfad5faccb111b47003c79917fa', $membership->getBody()->result->id); } @@ -77,14 +80,14 @@ public function testDeleteMembership() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteMembership.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) ->method('delete') ->with($this->equalTo('memberships/4536bcfad5faccb111b47003c79917fa')); - $membership = new \Cloudflare\API\Endpoints\Membership($mock); + $membership = new Membership($mock); $membership->deleteMembership('4536bcfad5faccb111b47003c79917fa'); diff --git a/tests/Endpoints/PageRulesTest.php b/tests/Endpoints/PageRulesTest.php index f16815ab..9b319b44 100644 --- a/tests/Endpoints/PageRulesTest.php +++ b/tests/Endpoints/PageRulesTest.php @@ -1,4 +1,10 @@ setAlwaysOnline(true); $response = $this->getPsr7JsonResponseForFixture('Endpoints/createPageRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -31,7 +37,7 @@ public function testCreatePageRule() ]) ); - $pageRules = new \Cloudflare\API\Endpoints\PageRules($mock); + $pageRules = new PageRules($mock); $result = $pageRules->createPageRule('023e105f4ecef8ad9ca31a8372d0c353', $target, $action, true, 1); $this->assertTrue($result); @@ -42,7 +48,7 @@ public function testListPageRules() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listPageRules.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -57,7 +63,7 @@ public function testListPageRules() ]) ); - $pageRules = new \Cloudflare\API\Endpoints\PageRules($mock); + $pageRules = new PageRules($mock); $pageRules->listPageRules('023e105f4ecef8ad9ca31a8372d0c353', 'active', 'status', 'desc', 'all'); $this->assertEquals('9a7806061c88ada191ed06f989cc3dac', $pageRules->getBody()->result[0]->id); } @@ -66,7 +72,7 @@ public function testGetPageRuleDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getPageRuleDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -75,20 +81,20 @@ public function testGetPageRuleDetails() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/pagerules/9a7806061c88ada191ed06f989cc3dac') ); - $pageRules = new \Cloudflare\API\Endpoints\PageRules($mock); + $pageRules = new PageRules($mock); $pageRules->getPageRuleDetails('023e105f4ecef8ad9ca31a8372d0c353', '9a7806061c88ada191ed06f989cc3dac'); $this->assertEquals('9a7806061c88ada191ed06f989cc3dac', $pageRules->getBody()->result->id); } public function testUpdatePageRule() { - $target = new \Cloudflare\API\Configurations\PageRulesTargets('*example.com/images/*'); - $action = new \Cloudflare\API\Configurations\PageRulesActions(); + $target = new PageRulesTargets('*example.com/images/*'); + $action = new PageRulesActions(); $action->setAlwaysOnline(true); $response = $this->getPsr7JsonResponseForFixture('Endpoints/updatePageRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -103,7 +109,7 @@ public function testUpdatePageRule() ]) ); - $pageRules = new \Cloudflare\API\Endpoints\PageRules($mock); + $pageRules = new PageRules($mock); $result = $pageRules->updatePageRule('023e105f4ecef8ad9ca31a8372d0c353', '9a7806061c88ada191ed06f989cc3dac', $target, $action, true, 1); $this->assertTrue($result); @@ -114,7 +120,7 @@ public function testDeletePageRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deletePageRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -123,7 +129,7 @@ public function testDeletePageRule() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/pagerules/9a7806061c88ada191ed06f989cc3dac') ); - $pageRules = new \Cloudflare\API\Endpoints\PageRules($mock); + $pageRules = new PageRules($mock); $result = $pageRules->deletePageRule('023e105f4ecef8ad9ca31a8372d0c353', '9a7806061c88ada191ed06f989cc3dac'); $this->assertTrue($result); diff --git a/tests/Endpoints/PoolsTest.php b/tests/Endpoints/PoolsTest.php index 9846f48a..7891296a 100644 --- a/tests/Endpoints/PoolsTest.php +++ b/tests/Endpoints/PoolsTest.php @@ -2,6 +2,7 @@ use Cloudflare\API\Adapter\Adapter; use Cloudflare\API\Endpoints\Pools; +use Cloudflare\API\Configurations\Pool; /** * @author Martijn Smidt @@ -22,11 +23,11 @@ public function testCreatePool() ] ]; - $poolConfiguration = new \Cloudflare\API\Configurations\Pool('primary-dc-1', $origins); + $poolConfiguration = new Pool('primary-dc-1', $origins); $response = $this->getPsr7JsonResponseForFixture('Endpoints/createPool.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -47,7 +48,7 @@ public function testListPools() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listPools.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -65,7 +66,7 @@ public function testGetPoolDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getPoolDetails.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -90,11 +91,11 @@ public function testUpdatePool() ] ]; - $poolConfiguration = new \Cloudflare\API\Configurations\Pool('primary-dc-1', $origins); + $poolConfiguration = new Pool('primary-dc-1', $origins); $response = $this->getPsr7JsonResponseForFixture('Endpoints/updatePool.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -115,7 +116,7 @@ public function testDeletePool() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deletePool.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) diff --git a/tests/Endpoints/RailgunTest.php b/tests/Endpoints/RailgunTest.php index 15e210b1..d1011a71 100644 --- a/tests/Endpoints/RailgunTest.php +++ b/tests/Endpoints/RailgunTest.php @@ -1,4 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/createRailgun.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -26,10 +30,10 @@ public function testcreate() $this->equalTo(['name' => $details['name']]) ); - $railgun = new \Cloudflare\API\Endpoints\Railgun($mock); + $railgun = new Railgun($mock); $result = $railgun->create($details['name']); - $this->assertObjectHasAttribute('result', $result); + $this->assertObjectHasProperty('result', $result); foreach ($details as $property => $value) { $this->assertEquals($result->result->{ $property }, $value); @@ -41,7 +45,7 @@ public function testlist() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listRailguns.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -55,11 +59,11 @@ public function testlist() ]) ); - $railgun = new \Cloudflare\API\Endpoints\Railgun($mock); + $railgun = new Railgun($mock); $result = $railgun->list(1, 20, 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('e928d310693a83094309acf9ead50448', $railgun->getBody()->result[0]->id); } @@ -67,7 +71,7 @@ public function testget() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getRailgun.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -76,7 +80,7 @@ public function testget() $this->equalTo('railguns/e928d310693a83094309acf9ead50448') ); - $railgun = new \Cloudflare\API\Endpoints\Railgun($mock); + $railgun = new Railgun($mock); $result = $railgun->get('e928d310693a83094309acf9ead50448'); $this->assertEquals('e928d310693a83094309acf9ead50448', $result->id); @@ -87,7 +91,7 @@ public function testgetZones() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listRailgunZones.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -96,11 +100,11 @@ public function testgetZones() $this->equalTo('railguns/e928d310693a83094309acf9ead50448/zones') ); - $railgun = new \Cloudflare\API\Endpoints\Railgun($mock); + $railgun = new Railgun($mock); $result = $railgun->getZones('e928d310693a83094309acf9ead50448'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('023e105f4ecef8ad9ca31a8372d0c353', $railgun->getBody()->result[0]->id); } @@ -108,7 +112,7 @@ public function testupdate() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateRailgun.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $details = [ @@ -122,7 +126,7 @@ public function testupdate() $this->equalTo($details) ); - $waf = new \Cloudflare\API\Endpoints\Railgun($mock); + $waf = new Railgun($mock); $result = $waf->update('e928d310693a83094309acf9ead50448', true); $this->assertEquals('e928d310693a83094309acf9ead50448', $result->id); @@ -133,7 +137,7 @@ public function testdelete() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteRailgun.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -142,7 +146,7 @@ public function testdelete() $this->equalTo('railguns/e928d310693a83094309acf9ead50448') ); - $waf = new \Cloudflare\API\Endpoints\Railgun($mock); + $waf = new Railgun($mock); $waf->delete('e928d310693a83094309acf9ead50448'); $this->assertEquals('e928d310693a83094309acf9ead50448', $waf->getBody()->result->id); } diff --git a/tests/Endpoints/SSLTest.php b/tests/Endpoints/SSLTest.php index c2a1b401..e6c05ca7 100644 --- a/tests/Endpoints/SSLTest.php +++ b/tests/Endpoints/SSLTest.php @@ -1,12 +1,15 @@ getPsr7JsonResponseForFixture('Endpoints/getSSLSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -15,7 +18,7 @@ public function testGetSSLSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/ssl') ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->getSSLSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('off', $result); @@ -25,7 +28,7 @@ public function testGetSSLVerificationStatus() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getSSLVerificationStatus.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -34,10 +37,10 @@ public function testGetSSLVerificationStatus() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/ssl/verification') ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->getSSLVerificationStatus('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); - $this->assertObjectHasAttribute('result', $result); + $this->assertObjectHasProperty('result', $result); $this->assertEquals('active', $result->result[0]->certificate_status); } @@ -45,7 +48,7 @@ public function testGetHTTPSRedirectSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getHTTPSRedirectSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -54,7 +57,7 @@ public function testGetHTTPSRedirectSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/always_use_https') ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->getHTTPSRedirectSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('off', $result); @@ -64,7 +67,7 @@ public function testGetHTTPSRewritesSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getHTTPSRewritesSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -73,7 +76,7 @@ public function testGetHTTPSRewritesSetting() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/automatic_https_rewrites') ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->getHTTPSRewritesSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('off', $result); @@ -83,7 +86,7 @@ public function testUpdateSSLSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateSSLSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -93,7 +96,7 @@ public function testUpdateSSLSetting() $this->equalTo(['value' => 'full']) ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->updateSSLSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'full'); $this->assertTrue($result); @@ -103,7 +106,7 @@ public function testUpdateHTTPSRedirectSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateHTTPSRedirectSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -113,7 +116,7 @@ public function testUpdateHTTPSRedirectSetting() $this->equalTo(['value' => 'off']) ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->updateHTTPSRedirectSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'off'); $this->assertTrue($result); @@ -123,7 +126,7 @@ public function testUpdateHTTPSRewritesSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateHTTPSRewritesSetting.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -133,7 +136,7 @@ public function testUpdateHTTPSRewritesSetting() $this->equalTo(['value' => 'off']) ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->updateHTTPSRewritesSetting('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'off'); $this->assertTrue($result); @@ -143,7 +146,7 @@ public function testUpdateSSLCertificatePackValidationMethod() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateSSLCertificatePackValidationMethod.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -153,7 +156,7 @@ public function testUpdateSSLCertificatePackValidationMethod() $this->equalTo(['validation_method' => 'txt']) ); - $sslMock = new \Cloudflare\API\Endpoints\SSL($mock); + $sslMock = new SSL($mock); $result = $sslMock->updateSSLCertificatePackValidationMethod('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'a77f8bd7-3b47-46b4-a6f1-75cf98109948', 'txt'); $this->assertTrue($result); diff --git a/tests/Endpoints/TLSTest.php b/tests/Endpoints/TLSTest.php index cf0018c5..7a33744e 100644 --- a/tests/Endpoints/TLSTest.php +++ b/tests/Endpoints/TLSTest.php @@ -1,5 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/getTLSClientAuth.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -22,7 +25,7 @@ public function testGetTLSClientAuth() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/settings/tls_client_auth') ); - $tlsMock = new \Cloudflare\API\Endpoints\TLS($mock); + $tlsMock = new TLS($mock); $result = $tlsMock->getTLSClientAuth('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertEquals('off', $result); @@ -32,7 +35,7 @@ public function testEnableTLS13() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/enableTLS13.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -42,7 +45,7 @@ public function testEnableTLS13() $this->equalTo(['value' => 'on']) ); - $tlsMock = new \Cloudflare\API\Endpoints\TLS($mock); + $tlsMock = new TLS($mock); $result = $tlsMock->enableTLS13('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', true); $this->assertTrue($result); @@ -52,7 +55,7 @@ public function testDisableTLS13() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/disableTLS13.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -62,7 +65,7 @@ public function testDisableTLS13() $this->equalTo(['value' => 'off']) ); - $tlsMock = new \Cloudflare\API\Endpoints\TLS($mock); + $tlsMock = new TLS($mock); $result = $tlsMock->disableTLS13('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', true); $this->assertTrue($result); @@ -72,7 +75,7 @@ public function testChangeMinimimTLSVersion() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/changeMinimumTLSVersion.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -82,7 +85,7 @@ public function testChangeMinimimTLSVersion() $this->equalTo(['value' => '1.1']) ); - $tlsMock = new \Cloudflare\API\Endpoints\TLS($mock); + $tlsMock = new TLS($mock); $result = $tlsMock->changeMinimumTLSVersion('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', '1.1'); $this->assertTrue($result); @@ -92,7 +95,7 @@ public function testUpdateTLSClientAuth() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateTLSClientAuth.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -102,7 +105,7 @@ public function testUpdateTLSClientAuth() $this->equalTo(['value' => 'off']) ); - $tlsMock = new \Cloudflare\API\Endpoints\TLS($mock); + $tlsMock = new TLS($mock); $result = $tlsMock->updateTLSClientAuth('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', 'off'); $this->assertTrue($result); diff --git a/tests/Endpoints/UARulesTest.php b/tests/Endpoints/UARulesTest.php index 84067456..7db9642b 100644 --- a/tests/Endpoints/UARulesTest.php +++ b/tests/Endpoints/UARulesTest.php @@ -1,4 +1,9 @@ getPsr7JsonResponseForFixture('Endpoints/listRules.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -25,11 +30,11 @@ public function testListRules() ]) ); - $zones = new \Cloudflare\API\Endpoints\UARules($mock); + $zones = new UARules($mock); $result = $zones->listRules('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -38,12 +43,12 @@ public function testListRules() public function testCreateRule() { - $config = new \Cloudflare\API\Configurations\UARules(); + $config = new UARulesConfiguration(); $config->addUA('Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/603.2.4 (KHTML, like Gecko) Version/10.1.1 Safari/603.2.4'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/createRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -58,7 +63,7 @@ public function testCreateRule() ]) ); - $rules = new \Cloudflare\API\Endpoints\UARules($mock); + $rules = new UARules($mock); $rules->createRule( '023e105f4ecef8ad9ca31a8372d0c353', 'js_challenge', @@ -73,7 +78,7 @@ public function getRuleDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getRuleDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -82,7 +87,7 @@ public function getRuleDetails() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/ua_rules/372e67954025e0ba6aaa6d586b9e0b59') ); - $lockdown = new \Cloudflare\API\Endpoints\UARules($mock); + $lockdown = new UARules($mock); $result = $lockdown->getRuleDetails('023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59'); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->id); @@ -91,12 +96,12 @@ public function getRuleDetails() public function testUpdateRule() { - $config = new \Cloudflare\API\Configurations\UARules(); + $config = new UARulesConfiguration(); $config->addUA('Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_5) AppleWebKit/603.2.4 (KHTML, like Gecko) Version/10.1.1 Safari/603.2.4'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -111,7 +116,7 @@ public function testUpdateRule() ]) ); - $rules = new \Cloudflare\API\Endpoints\UARules($mock); + $rules = new UARules($mock); $rules->updateRule( '023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59', @@ -126,7 +131,7 @@ public function testDeleteRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -135,7 +140,7 @@ public function testDeleteRule() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/ua_rules/372e67954025e0ba6aaa6d586b9e0b59') ); - $rules = new \Cloudflare\API\Endpoints\UARules($mock); + $rules = new UARules($mock); $rules->deleteRule('023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59'); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $rules->getBody()->result->id); } diff --git a/tests/Endpoints/UserTest.php b/tests/Endpoints/UserTest.php index 07dc4248..e92a8164 100644 --- a/tests/Endpoints/UserTest.php +++ b/tests/Endpoints/UserTest.php @@ -1,5 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/getUserDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); - $user = new \Cloudflare\API\Endpoints\User($mock); + $user = new User($mock); $details = $user->getUserDetails(); - $this->assertObjectHasAttribute('id', $details); + $this->assertObjectHasProperty('id', $details); $this->assertEquals('7c5dae5552338874e5053f2534d2767a', $details->id); - $this->assertObjectHasAttribute('email', $details); + $this->assertObjectHasProperty('email', $details); $this->assertEquals('user@example.com', $details->email); $this->assertEquals('7c5dae5552338874e5053f2534d2767a', $user->getBody()->result->id); } @@ -28,10 +31,10 @@ public function testGetUserID() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getUserId.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); - $user = new \Cloudflare\API\Endpoints\User($mock); + $user = new User($mock); $this->assertEquals('7c5dae5552338874e5053f2534d2767a', $user->getUserID()); $this->assertEquals('7c5dae5552338874e5053f2534d2767a', $user->getBody()->result->id); } @@ -40,12 +43,12 @@ public function testGetUserEmail() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getUserEmail.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once())->method('get'); - $user = new \Cloudflare\API\Endpoints\User($mock); + $user = new User($mock); $this->assertEquals('user@example.com', $user->getUserEmail()); $this->assertEquals('user@example.com', $user->getBody()->result->email); } @@ -54,14 +57,14 @@ public function testUpdateUserDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateUserDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) ->method('patch') ->with($this->equalTo('user'), $this->equalTo(['email' => 'user2@example.com'])); - $user = new \Cloudflare\API\Endpoints\User($mock); + $user = new User($mock); $user->updateUserDetails(['email' => 'user2@example.com']); $this->assertEquals('7c5dae5552338874e5053f2534d2767a', $user->getBody()->result->id); } diff --git a/tests/Endpoints/WAFTest.php b/tests/Endpoints/WAFTest.php index f0c97aa9..0d244e53 100644 --- a/tests/Endpoints/WAFTest.php +++ b/tests/Endpoints/WAFTest.php @@ -1,4 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/listPackages.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -28,11 +32,11 @@ public function testgetPackages() ]) ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->getPackages('023e105f4ecef8ad9ca31a8372d0c353', 1, 20, 'status', 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('a25a9a7e9c00afc1fb2e0245519d725b', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -43,7 +47,7 @@ public function testgetPackageInfo() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getPackageInfo.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -52,7 +56,7 @@ public function testgetPackageInfo() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/waf/packages/a25a9a7e9c00afc1fb2e0245519d725b') ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->getPackageInfo('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b'); $this->assertEquals('a25a9a7e9c00afc1fb2e0245519d725b', $result->id); @@ -63,7 +67,7 @@ public function testgetRules() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listPackageRules.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -79,11 +83,11 @@ public function testgetRules() ]) ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->getRules('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b', 1, 20, 'status', 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('92f17202ed8bd63d69a66b86a49a8f6b', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -94,7 +98,7 @@ public function testgetRuleInfo() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getPackageRuleInfo.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -103,7 +107,7 @@ public function testgetRuleInfo() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/waf/packages/a25a9a7e9c00afc1fb2e0245519d725b/rules/f939de3be84e66e757adcdcb87908023') ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->getRuleInfo('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b', 'f939de3be84e66e757adcdcb87908023'); $this->assertEquals('f939de3be84e66e757adcdcb87908023', $result->id); @@ -114,7 +118,7 @@ public function testupdateRule() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updatePackageRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $details = [ @@ -128,7 +132,7 @@ public function testupdateRule() $this->equalTo($details) ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->updateRule('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b', 'f939de3be84e66e757adcdcb87908023', 'on'); $this->assertEquals('f939de3be84e66e757adcdcb87908023', $result->id); @@ -139,11 +143,11 @@ public function testupdateRule() $this->assertEquals('f939de3be84e66e757adcdcb87908023', $waf->getBody()->result->id); } - public function getGroups() + public function getGroups(): array { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listPackageGroups.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -159,11 +163,11 @@ public function getGroups() ]) ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->getGroups('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b', 1, 20, 'status', 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('de677e5818985db1285d0e80225f06e5', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -174,7 +178,7 @@ public function testgetGroupInfo() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getPackageGroupInfo.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -183,7 +187,7 @@ public function testgetGroupInfo() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/waf/packages/a25a9a7e9c00afc1fb2e0245519d725b/groups/de677e5818985db1285d0e80225f06e5') ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->getGroupInfo('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b', 'de677e5818985db1285d0e80225f06e5'); $this->assertEquals('de677e5818985db1285d0e80225f06e5', $result->id); @@ -194,7 +198,7 @@ public function testupdateGroup() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updatePackageGroup.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $details = [ @@ -208,7 +212,7 @@ public function testupdateGroup() $this->equalTo($details) ); - $waf = new \Cloudflare\API\Endpoints\WAF($mock); + $waf = new WAF($mock); $result = $waf->updateGroup('023e105f4ecef8ad9ca31a8372d0c353', 'a25a9a7e9c00afc1fb2e0245519d725b', 'de677e5818985db1285d0e80225f06e5', 'off'); $this->assertEquals('de677e5818985db1285d0e80225f06e5', $result->id); diff --git a/tests/Endpoints/ZoneCacheTest.php b/tests/Endpoints/ZoneCacheTest.php index bdefeeca..52b68554 100644 --- a/tests/Endpoints/ZoneCacheTest.php +++ b/tests/Endpoints/ZoneCacheTest.php @@ -1,12 +1,15 @@ getPsr7JsonResponseForFixture('Endpoints/cachePurgeEverything.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -16,7 +19,7 @@ public function testCachePurgeEverything() $this->equalTo(['purge_everything' => true]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->cachePurgeEverything('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertTrue($result); @@ -27,7 +30,7 @@ public function testCachePurgeHost() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/cachePurgeHost.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -43,7 +46,7 @@ public function testCachePurgeHost() ) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->cachePurge('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', [], [], ['dash.cloudflare.com']); $this->assertTrue($result); @@ -54,7 +57,7 @@ public function testCachePurge() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/cachePurge.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -67,7 +70,7 @@ public function testCachePurge() ]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->cachePurge('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', [ 'https://example.com/file.jpg', ]); diff --git a/tests/Endpoints/ZoneDeleteTest.php b/tests/Endpoints/ZoneDeleteTest.php index 5ffd4e1a..fb24499e 100644 --- a/tests/Endpoints/ZoneDeleteTest.php +++ b/tests/Endpoints/ZoneDeleteTest.php @@ -1,17 +1,21 @@ getPsr7JsonResponseForFixture('Endpoints/deleteZoneTest.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) ->method('delete') ->with( $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353') ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->deleteZone('023e105f4ecef8ad9ca31a8372d0c353'); $this->assertTrue($result); $this->assertEquals('9a7806061c88ada191ed06f989cc3dac', $zones->getBody()->result->id); diff --git a/tests/Endpoints/ZoneLockdownTest.php b/tests/Endpoints/ZoneLockdownTest.php index 2af55ac6..228349af 100644 --- a/tests/Endpoints/ZoneLockdownTest.php +++ b/tests/Endpoints/ZoneLockdownTest.php @@ -1,5 +1,9 @@ getPsr7JsonResponseForFixture('Endpoints/listLockdowns.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -25,11 +29,11 @@ public function testListLockdowns() ]) ); - $zones = new \Cloudflare\API\Endpoints\ZoneLockdown($mock); + $zones = new ZoneLockdown($mock); $result = $zones->listLockdowns('023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -38,12 +42,12 @@ public function testListLockdowns() public function testAddLockdown() { - $config = new \Cloudflare\API\Configurations\ZoneLockdown(); + $config = new ZoneLockdownConfiguration(); $config->addIP('1.2.3.4'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/addLockdown.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -58,7 +62,7 @@ public function testAddLockdown() ]) ); - $zoneLockdown = new \Cloudflare\API\Endpoints\ZoneLockdown($mock); + $zoneLockdown = new ZoneLockdown($mock); $zoneLockdown->createLockdown( '023e105f4ecef8ad9ca31a8372d0c353', ['api.mysite.com/some/endpoint*'], @@ -73,7 +77,7 @@ public function testGetRecordDetails() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getRecordDetails.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -82,7 +86,7 @@ public function testGetRecordDetails() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/lockdowns/372e67954025e0ba6aaa6d586b9e0b59') ); - $lockdown = new \Cloudflare\API\Endpoints\ZoneLockdown($mock); + $lockdown = new ZoneLockdown($mock); $result = $lockdown->getLockdownDetails('023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59'); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $result->id); @@ -91,12 +95,12 @@ public function testGetRecordDetails() public function testUpdateLockdown() { - $config = new \Cloudflare\API\Configurations\ZoneLockdown(); + $config = new ZoneLockdownConfiguration(); $config->addIP('1.2.3.4'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateLockdown.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -111,7 +115,7 @@ public function testUpdateLockdown() ]) ); - $zoneLockdown = new \Cloudflare\API\Endpoints\ZoneLockdown($mock); + $zoneLockdown = new ZoneLockdown($mock); $zoneLockdown->updateLockdown( '023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59', @@ -124,12 +128,12 @@ public function testUpdateLockdown() public function testDeleteLockdown() { - $config = new \Cloudflare\API\Configurations\ZoneLockdown(); + $config = new ZoneLockdownConfiguration(); $config->addIP('1.2.3.4'); $response = $this->getPsr7JsonResponseForFixture('Endpoints/deleteLockdown.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('delete')->willReturn($response); $mock->expects($this->once()) @@ -138,7 +142,7 @@ public function testDeleteLockdown() $this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353/firewall/lockdowns/372e67954025e0ba6aaa6d586b9e0b59') ); - $zoneLockdown = new \Cloudflare\API\Endpoints\ZoneLockdown($mock); + $zoneLockdown = new ZoneLockdown($mock); $zoneLockdown->deleteLockdown('023e105f4ecef8ad9ca31a8372d0c353', '372e67954025e0ba6aaa6d586b9e0b59'); $this->assertEquals('372e67954025e0ba6aaa6d586b9e0b59', $zoneLockdown->getBody()->result->id); } diff --git a/tests/Endpoints/ZoneSettingsTest.php b/tests/Endpoints/ZoneSettingsTest.php index e4d2d8d6..3f3ba93e 100644 --- a/tests/Endpoints/ZoneSettingsTest.php +++ b/tests/Endpoints/ZoneSettingsTest.php @@ -11,7 +11,7 @@ public function testGetServerSideExcludeSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getServerSideExclude.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once())->method('get'); @@ -26,7 +26,7 @@ public function testUpdateServerSideExcludeSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateServerSideExclude.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once())->method('patch'); @@ -41,7 +41,7 @@ public function testGetBrowserCacheTtlSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getBrowserCacheTtlSetting.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once())->method('get'); @@ -56,7 +56,7 @@ public function testUpdateBrowserCacheTtlSetting() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/updateBrowserCacheTtlSetting.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once())->method('patch'); diff --git a/tests/Endpoints/ZoneSubscriptionsTest.php b/tests/Endpoints/ZoneSubscriptionsTest.php index bd4b7c45..8a81fa85 100644 --- a/tests/Endpoints/ZoneSubscriptionsTest.php +++ b/tests/Endpoints/ZoneSubscriptionsTest.php @@ -9,7 +9,7 @@ public function testListZoneSubscriptions() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listZoneSubscriptions.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -30,7 +30,7 @@ public function testAddZoneSubscriptionIfMissing() $postResponse = $this->getPsr7JsonResponseForFixture('Endpoints/createZoneSubscription.json'); $getResponse = $this->getPsr7JsonResponseForFixture('Endpoints/listEmptyZoneSubscriptions.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($postResponse); $mock->method('get')->willReturn($getResponse); @@ -57,7 +57,7 @@ public function testAddZoneSubscriptionIfExisting() $postResponse = $this->getPsr7JsonResponseForFixture('Endpoints/createZoneSubscription.json'); $getResponse = $this->getPsr7JsonResponseForFixture('Endpoints/listZoneSubscriptions.json'); - $mock = $this->getMockBuilder(Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($postResponse); $mock->method('get')->willReturn($getResponse); diff --git a/tests/Endpoints/ZonesTest.php b/tests/Endpoints/ZonesTest.php index b4412f78..9a807c9c 100644 --- a/tests/Endpoints/ZonesTest.php +++ b/tests/Endpoints/ZonesTest.php @@ -1,5 +1,8 @@ getPsr7JsonResponseForFixture('Endpoints/addZone.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -22,15 +25,15 @@ public function testAddZone() $this->equalTo(['name' => 'example.com', 'jump_start' => false]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->addZone('example.com'); - $this->assertObjectHasAttribute('id', $result); + $this->assertObjectHasProperty('id', $result); $this->assertEquals('023e105f4ecef8ad9ca31a8372d0c353', $result->id); $response = $this->getPsr7JsonResponseForFixture('Endpoints/createPageRule.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -46,7 +49,7 @@ public function testAddZone() ]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $zones->addZone('example.com', true, '01a7362d577a6c3019a474fd6f485823'); $this->assertEquals('9a7806061c88ada191ed06f989cc3dac', $zones->getBody()->result->id); } @@ -55,7 +58,7 @@ public function testAddZoneWithAccountId() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/addZone.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('post')->willReturn($response); $mock->expects($this->once()) @@ -71,10 +74,10 @@ public function testAddZoneWithAccountId() ]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->addZone('example.com', false, '023e105f4ecef8ad9ca31a8372d0c353'); - $this->assertObjectHasAttribute('id', $result); + $this->assertObjectHasProperty('id', $result); $this->assertEquals('023e105f4ecef8ad9ca31a8372d0c353', $result->account->id); } @@ -82,7 +85,7 @@ public function testActivationTest() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/activationTest.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('put')->willReturn($response); $mock->expects($this->once()) @@ -91,7 +94,7 @@ public function testActivationTest() $this->equalTo('zones/c2547eb745079dac9320b638f5e225cf483cc5cfdda41/activation_check') ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->activationCheck('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); $this->assertTrue($result); @@ -102,7 +105,7 @@ public function testListZones() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/listZones.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -120,11 +123,11 @@ public function testListZones() ]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->listZones('example.com', 'active', 1, 20, 'status', 'desc'); - $this->assertObjectHasAttribute('result', $result); - $this->assertObjectHasAttribute('result_info', $result); + $this->assertObjectHasProperty('result', $result); + $this->assertObjectHasProperty('result_info', $result); $this->assertEquals('023e105f4ecef8ad9ca31a8372d0c353', $result->result[0]->id); $this->assertEquals(1, $result->result_info->page); @@ -135,14 +138,14 @@ public function testGetZoneByID() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getZoneById.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) ->method('get') ->with($this->equalTo('zones/023e105f4ecef8ad9ca31a8372d0c353')); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->getZoneById('023e105f4ecef8ad9ca31a8372d0c353'); $this->assertInstanceOf(\stdClass::class, $result); @@ -154,7 +157,7 @@ public function testGetZoneID() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getZoneId.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -169,7 +172,7 @@ public function testGetZoneID() ]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->getZoneID('example.com'); $this->assertEquals('023e105f4ecef8ad9ca31a8372d0c353', $result); @@ -180,7 +183,7 @@ public function testGetAnalyticsDashboard() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/getAnalyticsDashboard.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('get')->willReturn($response); $mock->expects($this->once()) @@ -190,18 +193,18 @@ public function testGetAnalyticsDashboard() $this->equalTo(['since' => '-10080', 'until' => '0', 'continuous' => var_export(true, true)]) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $analytics = $zones->getAnalyticsDashboard('c2547eb745079dac9320b638f5e225cf483cc5cfdda41'); - $this->assertObjectHasAttribute('since', $analytics->totals); - $this->assertObjectHasAttribute('since', $analytics->timeseries[0]); + $this->assertObjectHasProperty('since', $analytics->totals); + $this->assertObjectHasProperty('since', $analytics->timeseries[0]); } public function testChangeDevelopmentMode() { $response = $this->getPsr7JsonResponseForFixture('Endpoints/changeDevelopmentMode.json'); - $mock = $this->getMockBuilder(\Cloudflare\API\Adapter\Adapter::class)->getMock(); + $mock = $this->getMockBuilder(Adapter::class)->disableOriginalConstructor()->getMock(); $mock->method('patch')->willReturn($response); $mock->expects($this->once()) @@ -211,7 +214,7 @@ public function testChangeDevelopmentMode() $this->equalTo(['value' => 'on']) ); - $zones = new \Cloudflare\API\Endpoints\Zones($mock); + $zones = new Zones($mock); $result = $zones->changeDevelopmentMode('c2547eb745079dac9320b638f5e225cf483cc5cfdda41', true); $this->assertTrue($result); diff --git a/tests/TestCase.php b/tests/TestCase.php index 418bc92b..7508a0b6 100644 --- a/tests/TestCase.php +++ b/tests/TestCase.php @@ -12,7 +12,9 @@ abstract class TestCase extends BaseTestCase * Returns a PSR7 Stream for a given fixture. * * @param string $fixture The fixture to create the stream for. + * * @return Psr7\Stream + * @SuppressWarnings(PHPMD.StaticAccess) */ protected function getPsr7StreamForFixture($fixture): Psr7\Stream { @@ -20,7 +22,7 @@ protected function getPsr7StreamForFixture($fixture): Psr7\Stream $this->assertFileExists($path); - $stream = Psr7\stream_for(file_get_contents($path)); + $stream = Psr7\Utils::streamFor(file_get_contents($path)); $this->assertInstanceOf(Psr7\Stream::class, $stream);