diff --git a/composer.json b/composer.json index 0f7b1ad..0c624ef 100644 --- a/composer.json +++ b/composer.json @@ -43,7 +43,8 @@ "laminas/laminas-console": "^2.8", "laminas/laminas-db": "^2.5", "doctrine/common": "^2.10", - "laminas/laminas-developer-tools": "^1.2.3" + "laminas/laminas-developer-tools": "^2.0", + "laminas-commons/lmc-user" : "^3.1" }, "suggests": { "laminas/laminas-developer-tools": "if you need to see current authorization details while developing", diff --git a/composer.lock b/composer.lock deleted file mode 100644 index 20db207..0000000 --- a/composer.lock +++ /dev/null @@ -1,3838 +0,0 @@ -{ - "_readme": [ - "This file locks the dependencies of your project to a known state", - "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", - "This file is @generated automatically" - ], - "content-hash": "c9167c22d26792d5128aba2a8dfabaf3", - "packages": [ - { - "name": "container-interop/container-interop", - "version": "1.2.0", - "source": { - "type": "git", - "url": "https://github.com/container-interop/container-interop.git", - "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/container-interop/container-interop/zipball/79cbf1341c22ec75643d841642dd5d6acd83bdb8", - "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8", - "shasum": "" - }, - "require": { - "psr/container": "^1.0" - }, - "type": "library", - "autoload": { - "psr-4": { - "Interop\\Container\\": "src/Interop/Container/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", - "homepage": "https://github.com/container-interop/container-interop", - "abandoned": "psr/container", - "time": "2017-02-14T19:40:03+00:00" - }, - { - "name": "laminas/laminas-authentication", - "version": "2.7.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-authentication.git", - "reference": "53505e07858d243792b96be763456f786d953501" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/53505e07858d243792b96be763456f786d953501", - "reference": "53505e07858d243792b96be763456f786d953501", - "shasum": "" - }, - "require": { - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-authentication": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-crypt": "^2.6 || ^3.2.1", - "laminas/laminas-db": "^2.8.2", - "laminas/laminas-http": "^2.7", - "laminas/laminas-ldap": "^2.8", - "laminas/laminas-session": "^2.8", - "laminas/laminas-uri": "^2.5.2", - "laminas/laminas-validator": "^2.10.1", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" - }, - "suggest": { - "laminas/laminas-crypt": "Laminas\\Crypt component", - "laminas/laminas-db": "Laminas\\Db component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-ldap": "Laminas\\Ldap component", - "laminas/laminas-session": "Laminas\\Session component", - "laminas/laminas-uri": "Laminas\\Uri component", - "laminas/laminas-validator": "Laminas\\Validator component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7.x-dev", - "dev-develop": "2.8.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Authentication\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides an API for authentication and includes concrete authentication adapters for common use case scenarios", - "homepage": "https://laminas.dev", - "keywords": [ - "Authentication", - "laminas" - ], - "time": "2019-12-31T16:14:48+00:00" - }, - { - "name": "laminas/laminas-cache", - "version": "2.9.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-cache.git", - "reference": "f4746a868c3e2f2da63c19d23efac12b9d1bb554" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-cache/zipball/f4746a868c3e2f2da63c19d23efac12b9d1bb554", - "reference": "f4746a868c3e2f2da63c19d23efac12b9d1bb554", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^2.6.3 || ^3.2", - "laminas/laminas-servicemanager": "^2.7.8 || ^3.3", - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0", - "psr/cache": "^1.0", - "psr/simple-cache": "^1.0" - }, - "provide": { - "psr/cache-implementation": "1.0", - "psr/simple-cache-implementation": "1.0" - }, - "replace": { - "zendframework/zend-cache": "self.version" - }, - "require-dev": { - "cache/integration-tests": "^0.16", - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-serializer": "^2.6", - "laminas/laminas-session": "^2.7.4", - "phpbench/phpbench": "^0.13", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" - }, - "suggest": { - "ext-apc": "APC or compatible extension, to use the APC storage adapter", - "ext-apcu": "APCU >= 5.1.0, to use the APCu storage adapter", - "ext-dba": "DBA, to use the DBA storage adapter", - "ext-memcache": "Memcache >= 2.0.0 to use the Memcache storage adapter", - "ext-memcached": "Memcached >= 1.0.0 to use the Memcached storage adapter", - "ext-mongo": "Mongo, to use MongoDb storage adapter", - "ext-mongodb": "MongoDB, to use the ExtMongoDb storage adapter", - "ext-redis": "Redis, to use Redis storage adapter", - "ext-wincache": "WinCache, to use the WinCache storage adapter", - "ext-xcache": "XCache, to use the XCache storage adapter", - "laminas/laminas-serializer": "Laminas\\Serializer component", - "laminas/laminas-session": "Laminas\\Session component", - "mongodb/mongodb": "Required for use with the ext-mongodb adapter", - "mongofill/mongofill": "Alternative to ext-mongo - a pure PHP implementation designed as a drop in replacement" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.9.x-dev", - "dev-develop": "2.10.x-dev" - }, - "laminas": { - "component": "Laminas\\Cache", - "config-provider": "Laminas\\Cache\\ConfigProvider" - } - }, - "autoload": { - "files": [ - "autoload/patternPluginManagerPolyfill.php" - ], - "psr-4": { - "Laminas\\Cache\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Caching implementation with a variety of storage options, as well as codified caching strategies for callbacks, classes, and output", - "homepage": "https://laminas.dev", - "keywords": [ - "cache", - "laminas", - "psr-16", - "psr-6" - ], - "time": "2019-12-31T16:23:18+00:00" - }, - { - "name": "laminas/laminas-config", - "version": "3.3.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-config.git", - "reference": "b8fe057f55e69a0e7a2e4ced79218a43f58606a8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-config/zipball/b8fe057f55e69a0e7a2e4ced79218a43f58606a8", - "reference": "b8fe057f55e69a0e7a2e4ced79218a43f58606a8", - "shasum": "" - }, - "require": { - "ext-json": "*", - "laminas/laminas-stdlib": "^2.7.7 || ^3.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0", - "psr/container": "^1.0" - }, - "conflict": { - "container-interop/container-interop": "<1.2.0" - }, - "replace": { - "zendframework/zend-config": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-filter": "^2.7.2", - "laminas/laminas-i18n": "^2.7.4", - "laminas/laminas-servicemanager": "^2.7.8 || ^3.3", - "malukenho/docheader": "^0.1.6", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" - }, - "suggest": { - "laminas/laminas-filter": "^2.7.2; install if you want to use the Filter processor", - "laminas/laminas-i18n": "^2.7.4; install if you want to use the Translator processor", - "laminas/laminas-servicemanager": "^2.7.8 || ^3.3; if you need an extensible plugin manager for use with the Config Factory" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.3.x-dev", - "dev-develop": "3.4.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Config\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides a nested object property based user interface for accessing this configuration data within application code", - "homepage": "https://laminas.dev", - "keywords": [ - "config", - "laminas" - ], - "time": "2019-12-31T16:30:11+00:00" - }, - { - "name": "laminas/laminas-escaper", - "version": "2.6.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-escaper.git", - "reference": "25f2a053eadfa92ddacb609dcbbc39362610da70" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/25f2a053eadfa92ddacb609dcbbc39362610da70", - "reference": "25f2a053eadfa92ddacb609dcbbc39362610da70", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-escaper": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.6.x-dev", - "dev-develop": "2.7.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Escaper\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Securely and safely escape HTML, HTML attributes, JavaScript, CSS, and URLs", - "homepage": "https://laminas.dev", - "keywords": [ - "escaper", - "laminas" - ], - "time": "2019-12-31T16:43:30+00:00" - }, - { - "name": "laminas/laminas-eventmanager", - "version": "3.2.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-eventmanager.git", - "reference": "ce4dc0bdf3b14b7f9815775af9dfee80a63b4748" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/ce4dc0bdf3b14b7f9815775af9dfee80a63b4748", - "reference": "ce4dc0bdf3b14b7f9815775af9dfee80a63b4748", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-eventmanager": "self.version" - }, - "require-dev": { - "athletic/athletic": "^0.1", - "container-interop/container-interop": "^1.1.0", - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-stdlib": "^2.7.3 || ^3.0", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" - }, - "suggest": { - "container-interop/container-interop": "^1.1.0, to use the lazy listeners feature", - "laminas/laminas-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2-dev", - "dev-develop": "3.3-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\EventManager\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Trigger and listen to events within a PHP application", - "homepage": "https://laminas.dev", - "keywords": [ - "event", - "eventmanager", - "events", - "laminas" - ], - "time": "2019-12-31T16:44:52+00:00" - }, - { - "name": "laminas/laminas-http", - "version": "2.11.2", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-http.git", - "reference": "8c66963b933c80da59433da56a44dfa979f3ec88" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-http/zipball/8c66963b933c80da59433da56a44dfa979f3ec88", - "reference": "8c66963b933c80da59433da56a44dfa979f3ec88", - "shasum": "" - }, - "require": { - "laminas/laminas-loader": "^2.5.1", - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-uri": "^2.5.2", - "laminas/laminas-validator": "^2.10.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-http": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-config": "^3.1 || ^2.6", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.3" - }, - "suggest": { - "paragonie/certainty": "For automated management of cacert.pem" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.11.x-dev", - "dev-develop": "2.12.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Http\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Provides an easy interface for performing Hyper-Text Transfer Protocol (HTTP) requests", - "homepage": "https://laminas.dev", - "keywords": [ - "http", - "http client", - "laminas" - ], - "time": "2019-12-31T17:02:36+00:00" - }, - { - "name": "laminas/laminas-json", - "version": "3.1.2", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-json.git", - "reference": "00dc0da7b5e5018904c5c4a8e80a5faa16c2c1c6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-json/zipball/00dc0da7b5e5018904c5c4a8e80a5faa16c2c1c6", - "reference": "00dc0da7b5e5018904c5c4a8e80a5faa16c2c1c6", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-json": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-stdlib": "^2.7.7 || ^3.1", - "phpunit/phpunit": "^5.7.23 || ^6.4.3" - }, - "suggest": { - "laminas/laminas-json-server": "For implementing JSON-RPC servers", - "laminas/laminas-xml2json": "For converting XML documents to JSON" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1.x-dev", - "dev-develop": "3.2.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Json\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides convenience methods for serializing native PHP to JSON and decoding JSON to native PHP", - "homepage": "https://laminas.dev", - "keywords": [ - "json", - "laminas" - ], - "time": "2019-12-31T17:15:04+00:00" - }, - { - "name": "laminas/laminas-loader", - "version": "2.6.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-loader.git", - "reference": "5d01c2c237ae9e68bec262f339947e2ea18979bc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-loader/zipball/5d01c2c237ae9e68bec262f339947e2ea18979bc", - "reference": "5d01c2c237ae9e68bec262f339947e2ea18979bc", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-loader": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.6.x-dev", - "dev-develop": "2.7.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Loader\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Autoloading and plugin loading strategies", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "loader" - ], - "time": "2019-12-31T17:18:27+00:00" - }, - { - "name": "laminas/laminas-modulemanager", - "version": "2.8.4", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-modulemanager.git", - "reference": "92b1cde1aab5aef687b863face6dd5d9c6751c78" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-modulemanager/zipball/92b1cde1aab5aef687b863face6dd5d9c6751c78", - "reference": "92b1cde1aab5aef687b863face6dd5d9c6751c78", - "shasum": "" - }, - "require": { - "laminas/laminas-config": "^3.1 || ^2.6", - "laminas/laminas-eventmanager": "^3.2 || ^2.6.3", - "laminas/laminas-stdlib": "^3.1 || ^2.7", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-modulemanager": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-console": "^2.6", - "laminas/laminas-di": "^2.6", - "laminas/laminas-loader": "^2.5", - "laminas/laminas-mvc": "^3.0 || ^2.7", - "laminas/laminas-servicemanager": "^3.0.3 || ^2.7.5", - "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.16" - }, - "suggest": { - "laminas/laminas-console": "Laminas\\Console component", - "laminas/laminas-loader": "Laminas\\Loader component if you are not using Composer autoloading for your modules", - "laminas/laminas-mvc": "Laminas\\Mvc component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8.x-dev", - "dev-develop": "2.9.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\ModuleManager\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Modular application system for laminas-mvc applications", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "modulemanager" - ], - "time": "2019-12-31T17:26:56+00:00" - }, - { - "name": "laminas/laminas-mvc", - "version": "3.1.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-mvc.git", - "reference": "ead09f8ab5ff0e562dbd0198c7f67523c2f61980" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/ead09f8ab5ff0e562dbd0198c7f67523c2f61980", - "reference": "ead09f8ab5ff0e562dbd0198c7f67523c2f61980", - "shasum": "" - }, - "require": { - "container-interop/container-interop": "^1.2", - "laminas/laminas-eventmanager": "^3.2", - "laminas/laminas-http": "^2.7", - "laminas/laminas-modulemanager": "^2.8", - "laminas/laminas-router": "^3.0.2", - "laminas/laminas-servicemanager": "^3.3", - "laminas/laminas-stdlib": "^3.1", - "laminas/laminas-view": "^2.9", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-mvc": "self.version" - }, - "require-dev": { - "http-interop/http-middleware": "^0.4.1", - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-json": "^2.6.1 || ^3.0", - "laminas/laminas-psr7bridge": "^1.0", - "laminas/laminas-stratigility": "^2.0.1", - "phpunit/phpunit": "^6.4.4 || ^5.7.14" - }, - "suggest": { - "http-interop/http-middleware": "^0.4.1 to be used together with laminas-stratigility", - "laminas/laminas-json": "(^2.6.1 || ^3.0) To auto-deserialize JSON body content in AbstractRestfulController extensions, when json_decode is unavailable", - "laminas/laminas-log": "^2.9.1 To provide log functionality via LogFilterManager, LogFormatterManager, and LogProcessorManager", - "laminas/laminas-mvc-console": "laminas-mvc-console provides the ability to expose laminas-mvc as a console application", - "laminas/laminas-mvc-i18n": "laminas-mvc-i18n provides integration with laminas-i18n, including a translation bridge and translatable route segments", - "laminas/laminas-mvc-plugin-fileprg": "To provide Post/Redirect/Get functionality around forms that container file uploads", - "laminas/laminas-mvc-plugin-flashmessenger": "To provide flash messaging capabilities between requests", - "laminas/laminas-mvc-plugin-identity": "To access the authenticated identity (per laminas-authentication) in controllers", - "laminas/laminas-mvc-plugin-prg": "To provide Post/Redirect/Get functionality within controllers", - "laminas/laminas-paginator": "^2.7 To provide pagination functionality via PaginatorPluginManager", - "laminas/laminas-psr7bridge": "(^0.2) To consume PSR-7 middleware within the MVC workflow", - "laminas/laminas-servicemanager-di": "laminas-servicemanager-di provides utilities for integrating laminas-di and laminas-servicemanager in your laminas-mvc application", - "laminas/laminas-stratigility": "laminas-stratigility is required to use middleware pipes in the MiddlewareListener" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1-dev", - "dev-develop": "3.2-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Mvc\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Laminas's event-driven MVC layer, including MVC Applications, Controllers, and Plugins", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc" - ], - "time": "2019-12-31T17:33:14+00:00" - }, - { - "name": "laminas/laminas-permissions-acl", - "version": "2.7.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-permissions-acl.git", - "reference": "624567fe376a70e0bfb5aa8217d5afa13b9d6e61" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/624567fe376a70e0bfb5aa8217d5afa13b9d6e61", - "reference": "624567fe376a70e0bfb5aa8217d5afa13b9d6e61", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-permissions-acl": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-servicemanager": "^2.7.5 || ^3.0.3", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.5" - }, - "suggest": { - "laminas/laminas-servicemanager": "To support Laminas\\Permissions\\Acl\\Assertion\\AssertionManager plugin manager usage" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7.x-dev", - "dev-develop": "2.8.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Permissions\\Acl\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Provides a lightweight and flexible access control list (ACL) implementation for privileges management", - "homepage": "https://laminas.dev", - "keywords": [ - "acl", - "laminas" - ], - "time": "2019-12-31T17:37:23+00:00" - }, - { - "name": "laminas/laminas-router", - "version": "3.3.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-router.git", - "reference": "c94f13f39dfbc4313efdbfcd9772487b4b009026" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-router/zipball/c94f13f39dfbc4313efdbfcd9772487b4b009026", - "reference": "c94f13f39dfbc4313efdbfcd9772487b4b009026", - "shasum": "" - }, - "require": { - "container-interop/container-interop": "^1.2", - "laminas/laminas-http": "^2.8.1", - "laminas/laminas-servicemanager": "^2.7.8 || ^3.3", - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "conflict": { - "laminas/laminas-mvc": "<3.0.0" - }, - "replace": { - "zendframework/zend-router": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-i18n": "^2.7.4", - "phpunit/phpunit": "^5.7.22 || ^6.4.1 || ^7.5.18" - }, - "suggest": { - "laminas/laminas-i18n": "^2.7.4, if defining translatable HTTP path segments" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.3.x-dev", - "dev-develop": "4.0.x-dev" - }, - "laminas": { - "component": "Laminas\\Router", - "config-provider": "Laminas\\Router\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Router\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Flexible routing system for HTTP and console applications", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc", - "routing" - ], - "time": "2020-01-03T17:19:34+00:00" - }, - { - "name": "laminas/laminas-servicemanager", - "version": "3.4.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-servicemanager.git", - "reference": "044cb8e380682563fb277ed5f6de4f690e4e6239" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/044cb8e380682563fb277ed5f6de4f690e4e6239", - "reference": "044cb8e380682563fb277ed5f6de4f690e4e6239", - "shasum": "" - }, - "require": { - "container-interop/container-interop": "^1.2", - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0", - "psr/container": "^1.0" - }, - "provide": { - "container-interop/container-interop-implementation": "^1.2", - "psr/container-implementation": "^1.0" - }, - "replace": { - "zendframework/zend-servicemanager": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "mikey179/vfsstream": "^1.6.5", - "ocramius/proxy-manager": "^1.0 || ^2.0", - "phpbench/phpbench": "^0.13.0", - "phpunit/phpunit": "^5.7.25 || ^6.4.4" - }, - "suggest": { - "laminas/laminas-stdlib": "laminas-stdlib ^2.5 if you wish to use the MergeReplaceKey or MergeRemoveKey features in Config instances", - "ocramius/proxy-manager": "ProxyManager 1.* to handle lazy initialization of services" - }, - "bin": [ - "bin/generate-deps-for-config-factory", - "bin/generate-factory-for-class" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.3-dev", - "dev-develop": "4.0-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\ServiceManager\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Factory-Driven Dependency Injection Container", - "homepage": "https://laminas.dev", - "keywords": [ - "PSR-11", - "dependency-injection", - "di", - "dic", - "laminas", - "service-manager", - "servicemanager" - ], - "time": "2019-12-31T17:44:47+00:00" - }, - { - "name": "laminas/laminas-stdlib", - "version": "3.2.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "2b18347625a2f06a1a485acfbc870f699dbe51c6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/2b18347625a2f06a1a485acfbc870f699dbe51c6", - "reference": "2b18347625a2f06a1a485acfbc870f699dbe51c6", - "shasum": "" - }, - "require": { - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-stdlib": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "phpbench/phpbench": "^0.13", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.2.x-dev", - "dev-develop": "3.3.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Stdlib\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "SPL extensions, array utilities, error handlers, and more", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "stdlib" - ], - "time": "2019-12-31T17:51:15+00:00" - }, - { - "name": "laminas/laminas-uri", - "version": "2.7.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-uri.git", - "reference": "6be8ce19622f359b048ce4faebf1aa1bca73a7ff" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-uri/zipball/6be8ce19622f359b048ce4faebf1aa1bca73a7ff", - "reference": "6be8ce19622f359b048ce4faebf1aa1bca73a7ff", - "shasum": "" - }, - "require": { - "laminas/laminas-escaper": "^2.5", - "laminas/laminas-validator": "^2.10", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-uri": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "phpunit/phpunit": "^5.7.27 || ^6.5.8 || ^7.1.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7.x-dev", - "dev-develop": "2.8.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Uri\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "A component that aids in manipulating and validating ยป Uniform Resource Identifiers (URIs)", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "uri" - ], - "time": "2019-12-31T17:56:00+00:00" - }, - { - "name": "laminas/laminas-validator", - "version": "2.13.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-validator.git", - "reference": "2a03c207d5ae038259f0abb588f64851cebdcb1a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/2a03c207d5ae038259f0abb588f64851cebdcb1a", - "reference": "2a03c207d5ae038259f0abb588f64851cebdcb1a", - "shasum": "" - }, - "require": { - "container-interop/container-interop": "^1.1", - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^7.1" - }, - "replace": { - "zendframework/zend-validator": "self.version" - }, - "require-dev": { - "laminas/laminas-cache": "^2.6.1", - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-config": "^2.6", - "laminas/laminas-db": "^2.7", - "laminas/laminas-filter": "^2.6", - "laminas/laminas-http": "^2.5.4", - "laminas/laminas-i18n": "^2.6", - "laminas/laminas-math": "^2.6", - "laminas/laminas-servicemanager": "^2.7.5 || ^3.0.3", - "laminas/laminas-session": "^2.8", - "laminas/laminas-uri": "^2.5", - "phpunit/phpunit": "^6.0.8 || ^5.7.15", - "psr/http-client": "^1.0", - "psr/http-factory": "^1.0", - "psr/http-message": "^1.0" - }, - "suggest": { - "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator", - "laminas/laminas-filter": "Laminas\\Filter component, required by the Digits validator", - "laminas/laminas-i18n": "Laminas\\I18n component to allow translation of validation error messages", - "laminas/laminas-i18n-resources": "Translations of validator messages", - "laminas/laminas-math": "Laminas\\Math component, required by the Csrf validator", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component to allow using the ValidatorPluginManager and validator chains", - "laminas/laminas-session": "Laminas\\Session component, ^2.8; required by the Csrf validator", - "laminas/laminas-uri": "Laminas\\Uri component, required by the Uri and Sitemap\\Loc validators", - "psr/http-message": "psr/http-message, required when validating PSR-7 UploadedFileInterface instances via the Upload and UploadFile validators" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.13.x-dev", - "dev-develop": "2.14.x-dev" - }, - "laminas": { - "component": "Laminas\\Validator", - "config-provider": "Laminas\\Validator\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Validator\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Validation classes for a wide range of domains, and the ability to chain validators to create complex validation criteria", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "validator" - ], - "time": "2019-12-31T17:57:49+00:00" - }, - { - "name": "laminas/laminas-view", - "version": "2.11.4", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-view.git", - "reference": "3bbb2e94287383604c898284a18d2d06cf17301e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-view/zipball/3bbb2e94287383604c898284a18d2d06cf17301e", - "reference": "3bbb2e94287383604c898284a18d2d06cf17301e", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^2.6.2 || ^3.0", - "laminas/laminas-json": "^2.6.1 || ^3.0", - "laminas/laminas-loader": "^2.5", - "laminas/laminas-stdlib": "^2.7 || ^3.0", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-view": "self.version" - }, - "require-dev": { - "laminas/laminas-authentication": "^2.5", - "laminas/laminas-cache": "^2.6.1", - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-config": "^2.6", - "laminas/laminas-console": "^2.6", - "laminas/laminas-escaper": "^2.5", - "laminas/laminas-feed": "^2.7", - "laminas/laminas-filter": "^2.6.1", - "laminas/laminas-http": "^2.5.4", - "laminas/laminas-i18n": "^2.6", - "laminas/laminas-log": "^2.7", - "laminas/laminas-modulemanager": "^2.7.1", - "laminas/laminas-mvc": "^2.7.14 || ^3.0", - "laminas/laminas-navigation": "^2.5", - "laminas/laminas-paginator": "^2.5", - "laminas/laminas-permissions-acl": "^2.6", - "laminas/laminas-router": "^3.0.1", - "laminas/laminas-serializer": "^2.6.1", - "laminas/laminas-servicemanager": "^2.7.5 || ^3.0.3", - "laminas/laminas-session": "^2.8.1", - "laminas/laminas-uri": "^2.5", - "phpunit/phpunit": "^5.7.15 || ^6.0.8" - }, - "suggest": { - "laminas/laminas-authentication": "Laminas\\Authentication component", - "laminas/laminas-escaper": "Laminas\\Escaper component", - "laminas/laminas-feed": "Laminas\\Feed component", - "laminas/laminas-filter": "Laminas\\Filter component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-i18n": "Laminas\\I18n component", - "laminas/laminas-mvc": "Laminas\\Mvc component", - "laminas/laminas-mvc-plugin-flashmessenger": "laminas-mvc-plugin-flashmessenger component, if you want to use the FlashMessenger view helper with laminas-mvc versions 3 and up", - "laminas/laminas-navigation": "Laminas\\Navigation component", - "laminas/laminas-paginator": "Laminas\\Paginator component", - "laminas/laminas-permissions-acl": "Laminas\\Permissions\\Acl component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", - "laminas/laminas-uri": "Laminas\\Uri component" - }, - "bin": [ - "bin/templatemap_generator.php" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.11.x-dev", - "dev-develop": "2.12.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\View\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Flexible view layer supporting and providing multiple view layers, helpers, and more", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "view" - ], - "time": "2019-12-31T18:03:30+00:00" - }, - { - "name": "laminas/laminas-zendframework-bridge", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-zendframework-bridge.git", - "reference": "32d7095e436a31b8d98e485a5c63d70df74915a8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-zendframework-bridge/zipball/32d7095e436a31b8d98e485a5c63d70df74915a8", - "reference": "32d7095e436a31b8d98e485a5c63d70df74915a8", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.5 || ^7.5 || ^8.1", - "squizlabs/php_codesniffer": "^3.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev", - "dev-develop": "1.1.x-dev" - }, - "laminas": { - "module": "Laminas\\ZendFrameworkBridge" - } - }, - "autoload": { - "files": [ - "src/autoload.php" - ], - "psr-4": { - "Laminas\\ZendFrameworkBridge\\": "src//" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Alias legacy ZF class names to Laminas Project equivalents.", - "keywords": [ - "ZendFramework", - "autoloading", - "laminas", - "zf" - ], - "time": "2019-12-31T15:24:03+00:00" - }, - { - "name": "psr/cache", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/php-fig/cache.git", - "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/cache/zipball/d11b50ad223250cf17b86e38383413f5a6764bf8", - "reference": "d11b50ad223250cf17b86e38383413f5a6764bf8", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Cache\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for caching libraries", - "keywords": [ - "cache", - "psr", - "psr-6" - ], - "time": "2016-08-06T20:24:11+00:00" - }, - { - "name": "psr/container", - "version": "1.0.0", - "source": { - "type": "git", - "url": "https://github.com/php-fig/container.git", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Container\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common Container Interface (PHP FIG PSR-11)", - "homepage": "https://github.com/php-fig/container", - "keywords": [ - "PSR-11", - "container", - "container-interface", - "container-interop", - "psr" - ], - "time": "2017-02-14T16:28:37+00:00" - }, - { - "name": "psr/simple-cache", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/php-fig/simple-cache.git", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/simple-cache/zipball/408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", - "reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\SimpleCache\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interfaces for simple caching", - "keywords": [ - "cache", - "caching", - "psr", - "psr-16", - "simple-cache" - ], - "time": "2017-10-23T01:57:42+00:00" - } - ], - "packages-dev": [ - { - "name": "doctrine/annotations", - "version": "v1.8.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/annotations.git", - "reference": "904dca4eb10715b92569fbcd79e201d5c349b6bc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/904dca4eb10715b92569fbcd79e201d5c349b6bc", - "reference": "904dca4eb10715b92569fbcd79e201d5c349b6bc", - "shasum": "" - }, - "require": { - "doctrine/lexer": "1.*", - "php": "^7.1" - }, - "require-dev": { - "doctrine/cache": "1.*", - "phpunit/phpunit": "^7.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.7.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Docblock Annotations Parser", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "docblock", - "parser" - ], - "time": "2019-10-01T18:55:10+00:00" - }, - { - "name": "doctrine/cache", - "version": "1.10.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/cache.git", - "reference": "382e7f4db9a12dc6c19431743a2b096041bcdd62" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/382e7f4db9a12dc6c19431743a2b096041bcdd62", - "reference": "382e7f4db9a12dc6c19431743a2b096041bcdd62", - "shasum": "" - }, - "require": { - "php": "~7.1" - }, - "conflict": { - "doctrine/common": ">2.2,<2.4" - }, - "require-dev": { - "alcaeus/mongo-php-adapter": "^1.1", - "doctrine/coding-standard": "^6.0", - "mongodb/mongodb": "^1.1", - "phpunit/phpunit": "^7.0", - "predis/predis": "~1.0" - }, - "suggest": { - "alcaeus/mongo-php-adapter": "Required to use legacy MongoDB driver" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.9.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "PHP Doctrine Cache library is a popular cache implementation that supports many different drivers such as redis, memcache, apc, mongodb and others.", - "homepage": "https://www.doctrine-project.org/projects/cache.html", - "keywords": [ - "abstraction", - "apcu", - "cache", - "caching", - "couchdb", - "memcached", - "php", - "redis", - "xcache" - ], - "time": "2019-11-29T15:36:20+00:00" - }, - { - "name": "doctrine/collections", - "version": "1.6.4", - "source": { - "type": "git", - "url": "https://github.com/doctrine/collections.git", - "reference": "6b1e4b2b66f6d6e49983cebfe23a21b7ccc5b0d7" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/6b1e4b2b66f6d6e49983cebfe23a21b7ccc5b0d7", - "reference": "6b1e4b2b66f6d6e49983cebfe23a21b7ccc5b0d7", - "shasum": "" - }, - "require": { - "php": "^7.1.3" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpstan/phpstan-shim": "^0.9.2", - "phpunit/phpunit": "^7.0", - "vimeo/psalm": "^3.2.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.6.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Collections\\": "lib/Doctrine/Common/Collections" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "PHP Doctrine Collections library that adds additional functionality on top of PHP arrays.", - "homepage": "https://www.doctrine-project.org/projects/collections.html", - "keywords": [ - "array", - "collections", - "iterators", - "php" - ], - "time": "2019-11-13T13:07:11+00:00" - }, - { - "name": "doctrine/common", - "version": "v2.11.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/common.git", - "reference": "b8ca1dcf6b0dc8a2af7a09baac8d0c48345df4ff" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/b8ca1dcf6b0dc8a2af7a09baac8d0c48345df4ff", - "reference": "b8ca1dcf6b0dc8a2af7a09baac8d0c48345df4ff", - "shasum": "" - }, - "require": { - "doctrine/annotations": "^1.0", - "doctrine/cache": "^1.0", - "doctrine/collections": "^1.0", - "doctrine/event-manager": "^1.0", - "doctrine/inflector": "^1.0", - "doctrine/lexer": "^1.0", - "doctrine/persistence": "^1.1", - "doctrine/reflection": "^1.0", - "php": "^7.1" - }, - "require-dev": { - "doctrine/coding-standard": "^1.0", - "phpstan/phpstan": "^0.11", - "phpstan/phpstan-phpunit": "^0.11", - "phpunit/phpunit": "^7.0", - "squizlabs/php_codesniffer": "^3.0", - "symfony/phpunit-bridge": "^4.0.5" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.11.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "lib/Doctrine/Common" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - } - ], - "description": "PHP Doctrine Common project is a library that provides additional functionality that other Doctrine projects depend on such as better reflection support, persistence interfaces, proxies, event system and much more.", - "homepage": "https://www.doctrine-project.org/projects/common.html", - "keywords": [ - "common", - "doctrine", - "php" - ], - "time": "2019-09-10T10:10:14+00:00" - }, - { - "name": "doctrine/event-manager", - "version": "1.1.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/event-manager.git", - "reference": "629572819973f13486371cb611386eb17851e85c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/event-manager/zipball/629572819973f13486371cb611386eb17851e85c", - "reference": "629572819973f13486371cb611386eb17851e85c", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "conflict": { - "doctrine/common": "<2.9@dev" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "lib/Doctrine/Common" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - } - ], - "description": "The Doctrine Event Manager is a simple PHP event system that was built to be used with the various Doctrine projects.", - "homepage": "https://www.doctrine-project.org/projects/event-manager.html", - "keywords": [ - "event", - "event dispatcher", - "event manager", - "event system", - "events" - ], - "time": "2019-11-10T09:48:07+00:00" - }, - { - "name": "doctrine/inflector", - "version": "1.3.1", - "source": { - "type": "git", - "url": "https://github.com/doctrine/inflector.git", - "reference": "ec3a55242203ffa6a4b27c58176da97ff0a7aec1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/inflector/zipball/ec3a55242203ffa6a4b27c58176da97ff0a7aec1", - "reference": "ec3a55242203ffa6a4b27c58176da97ff0a7aec1", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^6.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Inflector\\": "lib/Doctrine/Common/Inflector" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Common String Manipulations with regard to casing and singular/plural rules.", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "inflection", - "pluralize", - "singularize", - "string" - ], - "time": "2019-10-30T19:59:35+00:00" - }, - { - "name": "doctrine/instantiator", - "version": "1.3.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/instantiator.git", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/ae466f726242e637cebdd526a7d991b9433bacf1", - "reference": "ae466f726242e637cebdd526a7d991b9433bacf1", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "ext-pdo": "*", - "ext-phar": "*", - "phpbench/phpbench": "^0.13", - "phpstan/phpstan-phpunit": "^0.11", - "phpstan/phpstan-shim": "^0.11", - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, - "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": "http://ocramius.github.com/" - } - ], - "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" - ], - "time": "2019-10-21T16:45:58+00:00" - }, - { - "name": "doctrine/lexer", - "version": "1.2.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "5242d66dbeb21a30dd8a3e66bf7a73b66e05e1f6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/5242d66dbeb21a30dd8a3e66bf7a73b66e05e1f6", - "reference": "5242d66dbeb21a30dd8a3e66bf7a73b66e05e1f6", - "shasum": "" - }, - "require": { - "php": "^7.2" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpstan/phpstan": "^0.11.8", - "phpunit/phpunit": "^8.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.2.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\Lexer\\": "lib/Doctrine/Common/Lexer" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "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", - "keywords": [ - "annotations", - "docblock", - "lexer", - "parser", - "php" - ], - "time": "2019-10-30T14:39:59+00:00" - }, - { - "name": "doctrine/persistence", - "version": "1.3.3", - "source": { - "type": "git", - "url": "https://github.com/doctrine/persistence.git", - "reference": "99b196bbd4715a94fa100fac664a351ffa46d6a5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/persistence/zipball/99b196bbd4715a94fa100fac664a351ffa46d6a5", - "reference": "99b196bbd4715a94fa100fac664a351ffa46d6a5", - "shasum": "" - }, - "require": { - "doctrine/annotations": "^1.0", - "doctrine/cache": "^1.0", - "doctrine/collections": "^1.0", - "doctrine/event-manager": "^1.0", - "doctrine/reflection": "^1.0", - "php": "^7.1" - }, - "conflict": { - "doctrine/common": "<2.10@dev" - }, - "require-dev": { - "doctrine/coding-standard": "^6.0", - "phpstan/phpstan": "^0.11", - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "lib/Doctrine/Common", - "Doctrine\\Persistence\\": "lib/Doctrine/Persistence" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - } - ], - "description": "The Doctrine Persistence project is a set of shared interfaces and functionality that the different Doctrine object mappers share.", - "homepage": "https://doctrine-project.org/projects/persistence.html", - "keywords": [ - "mapper", - "object", - "odm", - "orm", - "persistence" - ], - "time": "2019-12-13T10:43:02+00:00" - }, - { - "name": "doctrine/reflection", - "version": "v1.0.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/reflection.git", - "reference": "02538d3f95e88eb397a5f86274deb2c6175c2ab6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/reflection/zipball/02538d3f95e88eb397a5f86274deb2c6175c2ab6", - "reference": "02538d3f95e88eb397a5f86274deb2c6175c2ab6", - "shasum": "" - }, - "require": { - "doctrine/annotations": "^1.0", - "ext-tokenizer": "*", - "php": "^7.1" - }, - "require-dev": { - "doctrine/coding-standard": "^4.0", - "doctrine/common": "^2.8", - "phpstan/phpstan": "^0.9.2", - "phpstan/phpstan-phpunit": "^0.9.4", - "phpunit/phpunit": "^7.0", - "squizlabs/php_codesniffer": "^3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "lib/Doctrine/Common" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - }, - { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com" - } - ], - "description": "Doctrine Reflection component", - "homepage": "https://www.doctrine-project.org/projects/reflection.html", - "keywords": [ - "reflection" - ], - "time": "2018-06-14T14:45:07+00:00" - }, - { - "name": "laminas/laminas-console", - "version": "2.8.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-console.git", - "reference": "478a6ceac3e31fb38d6314088abda8b239ee23a5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-console/zipball/478a6ceac3e31fb38d6314088abda8b239ee23a5", - "reference": "478a6ceac3e31fb38d6314088abda8b239ee23a5", - "shasum": "" - }, - "require": { - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-console": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-filter": "^2.7.2", - "laminas/laminas-json": "^2.6 || ^3.0", - "laminas/laminas-validator": "^2.10.1", - "phpunit/phpunit": "^5.7.23 || ^6.4.3" - }, - "suggest": { - "laminas/laminas-filter": "To support DefaultRouteMatcher usage", - "laminas/laminas-validator": "To support DefaultRouteMatcher usage" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8.x-dev", - "dev-develop": "2.9.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Console\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Build console applications using getopt syntax or routing, complete with prompts", - "homepage": "https://laminas.dev", - "keywords": [ - "console", - "laminas" - ], - "time": "2019-12-31T16:31:45+00:00" - }, - { - "name": "laminas/laminas-db", - "version": "2.11.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-db.git", - "reference": "26422b5469ed894b916ea6b8377a7332206178cc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-db/zipball/26422b5469ed894b916ea6b8377a7332206178cc", - "reference": "26422b5469ed894b916ea6b8377a7332206178cc", - "shasum": "" - }, - "require": { - "laminas/laminas-stdlib": "^2.7 || ^3.0", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-db": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-eventmanager": "^2.6.2 || ^3.0", - "laminas/laminas-hydrator": "^1.1 || ^2.1 || ^3.0", - "laminas/laminas-servicemanager": "^2.7.5 || ^3.0.3", - "phpunit/phpunit": "^5.7.27 || ^6.5.14" - }, - "suggest": { - "laminas/laminas-eventmanager": "Laminas\\EventManager component", - "laminas/laminas-hydrator": "Laminas\\Hydrator component for using HydratingResultSets", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.11.x-dev", - "dev-develop": "2.12.x-dev" - }, - "laminas": { - "component": "Laminas\\Db", - "config-provider": "Laminas\\Db\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Db\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Database abstraction layer, SQL abstraction, result set abstraction, and RowDataGateway and TableDataGateway implementations", - "homepage": "https://laminas.dev", - "keywords": [ - "db", - "laminas" - ], - "time": "2019-12-31T19:56:10+00:00" - }, - { - "name": "laminas/laminas-developer-tools", - "version": "1.3.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-developer-tools.git", - "reference": "2fc2018e2a218bd5ec2c5e7c9df89d1a8fd033c2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-developer-tools/zipball/2fc2018e2a218bd5ec2c5e7c9df89d1a8fd033c2", - "reference": "2fc2018e2a218bd5ec2c5e7c9df89d1a8fd033c2", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^2.6.2 || ^3.0", - "laminas/laminas-modulemanager": "^2.7", - "laminas/laminas-mvc": "^2.7 || ^3.0.1", - "laminas/laminas-servicemanager": "^2.7.5 || ^3.0.3", - "laminas/laminas-stdlib": "^2.7 || ^3.0", - "laminas/laminas-view": "^2.6", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0", - "symfony/var-dumper": "^3.4.36 || ^4.4.1 || ^5.0.1" - }, - "replace": { - "zendframework/zend-developer-tools": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "phpunit/phpunit": "^5.7.25 || ^6.4.4 || ^7.1" - }, - "suggest": { - "aist/aist-git-tools": "Show you information about current GIT repository", - "bjyoungblood/bjy-profiler": "Version: dev-master, allows the usage of the (Laminas) Db collector.", - "doctrine/doctrine-orm-module": "Profile DoctrineORM queries", - "jhuet/zdt-logger-module": "Show you log data from Laminas\\Log", - "ocramius/ocra-service-manager": "OcraServiceManager can help you track dependencies within your application.", - "san/san-session-toolbar": "SanSessionToolbar can help you see current Laminas\\Session data you're using within your application.", - "snapshotpl/api-tools-snap-event-debugger": "ZfSnapEventDebugger can help you debug events from Laminas\\EventManager" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev", - "dev-develop": "2.0.x-dev" - }, - "laminas": { - "module": "Laminas\\DeveloperTools" - } - }, - "autoload": { - "psr-4": { - "Laminas\\DeveloperTools\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Module for developer and debug tools for use with laminas-mvc applications.", - "homepage": "https://laminas.dev", - "keywords": [ - "debug", - "developer", - "laminas", - "module" - ], - "time": "2019-12-31T16:40:01+00:00" - }, - { - "name": "myclabs/deep-copy", - "version": "1.9.4", - "source": { - "type": "git", - "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "579bb7356d91f9456ccd505f24ca8b667966a0a7" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/579bb7356d91f9456ccd505f24ca8b667966a0a7", - "reference": "579bb7356d91f9456ccd505f24ca8b667966a0a7", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "replace": { - "myclabs/deep-copy": "self.version" - }, - "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^7.1" - }, - "type": "library", - "autoload": { - "psr-4": { - "DeepCopy\\": "src/DeepCopy/" - }, - "files": [ - "src/DeepCopy/deep_copy.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Create deep copies (clones) of your objects", - "keywords": [ - "clone", - "copy", - "duplicate", - "object", - "object graph" - ], - "time": "2019-12-15T19:12:40+00:00" - }, - { - "name": "phar-io/manifest", - "version": "1.0.3", - "source": { - "type": "git", - "url": "https://github.com/phar-io/manifest.git", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "reference": "7761fcacf03b4d4f16e7ccb606d4879ca431fcf4", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-phar": "*", - "phar-io/version": "^2.0", - "php": "^5.6 || ^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "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": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", - "time": "2018-07-08T19:23:20+00:00" - }, - { - "name": "phar-io/version", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/phar-io/version.git", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "reference": "45a2ec53a73c70ce41d55cedef9063630abaf1b6", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.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" - }, - { - "name": "Sebastian Heuer", - "email": "sebastian@phpeople.de", - "role": "Developer" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de", - "role": "Developer" - } - ], - "description": "Library for handling version information and constraints", - "time": "2018-07-08T19:19:57+00:00" - }, - { - "name": "phpdocumentor/reflection-common", - "version": "2.0.0", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/63a995caa1ca9e5590304cd845c15ad6d482a62a", - "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "require-dev": { - "phpunit/phpunit": "~6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jaap van Otterdijk", - "email": "opensource@ijaap.nl" - } - ], - "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": "2018-08-07T13:53:10+00:00" - }, - { - "name": "phpdocumentor/reflection-docblock", - "version": "4.3.4", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "da3fd972d6bafd628114f7e7e036f45944b62e9c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/da3fd972d6bafd628114f7e7e036f45944b62e9c", - "reference": "da3fd972d6bafd628114f7e7e036f45944b62e9c", - "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" - }, - "require-dev": { - "doctrine/instantiator": "^1.0.5", - "mockery/mockery": "^1.0", - "phpdocumentor/type-resolver": "0.4.*", - "phpunit/phpunit": "^6.4" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - } - ], - "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" - }, - { - "name": "phpdocumentor/type-resolver", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "2e32a6d48972b2c1976ed5d8967145b6cec4a4a9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/2e32a6d48972b2c1976ed5d8967145b6cec4a4a9", - "reference": "2e32a6d48972b2c1976ed5d8967145b6cec4a4a9", - "shasum": "" - }, - "require": { - "php": "^7.1", - "phpdocumentor/reflection-common": "^2.0" - }, - "require-dev": { - "ext-tokenizer": "^7.1", - "mockery/mockery": "~1", - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "phpDocumentor\\Reflection\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "me@mikevanriel.com" - } - ], - "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", - "time": "2019-08-22T18:11:29+00:00" - }, - { - "name": "phpspec/prophecy", - "version": "1.10.1", - "source": { - "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "cbe1df668b3fe136bcc909126a0f529a78d4cbbc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/cbe1df668b3fe136bcc909126a0f529a78d4cbbc", - "reference": "cbe1df668b3fe136bcc909126a0f529a78d4cbbc", - "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", - "sebastian/recursion-context": "^1.0|^2.0|^3.0" - }, - "require-dev": { - "phpspec/phpspec": "^2.5 || ^3.2", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5 || ^7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.10.x-dev" - } - }, - "autoload": { - "psr-4": { - "Prophecy\\": "src/Prophecy" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" - } - ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "time": "2019-12-22T21:05:45+00:00" - }, - { - "name": "phpunit/php-code-coverage", - "version": "7.0.10", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f1884187926fbb755a9aaf0b3836ad3165b478bf", - "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-xmlwriter": "*", - "php": "^7.2", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.1.1", - "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^4.2.2", - "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1.3" - }, - "require-dev": { - "phpunit/phpunit": "^8.2.2" - }, - "suggest": { - "ext-xdebug": "^2.7.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "7.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": "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" - ], - "time": "2019-11-20T13:55:58+00:00" - }, - { - "name": "phpunit/php-file-iterator", - "version": "2.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "050bedf145a257b1ff02746c31894800e5122946" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/050bedf145a257b1ff02746c31894800e5122946", - "reference": "050bedf145a257b1ff02746c31894800e5122946", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-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" - ], - "time": "2018-09-13T20:33:42+00:00" - }, - { - "name": "phpunit/php-text-template", - "version": "1.2.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "reference": "31f8b717e51d9a2afca6c9f046f5d69fc27c8686", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "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" - ], - "time": "2015-06-21T13:50:34+00:00" - }, - { - "name": "phpunit/php-timer", - "version": "2.1.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/1038454804406b0b5f5f520358e78c1c2f71501e", - "reference": "1038454804406b0b5f5f520358e78c1c2f71501e", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.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": "Utility class for timing", - "homepage": "https://github.com/sebastianbergmann/php-timer/", - "keywords": [ - "timer" - ], - "time": "2019-06-07T04:22:29+00:00" - }, - { - "name": "phpunit/php-token-stream", - "version": "3.1.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/995192df77f63a59e47f025390d2d1fdf8f425ff", - "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.0" - }, - "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" - } - ], - "description": "Wrapper around PHP's tokenizer extension.", - "homepage": "https://github.com/sebastianbergmann/php-token-stream/", - "keywords": [ - "tokenizer" - ], - "time": "2019-09-17T06:23:10+00:00" - }, - { - "name": "phpunit/phpunit", - "version": "8.5.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "7870c78da3c5e4883eaef36ae47853ebb3cb86f2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/7870c78da3c5e4883eaef36ae47853ebb3cb86f2", - "reference": "7870c78da3c5e4883eaef36ae47853ebb3cb86f2", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.2.0", - "ext-dom": "*", - "ext-json": "*", - "ext-libxml": "*", - "ext-mbstring": "*", - "ext-xml": "*", - "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.9.1", - "phar-io/manifest": "^1.0.3", - "phar-io/version": "^2.0.1", - "php": "^7.2", - "phpspec/prophecy": "^1.8.1", - "phpunit/php-code-coverage": "^7.0.7", - "phpunit/php-file-iterator": "^2.0.2", - "phpunit/php-text-template": "^1.2.1", - "phpunit/php-timer": "^2.1.2", - "sebastian/comparator": "^3.0.2", - "sebastian/diff": "^3.0.2", - "sebastian/environment": "^4.2.2", - "sebastian/exporter": "^3.1.1", - "sebastian/global-state": "^3.0.0", - "sebastian/object-enumerator": "^3.0.3", - "sebastian/resource-operations": "^2.0.1", - "sebastian/type": "^1.1.3", - "sebastian/version": "^2.0.1" - }, - "require-dev": { - "ext-pdo": "*" - }, - "suggest": { - "ext-soap": "*", - "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0.0" - }, - "bin": [ - "phpunit" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "8.5-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": "The PHP Unit Testing framework.", - "homepage": "https://phpunit.de/", - "keywords": [ - "phpunit", - "testing", - "xunit" - ], - "time": "2019-12-25T14:49:39+00:00" - }, - { - "name": "sebastian/code-unit-reverse-lookup", - "version": "1.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/code-unit-reverse-lookup.git", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/code-unit-reverse-lookup/zipball/4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "reference": "4419fcdb5eabb9caa61a27c7a1db532a6b55dd18", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.7 || ^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Looks up which function or method a line of code belongs to", - "homepage": "https://github.com/sebastianbergmann/code-unit-reverse-lookup/", - "time": "2017-03-04T06:30:41+00:00" - }, - { - "name": "sebastian/comparator", - "version": "3.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "reference": "5de4fc177adf9bce8df98d8d141a7559d7ccf6da", - "shasum": "" - }, - "require": { - "php": "^7.1", - "sebastian/diff": "^3.0", - "sebastian/exporter": "^3.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.1" - }, - "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": "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": "https://github.com/sebastianbergmann/comparator", - "keywords": [ - "comparator", - "compare", - "equality" - ], - "time": "2018-07-12T15:12:46+00:00" - }, - { - "name": "sebastian/diff", - "version": "3.0.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "reference": "720fcc7e9b5cf384ea68d9d930d480907a0c1a29", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.5 || ^8.0", - "symfony/process": "^2 || ^3.3 || ^4" - }, - "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": "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", - "udiff", - "unidiff", - "unified diff" - ], - "time": "2019-02-04T06:01:07+00:00" - }, - { - "name": "sebastian/environment", - "version": "4.2.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "require-dev": { - "phpunit/phpunit": "^7.5" - }, - "suggest": { - "ext-posix": "*" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.2-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Provides functionality to handle HHVM/PHP environments", - "homepage": "http://www.github.com/sebastianbergmann/environment", - "keywords": [ - "Xdebug", - "environment", - "hhvm" - ], - "time": "2019-11-20T08:46:58+00:00" - }, - { - "name": "sebastian/exporter", - "version": "3.1.2", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/68609e1261d215ea5b21b7987539cbfbe156ec3e", - "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e", - "shasum": "" - }, - "require": { - "php": "^7.0", - "sebastian/recursion-context": "^3.0" - }, - "require-dev": { - "ext-mbstring": "*", - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.1.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "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": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", - "keywords": [ - "export", - "exporter" - ], - "time": "2019-09-14T09:02:43+00:00" - }, - { - "name": "sebastian/global-state", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", - "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", - "shasum": "" - }, - "require": { - "php": "^7.2", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" - }, - "require-dev": { - "ext-dom": "*", - "phpunit/phpunit": "^8.0" - }, - "suggest": { - "ext-uopz": "*" - }, - "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" - } - ], - "description": "Snapshotting of global state", - "homepage": "http://www.github.com/sebastianbergmann/global-state", - "keywords": [ - "global state" - ], - "time": "2019-02-01T05:30:01+00:00" - }, - { - "name": "sebastian/object-enumerator", - "version": "3.0.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/object-enumerator.git", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-enumerator/zipball/7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "reference": "7cfd9e65d11ffb5af41198476395774d4c8a84c5", - "shasum": "" - }, - "require": { - "php": "^7.0", - "sebastian/object-reflector": "^1.1.1", - "sebastian/recursion-context": "^3.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Traverses array structures and object graphs to enumerate all referenced objects", - "homepage": "https://github.com/sebastianbergmann/object-enumerator/", - "time": "2017-08-03T12:35:26+00:00" - }, - { - "name": "sebastian/object-reflector", - "version": "1.1.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/object-reflector.git", - "reference": "773f97c67f28de00d397be301821b06708fca0be" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/object-reflector/zipball/773f97c67f28de00d397be301821b06708fca0be", - "reference": "773f97c67f28de00d397be301821b06708fca0be", - "shasum": "" - }, - "require": { - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - } - ], - "description": "Allows reflection of object attributes, including inherited and non-public ones", - "homepage": "https://github.com/sebastianbergmann/object-reflector/", - "time": "2017-03-29T09:07:27+00:00" - }, - { - "name": "sebastian/recursion-context", - "version": "3.0.0", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "reference": "5b0cd723502bac3b006cbf3dbf7a1e3fcefe4fa8", - "shasum": "" - }, - "require": { - "php": "^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^6.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0.x-dev" - } - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Jeff Welch", - "email": "whatthejeff@gmail.com" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, - { - "name": "Adam Harvey", - "email": "aharvey@php.net" - } - ], - "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", - "time": "2017-03-03T06:23:57+00:00" - }, - { - "name": "sebastian/resource-operations", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/resource-operations.git", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/resource-operations/zipball/4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "reference": "4d7a795d35b889bf80a0cc04e08d77cedfa917a9", - "shasum": "" - }, - "require": { - "php": "^7.1" - }, - "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" - } - ], - "description": "Provides a list of PHP built-in functions that operate on resources", - "homepage": "https://www.github.com/sebastianbergmann/resource-operations", - "time": "2018-10-04T04:07:39+00:00" - }, - { - "name": "sebastian/type", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/type.git", - "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/3aaaa15fa71d27650d62a948be022fe3b48541a3", - "reference": "3aaaa15fa71d27650d62a948be022fe3b48541a3", - "shasum": "" - }, - "require": { - "php": "^7.2" - }, - "require-dev": { - "phpunit/phpunit": "^8.2" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.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": "Collection of value objects that represent the types of the PHP type system", - "homepage": "https://github.com/sebastianbergmann/type", - "time": "2019-07-02T08:10:15+00:00" - }, - { - "name": "sebastian/version", - "version": "2.0.1", - "source": { - "type": "git", - "url": "https://github.com/sebastianbergmann/version.git", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/99732be0ddb3361e16ad77b68ba41efc8e979019", - "reference": "99732be0ddb3361e16ad77b68ba41efc8e979019", - "shasum": "" - }, - "require": { - "php": ">=5.6" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-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 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" - }, - { - "name": "symfony/polyfill-ctype", - "version": "v1.13.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", - "reference": "f8f0b461be3385e56d6de3dbb5a0df24c0c275e3", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-ctype": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.13-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Gert de Pagter", - "email": "BackEndTea@gmail.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for ctype functions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "ctype", - "polyfill", - "portable" - ], - "time": "2019-11-27T13:56:44+00:00" - }, - { - "name": "symfony/polyfill-mbstring", - "version": "v1.13.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "7b4aab9743c30be783b73de055d24a39cf4b954f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/7b4aab9743c30be783b73de055d24a39cf4b954f", - "reference": "7b4aab9743c30be783b73de055d24a39cf4b954f", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.13-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for the Mbstring extension", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "mbstring", - "polyfill", - "portable", - "shim" - ], - "time": "2019-11-27T14:18:11+00:00" - }, - { - "name": "symfony/var-dumper", - "version": "v5.0.2", - "source": { - "type": "git", - "url": "https://github.com/symfony/var-dumper.git", - "reference": "d7bc61d5d335fa9b1b91e14bb16861e8ca50f53a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/d7bc61d5d335fa9b1b91e14bb16861e8ca50f53a", - "reference": "d7bc61d5d335fa9b1b91e14bb16861e8ca50f53a", - "shasum": "" - }, - "require": { - "php": "^7.2.5", - "symfony/polyfill-mbstring": "~1.0" - }, - "conflict": { - "phpunit/phpunit": "<5.4.3", - "symfony/console": "<4.4" - }, - "require-dev": { - "ext-iconv": "*", - "symfony/console": "^4.4|^5.0", - "symfony/process": "^4.4|^5.0", - "twig/twig": "^2.4|^3.0" - }, - "suggest": { - "ext-iconv": "To convert non-UTF-8 strings to UTF-8 (or symfony/polyfill-iconv in case ext-iconv cannot be used).", - "ext-intl": "To show region name in time zone dump", - "symfony/console": "To use the ServerDumpCommand and/or the bin/var-dump-server script" - }, - "bin": [ - "Resources/bin/var-dump-server" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "5.0-dev" - } - }, - "autoload": { - "files": [ - "Resources/functions/dump.php" - ], - "psr-4": { - "Symfony\\Component\\VarDumper\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony mechanism for exploring and dumping PHP variables", - "homepage": "https://symfony.com", - "keywords": [ - "debug", - "dump" - ], - "time": "2019-12-18T13:50:31+00:00" - }, - { - "name": "theseer/tokenizer", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/theseer/tokenizer.git", - "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/11336f6f84e16a720dae9d8e6ed5019efa85a0f9", - "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9", - "shasum": "" - }, - "require": { - "ext-dom": "*", - "ext-tokenizer": "*", - "ext-xmlwriter": "*", - "php": "^7.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", - "time": "2019-06-13T22:48:21+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.6.0", - "source": { - "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "573381c0a64f155a0d9a23f4b0c797194805b925" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/573381c0a64f155a0d9a23f4b0c797194805b925", - "reference": "573381c0a64f155a0d9a23f4b0c797194805b925", - "shasum": "" - }, - "require": { - "php": "^5.3.3 || ^7.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "vimeo/psalm": "<3.6.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" - }, - "type": "library", - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "time": "2019-11-24T13:36:37+00:00" - } - ], - "aliases": [], - "minimum-stability": "stable", - "stability-flags": [], - "prefer-stable": false, - "prefer-lowest": false, - "platform": { - "php": "^7.2" - }, - "platform-dev": [] -} diff --git a/config/module.config.php b/config/module.config.php index cee2595..2990994 100644 --- a/config/module.config.php +++ b/config/module.config.php @@ -6,6 +6,8 @@ * @license http://framework.zend.com/license/new-bsd New BSD License */ +namespace BjyAuthorize; + return [ 'bjyauthorize' => [ // default role for unauthenticated users @@ -52,57 +54,49 @@ // Key used by the cache for caching the acl 'cache_key' => 'bjyauthorize_acl' ], - 'service_manager' => [ 'factories' => [ - 'BjyAuthorize\Cache' => 'BjyAuthorize\Service\CacheFactory', - 'BjyAuthorize\CacheKeyGenerator' => 'BjyAuthorize\Service\CacheKeyGeneratorFactory', - 'BjyAuthorize\Config' => 'BjyAuthorize\Service\ConfigServiceFactory', - 'BjyAuthorize\Guards' => 'BjyAuthorize\Service\GuardsServiceFactory', - 'BjyAuthorize\RoleProviders' => 'BjyAuthorize\Service\RoleProvidersServiceFactory', - 'BjyAuthorize\ResourceProviders' => 'BjyAuthorize\Service\ResourceProvidersServiceFactory', - 'BjyAuthorize\RuleProviders' => 'BjyAuthorize\Service\RuleProvidersServiceFactory', - 'BjyAuthorize\Guard\Controller' => 'BjyAuthorize\Service\ControllerGuardServiceFactory', - 'BjyAuthorize\Guard\Route' => 'BjyAuthorize\Service\RouteGuardServiceFactory', - 'BjyAuthorize\Provider\Role\Config' => 'BjyAuthorize\Service\ConfigRoleProviderServiceFactory', - 'BjyAuthorize\Provider\Role\LaminasDb' => 'BjyAuthorize\Service\LaminasDbRoleProviderServiceFactory', - 'BjyAuthorize\Provider\Rule\Config' => 'BjyAuthorize\Service\ConfigRuleProviderServiceFactory', - 'BjyAuthorize\Provider\Resource\Config' => 'BjyAuthorize\Service\ConfigResourceProviderServiceFactory', - 'BjyAuthorize\Service\Authorize' => 'BjyAuthorize\Service\AuthorizeFactory', - 'BjyAuthorize\Provider\Identity\ProviderInterface' - => 'BjyAuthorize\Service\IdentityProviderServiceFactory', - 'BjyAuthorize\Provider\Identity\AuthenticationIdentityProvider' - => 'BjyAuthorize\Service\AuthenticationIdentityProviderServiceFactory', - 'BjyAuthorize\Provider\Role\ObjectRepositoryProvider' - => 'BjyAuthorize\Service\ObjectRepositoryRoleProviderFactory', - 'BjyAuthorize\Collector\RoleCollector' => 'BjyAuthorize\Service\RoleCollectorServiceFactory', - 'BjyAuthorize\Provider\Identity\LmcUserLaminasDb' - => 'BjyAuthorize\Service\LmcUserLaminasDbIdentityProviderServiceFactory', - 'BjyAuthorize\View\UnauthorizedStrategy' - => 'BjyAuthorize\Service\UnauthorizedStrategyServiceFactory', - 'BjyAuthorize\Service\RoleDbTableGateway' => 'BjyAuthorize\Service\UserRoleServiceFactory', + 'BjyAuthorize\Cache' => Service\CacheFactory::class, + 'BjyAuthorize\CacheKeyGenerator' => Service\CacheKeyGeneratorFactory::class, + 'BjyAuthorize\Config' => Service\ConfigServiceFactory::class, + 'BjyAuthorize\Guards' => Service\GuardsServiceFactory::class, + 'BjyAuthorize\RoleProviders' => Service\RoleProvidersServiceFactory::class, + 'BjyAuthorize\ResourceProviders' => Service\ResourceProvidersServiceFactory::class, + 'BjyAuthorize\RuleProviders' => Service\RuleProvidersServiceFactory::class, + 'BjyAuthorize\Service\RoleDbTableGateway' => Service\UserRoleServiceFactory::class, + Collector\RoleCollector::class => Service\RoleCollectorServiceFactory::class, + Guard\Controller::class => Service\ControllerGuardServiceFactory::class, + Guard\Route::class => Service\RouteGuardServiceFactory::class, + Provider\Identity\AuthenticationIdentityProvider::class + => Service\AuthenticationIdentityProviderServiceFactory::class, + Provider\Identity\LmcUserLaminasDb::class => Service\LmcUserLaminasDbIdentityProviderServiceFactory::class, + Provider\Identity\ProviderInterface::class => Service\IdentityProviderServiceFactory::class, + Provider\Resource\Config::class => Service\ConfigResourceProviderServiceFactory::class, + Provider\Role\Config::class => Service\ConfigRoleProviderServiceFactory::class, + Provider\Role\LaminasDb::class => Service\LaminasDbRoleProviderServiceFactory::class, + Provider\Role\ObjectRepositoryProvider::class => Service\ObjectRepositoryRoleProviderFactory::class, + Provider\Rule\Config::class => Service\ConfigRuleProviderServiceFactory::class, + Service\Authorize::class => Service\AuthorizeFactory::class, + View\UnauthorizedStrategy::class => Service\UnauthorizedStrategyServiceFactory::class, ], 'invokables' => [ - 'BjyAuthorize\View\RedirectionStrategy' => 'BjyAuthorize\View\RedirectionStrategy', + View\RedirectionStrategy::class, ], 'aliases' => [ - 'bjyauthorize_zend_db_adapter' => 'Laminas\Db\Adapter\Adapter', + 'bjyauthorize_zend_db_adapter' => \Laminas\Db\Adapter\Adapter::class, ], 'initializers' => [ - 'BjyAuthorize\Service\AuthorizeAwareServiceInitializer' - => 'BjyAuthorize\Service\AuthorizeAwareServiceInitializer' + Service\AuthorizeAwareServiceInitializer::class ], ], - 'view_manager' => [ 'template_map' => [ 'error/403' => __DIR__ . '/../view/error/403.phtml', - 'zend-developer-tools/toolbar/bjy-authorize-role' - => __DIR__ . '/../view/zend-developer-tools/toolbar/bjy-authorize-role.phtml', + 'laminas-developer-tools/toolbar/bjy-authorize-role' + => __DIR__ . '/../view/laminas-developer-tools/toolbar/bjy-authorize-role.phtml', ], ], - - 'zenddevelopertools' => [ + 'laminas-developer-tools' => [ 'profiler' => [ 'collectors' => [ 'bjy_authorize_role_collector' => 'BjyAuthorize\\Collector\\RoleCollector', @@ -110,7 +104,7 @@ ], 'toolbar' => [ 'entries' => [ - 'bjy_authorize_role_collector' => 'zend-developer-tools/toolbar/bjy-authorize-role', + 'bjy_authorize_role_collector' => 'laminas-developer-tools/toolbar/bjy-authorize-role', ], ], ], diff --git a/src/BjyAuthorize/Collector/RoleCollector.php b/src/BjyAuthorize/Collector/RoleCollector.php index 065d33b..50437f6 100644 --- a/src/BjyAuthorize/Collector/RoleCollector.php +++ b/src/BjyAuthorize/Collector/RoleCollector.php @@ -9,10 +9,10 @@ namespace BjyAuthorize\Collector; use BjyAuthorize\Provider\Identity\ProviderInterface; -use Serializable; +use Laminas\DeveloperTools\Collector\CollectorInterface; use Laminas\Mvc\MvcEvent; use Laminas\Permissions\Acl\Role\RoleInterface; -use ZendDeveloperTools\Collector\CollectorInterface; +use Serializable; /** * Role collector - collects the role during dispatch diff --git a/src/BjyAuthorize/Controller/Plugin/IsAllowedFactory.php b/src/BjyAuthorize/Controller/Plugin/IsAllowedFactory.php index 596f1c7..84bd31a 100644 --- a/src/BjyAuthorize/Controller/Plugin/IsAllowedFactory.php +++ b/src/BjyAuthorize/Controller/Plugin/IsAllowedFactory.php @@ -3,6 +3,7 @@ namespace BjyAuthorize\Controller\Plugin; +use BjyAuthorize\Service\Authorize; use Interop\Container\ContainerInterface; use Laminas\ServiceManager\AbstractPluginManager; use Laminas\ServiceManager\FactoryInterface; @@ -27,7 +28,7 @@ public function createService(ServiceLocatorInterface $serviceLocator) */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - $authorize = $container->get('BjyAuthorize\Service\Authorize'); + $authorize = $container->get(Authorize::class); return new IsAllowed($authorize); } diff --git a/src/BjyAuthorize/Guard/AbstractGuard.php b/src/BjyAuthorize/Guard/AbstractGuard.php index 48bdacf..91f67b6 100644 --- a/src/BjyAuthorize/Guard/AbstractGuard.php +++ b/src/BjyAuthorize/Guard/AbstractGuard.php @@ -22,7 +22,7 @@ abstract class AbstractGuard extends AbstractListenerAggregate implements /** * @var ContainerInterface */ - protected $serviceLocator; + protected $container; /** * @var array[] @@ -32,11 +32,11 @@ abstract class AbstractGuard extends AbstractListenerAggregate implements /** * * @param array $rules - * @param ContainerInterface $serviceLocator + * @param ContainerInterface $container */ - public function __construct(array $rules, ContainerInterface $serviceLocator) + public function __construct(array $rules, ContainerInterface $container) { - $this->serviceLocator = $serviceLocator; + $this->container = $container; foreach ($rules as $rule) { $rule['roles'] = (array)$rule['roles']; diff --git a/src/BjyAuthorize/Guard/Controller.php b/src/BjyAuthorize/Guard/Controller.php index e24d2aa..78e7791 100644 --- a/src/BjyAuthorize/Guard/Controller.php +++ b/src/BjyAuthorize/Guard/Controller.php @@ -9,6 +9,7 @@ namespace BjyAuthorize\Guard; use BjyAuthorize\Exception\UnAuthorizedException; +use BjyAuthorize\Service\Authorize; use Laminas\Console\Request as ConsoleRequest; use Laminas\EventManager\EventManagerInterface; use Laminas\Http\Request as HttpRequest; @@ -77,7 +78,7 @@ public function getResourceName($controller, $action = null) public function onDispatch(MvcEvent $event) { /* @var $service \BjyAuthorize\Service\Authorize */ - $service = $this->serviceLocator->get('BjyAuthorize\Service\Authorize'); + $service = $this->container->get(Authorize::class); $match = $event->getRouteMatch(); $controller = $match->getParam('controller'); $action = $match->getParam('action'); diff --git a/src/BjyAuthorize/Guard/Route.php b/src/BjyAuthorize/Guard/Route.php index 7044763..0d8a193 100644 --- a/src/BjyAuthorize/Guard/Route.php +++ b/src/BjyAuthorize/Guard/Route.php @@ -9,6 +9,7 @@ namespace BjyAuthorize\Guard; use BjyAuthorize\Exception\UnAuthorizedException; +use BjyAuthorize\Service\Authorize; use Laminas\Console\Request as ConsoleRequest; use Laminas\EventManager\EventManagerInterface; use Laminas\Mvc\MvcEvent; @@ -50,7 +51,7 @@ public function attach(EventManagerInterface $events, $priority = 1) public function onRoute(MvcEvent $event) { /* @var $service \BjyAuthorize\Service\Authorize */ - $service = $this->serviceLocator->get('BjyAuthorize\Service\Authorize'); + $service = $this->container->get(Authorize::class); $match = $event->getRouteMatch(); $routeName = $match->getMatchedRouteName(); diff --git a/src/BjyAuthorize/Provider/Role/ObjectRepositoryProvider.php b/src/BjyAuthorize/Provider/Role/ObjectRepositoryProvider.php index 226bd74..5a484f5 100644 --- a/src/BjyAuthorize/Provider/Role/ObjectRepositoryProvider.php +++ b/src/BjyAuthorize/Provider/Role/ObjectRepositoryProvider.php @@ -10,23 +10,23 @@ use BjyAuthorize\Acl\HierarchicalRoleInterface; use BjyAuthorize\Acl\Role; -use Doctrine\Common\Persistence\ObjectRepository; +use Doctrine\Persistence\ObjectRepository; use Laminas\Permissions\Acl\Role\RoleInterface; /** - * Role provider based on a {@see \Doctrine\Common\Persistence\ObjectRepository} + * Role provider based on a {@see \Doctrine\Persistence\ObjectRepository} * * @author Tom Oram */ class ObjectRepositoryProvider implements ProviderInterface { /** - * @var \Doctrine\Common\Persistence\ObjectRepository + * @var \Doctrine\Persistence\ObjectRepository */ protected $objectRepository; /** - * @param \Doctrine\Common\Persistence\ObjectRepository $objectRepository + * @param \Doctrine\Persistence\ObjectRepository $objectRepository */ public function __construct(ObjectRepository $objectRepository) { diff --git a/src/BjyAuthorize/Service/AuthenticationIdentityProviderServiceFactory.php b/src/BjyAuthorize/Service/AuthenticationIdentityProviderServiceFactory.php index b69ebb2..05c1924 100644 --- a/src/BjyAuthorize/Service/AuthenticationIdentityProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/AuthenticationIdentityProviderServiceFactory.php @@ -11,8 +11,7 @@ use BjyAuthorize\Provider\Identity\AuthenticationIdentityProvider; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Simple authentication provider factory @@ -23,6 +22,7 @@ class AuthenticationIdentityProviderServiceFactory implements FactoryInterface { /** * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { @@ -35,12 +35,4 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o return $simpleIdentityProvider; } - - /** - * {@inheritDoc} - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, AuthenticationIdentityProvider::class); - } } diff --git a/src/BjyAuthorize/Service/AuthorizeAwareServiceInitializer.php b/src/BjyAuthorize/Service/AuthorizeAwareServiceInitializer.php index fc9bfc8..a2d029e 100644 --- a/src/BjyAuthorize/Service/AuthorizeAwareServiceInitializer.php +++ b/src/BjyAuthorize/Service/AuthorizeAwareServiceInitializer.php @@ -11,8 +11,7 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\InitializerInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Initializer\InitializerInterface; /** * Initializer that injects a {@see \BjyAuthorize\Service\Authorize} in @@ -24,6 +23,7 @@ class AuthorizeAwareServiceInitializer implements InitializerInterface { /** * {@inheritDoc} + * @see \Laminas\ServiceManager\Initializer\InitializerInterface::__invoke() */ public function __invoke(ContainerInterface $container, $instance) { @@ -32,16 +32,8 @@ public function __invoke(ContainerInterface $container, $instance) } /* @var $authorize \BjyAuthorize\Service\Authorize */ - $authorize = $container->get('BjyAuthorize\Service\Authorize'); + $authorize = $container->get(Authorize::class); $instance->setAuthorizeService($authorize); } - - /** - * {@inheritDoc} - */ - public function initialize($instance, ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, $instance); - } } diff --git a/src/BjyAuthorize/Service/AuthorizeFactory.php b/src/BjyAuthorize/Service/AuthorizeFactory.php index 95ddd18..174b860 100644 --- a/src/BjyAuthorize/Service/AuthorizeFactory.php +++ b/src/BjyAuthorize/Service/AuthorizeFactory.php @@ -9,8 +9,7 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of building the {@see \BjyAuthorize\Service\Authorize} service @@ -19,18 +18,12 @@ */ class AuthorizeFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return new Authorize($container->get('BjyAuthorize\Config'), $container); - } - /** * {@inheritDoc} - * - * @return \BjyAuthorize\Service\Authorize + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, Authorize::class); + return new Authorize($container->get('BjyAuthorize\Config'), $container); } } diff --git a/src/BjyAuthorize/Service/BaseProvidersServiceFactory.php b/src/BjyAuthorize/Service/BaseProvidersServiceFactory.php index 6dbcf6c..b40f7eb 100644 --- a/src/BjyAuthorize/Service/BaseProvidersServiceFactory.php +++ b/src/BjyAuthorize/Service/BaseProvidersServiceFactory.php @@ -9,8 +9,7 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Base factory responsible of instantiating providers @@ -23,8 +22,7 @@ abstract class BaseProvidersServiceFactory implements FactoryInterface /** * {@inheritDoc} - * - * @return array + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { @@ -41,14 +39,4 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o return $providers; } - - /** - * {@inheritDoc} - * - * @return array - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, ''); - } } diff --git a/src/BjyAuthorize/Service/CacheFactory.php b/src/BjyAuthorize/Service/CacheFactory.php index 1e6721d..00db9cf 100644 --- a/src/BjyAuthorize/Service/CacheFactory.php +++ b/src/BjyAuthorize/Service/CacheFactory.php @@ -9,10 +9,9 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\Cache\Storage\StorageInterface; use Laminas\Cache\StorageFactory; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\Cache\Storage\StorageInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory for building the cache storage @@ -22,24 +21,11 @@ class CacheFactory implements FactoryInterface { /** - * @param ContainerInterface $container - * @param string $requestedName - * @param array|null $options - * @return StorageInterface + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { return StorageFactory::factory($container->get('BjyAuthorize\Config')['cache_options']); } - - /** - * Create a cache - * - * @param ServiceLocatorInterface $serviceLocator - * @return StorageInterface - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, StorageFactory::class); - } } diff --git a/src/BjyAuthorize/Service/CacheKeyGeneratorFactory.php b/src/BjyAuthorize/Service/CacheKeyGeneratorFactory.php index 8fb84d9..fd9860b 100644 --- a/src/BjyAuthorize/Service/CacheKeyGeneratorFactory.php +++ b/src/BjyAuthorize/Service/CacheKeyGeneratorFactory.php @@ -9,8 +9,7 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory for building a cache key generator @@ -20,10 +19,8 @@ class CacheKeyGeneratorFactory implements FactoryInterface { /** - * @param ContainerInterface $container - * @param string $requestedName - * @param array|null $options - * @return \Closure + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { @@ -34,15 +31,4 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o return $cacheKey; }; } - - /** - * Create a cache key - * - * @param ServiceLocatorInterface $serviceLocator - * @return callable - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, ''); - } } diff --git a/src/BjyAuthorize/Service/ConfigResourceProviderServiceFactory.php b/src/BjyAuthorize/Service/ConfigResourceProviderServiceFactory.php index 399b551..681d3e6 100644 --- a/src/BjyAuthorize/Service/ConfigResourceProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/ConfigResourceProviderServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Provider\Resource\Config; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Provider\Resource\Config} @@ -21,25 +20,13 @@ class ConfigResourceProviderServiceFactory implements FactoryInterface { /** - * @param ContainerInterface $container - * @param string $requestedName - * @param array|null $options - * @return Config + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { return new Config( - $container->get('BjyAuthorize\Config')['resource_providers']['BjyAuthorize\Provider\Resource\Config'] + $container->get('BjyAuthorize\Config')['resource_providers'][Config::class] ); } - - /** - * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Resource\Config - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, Config::class); - } } diff --git a/src/BjyAuthorize/Service/ConfigRoleProviderServiceFactory.php b/src/BjyAuthorize/Service/ConfigRoleProviderServiceFactory.php index 316b646..abd5cc8 100644 --- a/src/BjyAuthorize/Service/ConfigRoleProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/ConfigRoleProviderServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Provider\Role\Config; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Provider\Role\Config} @@ -20,20 +19,14 @@ */ class ConfigRoleProviderServiceFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return new Config( - $container->get('BjyAuthorize\Config')['role_providers']['BjyAuthorize\Provider\Role\Config'] - ); - } - /** * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Role\Config + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, Config::class); + return new Config( + $container->get('BjyAuthorize\Config')['role_providers'][Config::class] + ); } } diff --git a/src/BjyAuthorize/Service/ConfigRuleProviderServiceFactory.php b/src/BjyAuthorize/Service/ConfigRuleProviderServiceFactory.php index 2ab43ad..2823943 100644 --- a/src/BjyAuthorize/Service/ConfigRuleProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/ConfigRuleProviderServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Provider\Rule\Config; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Provider\Rule\Config} @@ -20,20 +19,14 @@ */ class ConfigRuleProviderServiceFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return new Config( - $container->get('BjyAuthorize\Config')['rule_providers']['BjyAuthorize\Provider\Rule\Config'] - ); - } - /** * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Rule\Config + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, Config::class); + return new Config( + $container->get('BjyAuthorize\Config')['rule_providers'][Config::class] + ); } } diff --git a/src/BjyAuthorize/Service/ConfigServiceFactory.php b/src/BjyAuthorize/Service/ConfigServiceFactory.php index 97fae2c..0591a3f 100644 --- a/src/BjyAuthorize/Service/ConfigServiceFactory.php +++ b/src/BjyAuthorize/Service/ConfigServiceFactory.php @@ -9,8 +9,7 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of retrieving an array containing the BjyAuthorize configuration @@ -20,10 +19,8 @@ class ConfigServiceFactory implements FactoryInterface { /** - * @param ContainerInterface $container - * @param string $requestedName - * @param array|null $options - * @return array + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { @@ -31,14 +28,4 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o return $config['bjyauthorize']; } - - /** - * {@inheritDoc} - * - * @return array - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, ''); - } } diff --git a/src/BjyAuthorize/Service/ControllerGuardServiceFactory.php b/src/BjyAuthorize/Service/ControllerGuardServiceFactory.php index 4c00ffa..c9283a6 100644 --- a/src/BjyAuthorize/Service/ControllerGuardServiceFactory.php +++ b/src/BjyAuthorize/Service/ControllerGuardServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Guard\Controller; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Guard\Controller} @@ -20,21 +19,15 @@ */ class ControllerGuardServiceFactory implements FactoryInterface { + /** + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() + */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { return new Controller( - $container->get('BjyAuthorize\Config')['guards']['BjyAuthorize\Guard\Controller'], + $container->get('BjyAuthorize\Config')['guards'][Controller::class], $container ); } - - /** - * {@inheritDoc} - * - * @return \BjyAuthorize\Guard\Controller - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, Controller::class); - } } diff --git a/src/BjyAuthorize/Service/IdentityProviderServiceFactory.php b/src/BjyAuthorize/Service/IdentityProviderServiceFactory.php index 7fe356e..560e379 100644 --- a/src/BjyAuthorize/Service/IdentityProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/IdentityProviderServiceFactory.php @@ -9,8 +9,7 @@ namespace BjyAuthorize\Service; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of building {@see \BjyAuthorize\Provider\Identity\ProviderInterface} @@ -19,18 +18,12 @@ */ class IdentityProviderServiceFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return $container->get($container->get('BjyAuthorize\Config')['identity_provider']); - } - /** * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Identity\ProviderInterface + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, ''); + return $container->get($container->get('BjyAuthorize\Config')['identity_provider']); } } diff --git a/src/BjyAuthorize/Service/LaminasDbRoleProviderServiceFactory.php b/src/BjyAuthorize/Service/LaminasDbRoleProviderServiceFactory.php index 73fafe1..c29d68e 100644 --- a/src/BjyAuthorize/Service/LaminasDbRoleProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/LaminasDbRoleProviderServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Provider\Role\LaminasDb; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Provider\Role\LaminasDb} @@ -20,21 +19,15 @@ */ class LaminasDbRoleProviderServiceFactory implements FactoryInterface { + /** + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() + */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { return new LaminasDb( - $container->get('BjyAuthorize\Config')['role_providers']['BjyAuthorize\Provider\Role\LaminasDb'], + $container->get('BjyAuthorize\Config')['role_providers'][LaminasDb::class], $container ); } - - /** - * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Role\LaminasDb - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, LaminasDb::class); - } } diff --git a/src/BjyAuthorize/Service/LmcUserLaminasDbIdentityProviderServiceFactory.php b/src/BjyAuthorize/Service/LmcUserLaminasDbIdentityProviderServiceFactory.php index cea31da..5c08efb 100644 --- a/src/BjyAuthorize/Service/LmcUserLaminasDbIdentityProviderServiceFactory.php +++ b/src/BjyAuthorize/Service/LmcUserLaminasDbIdentityProviderServiceFactory.php @@ -11,8 +11,7 @@ use BjyAuthorize\Provider\Identity\LmcUserLaminasDb; use Interop\Container\ContainerInterface; use Laminas\Db\TableGateway\TableGateway; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Provider\Identity\LmcUserLaminasDb} @@ -21,6 +20,10 @@ */ class LmcUserLaminasDbIdentityProviderServiceFactory implements FactoryInterface { + /** + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() + */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { /* @var $tableGateway \Laminas\Db\TableGateway\TableGateway */ @@ -35,14 +38,4 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o return $provider; } - - /** - * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Identity\LmcUserLaminasDb - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, LmcUserLaminasDb::class); - } } diff --git a/src/BjyAuthorize/Service/ObjectRepositoryRoleProviderFactory.php b/src/BjyAuthorize/Service/ObjectRepositoryRoleProviderFactory.php index e0dc931..8890b4d 100644 --- a/src/BjyAuthorize/Service/ObjectRepositoryRoleProviderFactory.php +++ b/src/BjyAuthorize/Service/ObjectRepositoryRoleProviderFactory.php @@ -11,8 +11,7 @@ use BjyAuthorize\Exception\InvalidArgumentException; use BjyAuthorize\Provider\Role\ObjectRepositoryProvider; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Provider\Role\ObjectRepositoryProvider} @@ -22,17 +21,21 @@ */ class ObjectRepositoryRoleProviderFactory implements FactoryInterface { + /** + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() + */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { $config = $container->get('BjyAuthorize\Config'); - if (!isset($config['role_providers']['BjyAuthorize\Provider\Role\ObjectRepositoryProvider'])) { + if (!isset($config['role_providers'][ObjectRepositoryProvider::class])) { throw new InvalidArgumentException( 'Config for "BjyAuthorize\Provider\Role\ObjectRepositoryProvider" not set' ); } - $providerConfig = $config['role_providers']['BjyAuthorize\Provider\Role\ObjectRepositoryProvider']; + $providerConfig = $config['role_providers'][ObjectRepositoryProvider::class]; if (!isset($providerConfig['role_entity_class'])) { throw new InvalidArgumentException('role_entity_class not set in the bjyauthorize role_providers config.'); @@ -42,19 +45,9 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o throw new InvalidArgumentException('object_manager not set in the bjyauthorize role_providers config.'); } - /* @var $objectManager \Doctrine\Common\Persistence\ObjectManager */ + /* @var $objectManager \Doctrine\Persistence\ObjectManager */ $objectManager = $container->get($providerConfig['object_manager']); return new ObjectRepositoryProvider($objectManager->getRepository($providerConfig['role_entity_class'])); } - - /** - * {@inheritDoc} - * - * @return \BjyAuthorize\Provider\Role\ObjectRepositoryProvider - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, ObjectRepositoryProvider::class); - } } diff --git a/src/BjyAuthorize/Service/RoleCollectorServiceFactory.php b/src/BjyAuthorize/Service/RoleCollectorServiceFactory.php index 9590bd0..3718e74 100644 --- a/src/BjyAuthorize/Service/RoleCollectorServiceFactory.php +++ b/src/BjyAuthorize/Service/RoleCollectorServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Collector\RoleCollector; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Collector\RoleCollector} @@ -20,6 +19,10 @@ */ class RoleCollectorServiceFactory implements FactoryInterface { + /** + * {@inheritDoc} + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() + */ public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { /* @var $identityProvider \BjyAuthorize\Provider\Identity\ProviderInterface */ @@ -27,14 +30,4 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o return new RoleCollector($identityProvider); } - - /** - * {@inheritDoc} - * - * @return \BjyAuthorize\Collector\RoleCollector - */ - public function createService(ServiceLocatorInterface $serviceLocator) - { - return $this($serviceLocator, RoleCollector::class); - } } diff --git a/src/BjyAuthorize/Service/RouteGuardServiceFactory.php b/src/BjyAuthorize/Service/RouteGuardServiceFactory.php index 8b2a137..57c0e75 100644 --- a/src/BjyAuthorize/Service/RouteGuardServiceFactory.php +++ b/src/BjyAuthorize/Service/RouteGuardServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\Guard\Route; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\Guard\Route} @@ -20,18 +19,12 @@ */ class RouteGuardServiceFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return new Route($container->get('BjyAuthorize\Config')['guards']['BjyAuthorize\Guard\Route'], $container); - } - /** * {@inheritDoc} - * - * @return \BjyAuthorize\Guard\Route + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, Route::class); + return new Route($container->get('BjyAuthorize\Config')['guards'][Route::class], $container); } } diff --git a/src/BjyAuthorize/Service/UnauthorizedStrategyServiceFactory.php b/src/BjyAuthorize/Service/UnauthorizedStrategyServiceFactory.php index c521f14..e2ee31a 100644 --- a/src/BjyAuthorize/Service/UnauthorizedStrategyServiceFactory.php +++ b/src/BjyAuthorize/Service/UnauthorizedStrategyServiceFactory.php @@ -10,8 +10,7 @@ use BjyAuthorize\View\UnauthorizedStrategy; use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * Factory responsible of instantiating {@see \BjyAuthorize\View\UnauthorizedStrategy} @@ -20,18 +19,12 @@ */ class UnauthorizedStrategyServiceFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return new UnauthorizedStrategy($container->get('BjyAuthorize\Config')['template']); - } - /** * {@inheritDoc} - * - * @return \BjyAuthorize\View\UnauthorizedStrategy + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, UnauthorizedStrategy::class); + return new UnauthorizedStrategy($container->get('BjyAuthorize\Config')['template']); } } diff --git a/src/BjyAuthorize/Service/UserRoleServiceFactory.php b/src/BjyAuthorize/Service/UserRoleServiceFactory.php index 77f57c0..01525d7 100644 --- a/src/BjyAuthorize/Service/UserRoleServiceFactory.php +++ b/src/BjyAuthorize/Service/UserRoleServiceFactory.php @@ -10,8 +10,7 @@ use Interop\Container\ContainerInterface; use Laminas\Db\TableGateway\TableGateway; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; +use Laminas\ServiceManager\Factory\FactoryInterface; /** * @author Simone Castellaneta @@ -20,18 +19,12 @@ */ class UserRoleServiceFactory implements FactoryInterface { - public function __invoke(ContainerInterface $container, $requestedName, array $options = null) - { - return new TableGateway('user_role', $container->get('bjyauthorize_zend_db_adapter')); - } - /** * {@inheritDoc} - * - * @return \Laminas\Db\TableGateway\TableGateway + * @see \Laminas\ServiceManager\Factory\FactoryInterface::__invoke() */ - public function createService(ServiceLocatorInterface $serviceLocator) + public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { - return $this($serviceLocator, TableGateway::class); + return new TableGateway('user_role', $container->get('bjyauthorize_zend_db_adapter')); } } diff --git a/src/BjyAuthorize/View/Helper/IsAllowedFactory.php b/src/BjyAuthorize/View/Helper/IsAllowedFactory.php index 05e35a1..c3c6f47 100644 --- a/src/BjyAuthorize/View/Helper/IsAllowedFactory.php +++ b/src/BjyAuthorize/View/Helper/IsAllowedFactory.php @@ -3,6 +3,7 @@ namespace BjyAuthorize\View\Helper; +use BjyAuthorize\Service\Authorize; use Interop\Container\ContainerInterface; use Laminas\ServiceManager\AbstractPluginManager; use Laminas\ServiceManager\FactoryInterface; @@ -28,7 +29,7 @@ public function createService(ServiceLocatorInterface $serviceLocator) public function __invoke(ContainerInterface $container, $requestedName, array $options = null) { /* @var $authorize \BjyAuthorize\Service\Authorize */ - $authorize = $container->get('BjyAuthorize\Service\Authorize'); + $authorize = $container->get(Authorize::class); return new IsAllowed($authorize); } diff --git a/tests/BjyAuthorizeTest/Collector/RoleCollectorTest.php b/tests/BjyAuthorizeTest/Collector/RoleCollectorTest.php index 62a2755..b248a6d 100644 --- a/tests/BjyAuthorizeTest/Collector/RoleCollectorTest.php +++ b/tests/BjyAuthorizeTest/Collector/RoleCollectorTest.php @@ -24,7 +24,7 @@ class RoleCollectorTest extends TestCase protected $collector; /** - * @var \PHPUnit_Framework_MockObject_MockObject|\BjyAuthorize\Provider\Identity\ProviderInterface + * @var \PHPUnit\Framework\MockObject\MockObject|\BjyAuthorize\Provider\Identity\ProviderInterface */ protected $identityProvider; diff --git a/tests/BjyAuthorizeTest/Guard/ControllerTest.php b/tests/BjyAuthorizeTest/Guard/ControllerTest.php index 35d932d..06ac11a 100644 --- a/tests/BjyAuthorizeTest/Guard/ControllerTest.php +++ b/tests/BjyAuthorizeTest/Guard/ControllerTest.php @@ -22,12 +22,12 @@ class ControllerTest extends TestCase { /** - * @var \Laminas\ServiceManager\ServiceLocatorInterface|\PHPUnit_Framework_MockObject_MockObject + * @var \Laminas\ServiceManager\ServiceLocatorInterface|\PHPUnit\Framework\MockObject\MockObject */ protected $serviceLocator; /** - * @var \BjyAuthorize\Service\Authorize|\PHPUnit_Framework_MockObject_MockObject + * @var \BjyAuthorize\Service\Authorize|\PHPUnit\Framework\MockObject\MockObject */ protected $authorize; @@ -288,7 +288,7 @@ public function testOnDispatchWithInvalidResourceConsole() * @param string|null $action * @param string|null $method * - * @return \PHPUnit_Framework_MockObject_MockObject|\Laminas\Mvc\MvcEvent + * @return \PHPUnit\Framework\MockObject\MockObject|\Laminas\Mvc\MvcEvent */ private function createMvcEvent($controller = null, $action = null, $method = null) { diff --git a/tests/BjyAuthorizeTest/Guard/RouteTest.php b/tests/BjyAuthorizeTest/Guard/RouteTest.php index 12d19fe..11c5b27 100644 --- a/tests/BjyAuthorizeTest/Guard/RouteTest.php +++ b/tests/BjyAuthorizeTest/Guard/RouteTest.php @@ -21,12 +21,12 @@ class RouteTest extends TestCase { /** - * @var \Laminas\ServiceManager\ServiceLocatorInterface|\PHPUnit_Framework_MockObject_MockObject + * @var \Laminas\ServiceManager\ServiceLocatorInterface|\PHPUnit\Framework\MockObject\MockObject */ protected $serviceLocator; /** - * @var \BjyAuthorize\Service\Authorize|\PHPUnit_Framework_MockObject_MockObject + * @var \BjyAuthorize\Service\Authorize|\PHPUnit\Framework\MockObject\MockObject */ protected $authorize; @@ -251,7 +251,7 @@ public function testOnDispatchWithInvalidResourceConsole() /** * @param string|null $route * - * @return \PHPUnit_Framework_MockObject_MockObject|\Laminas\Mvc\MvcEvent + * @return \PHPUnit\Framework\MockObject\MockObject|\Laminas\Mvc\MvcEvent */ private function createMvcEvent($route = null) { diff --git a/tests/BjyAuthorizeTest/Provider/Identity/AuthenticationIdentityProviderTest.php b/tests/BjyAuthorizeTest/Provider/Identity/AuthenticationIdentityProviderTest.php index 10e9dd7..8664720 100644 --- a/tests/BjyAuthorizeTest/Provider/Identity/AuthenticationIdentityProviderTest.php +++ b/tests/BjyAuthorizeTest/Provider/Identity/AuthenticationIdentityProviderTest.php @@ -19,7 +19,7 @@ class AuthenticationIdentityProviderTest extends TestCase { /** - * @var \Laminas\Authentication\AuthenticationService|\PHPUnit_Framework_MockObject_MockObject + * @var \Laminas\Authentication\AuthenticationService|\PHPUnit\Framework\MockObject\MockObject */ protected $authService; diff --git a/tests/BjyAuthorizeTest/Provider/Role/ObjectRepositoryProviderTest.php b/tests/BjyAuthorizeTest/Provider/Role/ObjectRepositoryProviderTest.php index 4fe5b36..909fb11 100644 --- a/tests/BjyAuthorizeTest/Provider/Role/ObjectRepositoryProviderTest.php +++ b/tests/BjyAuthorizeTest/Provider/Role/ObjectRepositoryProviderTest.php @@ -9,8 +9,9 @@ namespace BjyAuthorizeTest\Provider\Role; use BjyAuthorize\Acl\Role; -use \PHPUnit\Framework\TestCase; use BjyAuthorize\Provider\Role\ObjectRepositoryProvider; +use Doctrine\Persistence\ObjectRepository; +use PHPUnit\Framework\TestCase; /** * {@see \BjyAuthorize\Provider\Role\ObjectRepositoryProvider} test @@ -25,7 +26,7 @@ class ObjectRepositoryProviderTest extends TestCase private $provider; /** - * @var \PHPUnit_Framework_MockObject_MockObject + * @var \PHPUnit\Framework\MockObject\MockObject */ private $repository; @@ -34,7 +35,7 @@ class ObjectRepositoryProviderTest extends TestCase */ protected function setUp(): void { - $this->repository = $this->createMock('Doctrine\Common\Persistence\ObjectRepository'); + $this->repository = $this->createMock(ObjectRepository::class); $this->provider = new ObjectRepositoryProvider($this->repository); } @@ -42,7 +43,7 @@ protected function setUp(): void * @param string $name * @param string $parent * - * @return \PHPUnit_Framework_MockObject_MockObject|\BjyAuthorize\Acl\HierarchicalRoleInterface + * @return \PHPUnit\Framework\MockObject\MockObject|\BjyAuthorize\Acl\HierarchicalRoleInterface */ private function createRoleMock($name, $parent) { diff --git a/tests/BjyAuthorizeTest/Service/AuthenticationIdentityProviderServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/AuthenticationIdentityProviderServiceFactoryTest.php index 634eeab..c47b645 100644 --- a/tests/BjyAuthorizeTest/Service/AuthenticationIdentityProviderServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/AuthenticationIdentityProviderServiceFactoryTest.php @@ -10,8 +10,10 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; use BjyAuthorize\Service\AuthenticationIdentityProviderServiceFactory; +use Interop\Container\ContainerInterface; +use LmcUser\Service\User; +use PHPUnit\Framework\TestCase; /** * Factory test for {@see \BjyAuthorize\Service\AuthenticationIdentityProviderServiceFactory} @@ -28,16 +30,16 @@ class AuthenticationIdentityProviderServiceFactoryTest extends TestCase public function testCreateService() { $config = [ - 'default_role' => 'test-guest', + 'default_role' => 'test-guest', 'authenticated_role' => 'test-user', ]; - $user = $this->getMockBuilder('ZfcUser\\Service\\User')->setMethods(['getAuthService'])->getMock(); - $auth = $this->createMock('Laminas\\Authentication\\AuthenticationService'); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); + $user = $this->getMockBuilder(User::class)->getMock(); + $auth = $this->createMock('Laminas\\Authentication\\AuthenticationService'); + $container = $this->createMock(ContainerInterface::class); $user->expects($this->once())->method('getAuthService')->will($this->returnValue($auth)); - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with($this->logicalOr('lmcuser_user_service', 'BjyAuthorize\\Config')) @@ -54,7 +56,7 @@ function ($service) use ($user, $config) { ); $authenticationFactory = new AuthenticationIdentityProviderServiceFactory(); - $authentication = $authenticationFactory->createService($serviceLocator); + $authentication = $authenticationFactory($container, AuthenticationIdentityProviderServiceFactory::class); $this->assertEquals($authentication->getDefaultRole(), 'test-guest'); $this->assertEquals($authentication->getAuthenticatedRole(), 'test-user'); diff --git a/tests/BjyAuthorizeTest/Service/AuthorizeAwareServiceInitializerTest.php b/tests/BjyAuthorizeTest/Service/AuthorizeAwareServiceInitializerTest.php index a27e0eb..c8d172f 100644 --- a/tests/BjyAuthorizeTest/Service/AuthorizeAwareServiceInitializerTest.php +++ b/tests/BjyAuthorizeTest/Service/AuthorizeAwareServiceInitializerTest.php @@ -10,8 +10,11 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Service\Authorize; +use BjyAuthorize\Service\AuthorizeAwareInterface; use BjyAuthorize\Service\AuthorizeAwareServiceInitializer; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\AuthorizeAwareServiceInitializer} @@ -21,14 +24,14 @@ class AuthorizeAwareServiceInitializerTest extends TestCase { /** - * @var \PHPUnit_Framework_MockObject_MockObject + * @var \PHPUnit\Framework\MockObject\MockObject */ protected $authorize; /** - * @var \PHPUnit_Framework_MockObject_MockObject + * @var \PHPUnit\Framework\MockObject\MockObject */ - protected $locator; + protected $container; /** * @var \BjyAuthorize\Service\AuthorizeAwareServiceInitializer @@ -37,14 +40,26 @@ class AuthorizeAwareServiceInitializerTest extends TestCase /** * {@inheritDoc} + * @see \PHPUnit\Framework\TestCase::setUp() */ - public function setUp(): void + protected function setUp(): void { - $this->authorize = $this->getMockBuilder('BjyAuthorize\\Service\\Authorize')->disableOriginalConstructor()->getMock(); - $this->locator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); + $this->authorize = $this->getMockBuilder(Authorize::class)->disableOriginalConstructor()->getMock(); + $this->container = $this->createMock(ContainerInterface::class); $this->initializer = new AuthorizeAwareServiceInitializer(); - $this->locator->expects($this->any())->method('get')->will($this->returnValue($this->authorize)); + $this->container->expects($this->any())->method('get')->will($this->returnValue($this->authorize)); + } + + /** + * {@inheritDoc} + * @see \PHPUnit\Framework\TestCase::tearDown() + */ + protected function tearDown(): void + { + unset($this->initializer); + unset($this->container); + unset($this->authorize); } /** @@ -52,11 +67,12 @@ public function setUp(): void */ public function testInitializeWithAuthorizeAwareObject() { - $awareObject = $this->createMock('BjyAuthorize\\Service\\AuthorizeAwareInterface'); + $awareObject = $this->createMock(AuthorizeAwareInterface::class); $awareObject->expects($this->once())->method('setAuthorizeService')->with($this->authorize); - $this->initializer->initialize($awareObject, $this->locator); + $initializer = $this->initializer; + $initializer($this->container, $awareObject); } /** @@ -64,10 +80,11 @@ public function testInitializeWithAuthorizeAwareObject() */ public function testInitializeWithSimpleObject() { - $awareObject = $this->getMockBuilder('stdClass')->setMethods(['setAuthorizeService'])->getMock(); + $awareObject = $this->getMockBuilder('stdClass')->getMock(); - $awareObject->expects($this->never())->method('setAuthorizeService'); + $this->container->expects($this->never())->method('get'); - $this->initializer->initialize($awareObject, $this->locator); + $initializer = $this->initializer; + $initializer($this->container, $awareObject); } } diff --git a/tests/BjyAuthorizeTest/Service/AuthorizeFactoryTest.php b/tests/BjyAuthorizeTest/Service/AuthorizeFactoryTest.php index 794d3d8..e5d7e99 100644 --- a/tests/BjyAuthorizeTest/Service/AuthorizeFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/AuthorizeFactoryTest.php @@ -8,9 +8,10 @@ namespace BjyAuthorizeTest\Service; +use BjyAuthorize\Service\Authorize; use BjyAuthorize\Service\AuthorizeFactory; -use \PHPUnit\Framework\TestCase; use Laminas\ServiceManager\ServiceManager; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\AuthorizeFactory} @@ -20,17 +21,17 @@ class AuthorizeFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\AuthorizeFactory::createService + * @covers \BjyAuthorize\Service\AuthorizeFactory::__invoke */ - public function testCreateServiceSetCacheOptionsIfCacheIsEnabledAndAdapterOptionsAreProvided() + public function testInvokeSetCacheOptionsIfCacheIsEnabledAndAdapterOptionsAreProvided() { - $serviceLocator = new ServiceManager(); - $serviceLocator->setService('BjyAuthorize\Config', ['cache_key' => 'bjyauthorize_acl']); + $serviceManager = new ServiceManager(); + $serviceManager->setService('BjyAuthorize\Config', ['cache_key' => 'bjyauthorize_acl']); $authorizeFactory = new AuthorizeFactory(); - $authorize = $authorizeFactory->createService($serviceLocator); + $authorize = $authorizeFactory($serviceManager, AuthorizeFactory::class); - $this->assertInstanceOf('BjyAuthorize\Service\Authorize', $authorize); + $this->assertInstanceOf(Authorize::class, $authorize); } } diff --git a/tests/BjyAuthorizeTest/Service/AuthorizeTest.php b/tests/BjyAuthorizeTest/Service/AuthorizeTest.php index b217b8a..09b69b4 100644 --- a/tests/BjyAuthorizeTest/Service/AuthorizeTest.php +++ b/tests/BjyAuthorizeTest/Service/AuthorizeTest.php @@ -8,9 +8,18 @@ namespace BjyAuthorizeTest\Service; +use BjyAuthorize\Provider\Identity\ProviderInterface; +use BjyAuthorize\Provider\Resource\Config as ResourceConfig; +use BjyAuthorize\Provider\Role\Config as RoleConfig; use BjyAuthorize\Service\Authorize; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Service\GuardsServiceFactory; +use BjyAuthorize\Service\ResourceProvidersServiceFactory; +use BjyAuthorize\Service\RoleProvidersServiceFactory; +use BjyAuthorize\Service\RuleProvidersServiceFactory; +use Laminas\Cache\Storage\Adapter\Filesystem; +use Laminas\Permissions\Acl\Acl; use Laminas\ServiceManager\ServiceManager; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\Authorize} @@ -20,48 +29,53 @@ class AuthorizeTest extends TestCase { /** @var ServiceManager */ - protected $serviceLocator; + protected $serviceManager; - public function setUp(): void + /** + * {@inheritDoc} + * @see \PHPUnit\Framework\TestCase::setUp() + */ + protected function setUp(): void { - $cache = $this->getMockBuilder('Laminas\Cache\Storage\Adapter\Filesystem') + $cache = $this->getMockBuilder(Filesystem::class) ->disableOriginalConstructor() ->getMock(); $cache->expects($this->any())->method('getItem'); $cache->expects($this->any())->method('setItem'); - $serviceLocator = new ServiceManager(); - $serviceLocator->setService('BjyAuthorize\Cache', $cache); - $serviceLocator->setService( - 'BjyAuthorize\Provider\Identity\ProviderInterface', - $this->createMock('BjyAuthorize\Provider\Identity\ProviderInterface') - ); - $serviceLocator->setService( + $serviceManager = new ServiceManager(); + $serviceManager->setService('BjyAuthorize\Cache', $cache); + $serviceManager->setService(ProviderInterface::class, $this->createMock(ProviderInterface::class)); + $serviceManager->setService( 'BjyAuthorize\RoleProviders', - $this->createMock('BjyAuthorize\Service\RoleProvidersServiceFactory') + $this->createMock(RoleProvidersServiceFactory::class) ); - - $serviceLocator->setService( + $serviceManager->setService( 'BjyAuthorize\ResourceProviders', - $this->createMock('BjyAuthorize\Service\ResourceProvidersServiceFactory') + $this->createMock(ResourceProvidersServiceFactory::class) ); - - $serviceLocator->setService( + $serviceManager->setService( 'BjyAuthorize\RuleProviders', - $this->createMock('BjyAuthorize\Service\RuleProvidersServiceFactory') - ); - $serviceLocator->setService( - 'BjyAuthorize\Guards', - $this->createMock('BjyAuthorize\Service\GuardsServiceFactory') + $this->createMock(RuleProvidersServiceFactory::class) ); - $serviceLocator->setService( + $serviceManager->setService('BjyAuthorize\Guards', $this->createMock(GuardsServiceFactory::class)); + $serviceManager->setService( 'BjyAuthorize\CacheKeyGenerator', function () { return 'bjyauthorize-acl'; } ); - $this->serviceLocator = $serviceLocator; + $this->serviceManager = $serviceManager; + } + + /** + * {@inheritDoc} + * @see \PHPUnit\Framework\TestCase::tearDown() + */ + protected function tearDown(): void + { + unset($this->serviceManager); } /** @@ -69,9 +83,9 @@ function () { */ public function testLoadLoadsAclFromCacheAndDoesNotBuildANewAclObject() { - $acl = $this->createMock('Laminas\Permissions\Acl\Acl'); + $acl = $this->createMock(Acl::class); - $cache = $this->getMockBuilder('Laminas\Cache\Storage\Adapter\Filesystem') + $cache = $this->getMockBuilder(Filesystem::class) ->disableOriginalConstructor() ->getMock(); @@ -89,10 +103,7 @@ function ($key, & $success) use ($acl) { ); $serviceManager = new ServiceManager(); - $serviceManager->setService( - 'BjyAuthorize\Provider\Identity\ProviderInterface', - $this->createMock('BjyAuthorize\Provider\Identity\ProviderInterface') - ); + $serviceManager->setService(ProviderInterface::class, $this->createMock(ProviderInterface::class)); $serviceManager->setService('BjyAuthorize\Cache', $cache); $serviceManager->setService( 'BjyAuthorize\CacheKeyGenerator', @@ -118,35 +129,29 @@ public function testLoadWritesAclToCacheIfCacheIsEnabledButAclIsNotStoredInCache $cache->expects($this->once())->method('getItem'); $cache->expects($this->once())->method('setItem'); - $serviceLocator = new ServiceManager(); - $serviceLocator->setService('BjyAuthorize\Cache', $cache); - $serviceLocator->setService( - 'BjyAuthorize\Provider\Identity\ProviderInterface', - $this->createMock('BjyAuthorize\Provider\Identity\ProviderInterface') - ); - $serviceLocator->setService( + $serviceManager = new ServiceManager(); + $serviceManager->setService('BjyAuthorize\Cache', $cache); + $serviceManager->setService(ProviderInterface::class, $this->createMock(ProviderInterface::class)); + $serviceManager->setService( 'BjyAuthorize\RoleProviders', - $this->createMock('BjyAuthorize\Service\RoleProvidersServiceFactory') + $this->createMock(RoleProvidersServiceFactory::class) ); - $serviceLocator->setService( + $serviceManager->setService( 'BjyAuthorize\ResourceProviders', - $this->createMock('BjyAuthorize\Service\ResourceProvidersServiceFactory') + $this->createMock(ResourceProvidersServiceFactory::class) ); - $serviceLocator->setService( + $serviceManager->setService( 'BjyAuthorize\RuleProviders', - $this->createMock('BjyAuthorize\Service\RuleProvidersServiceFactory') - ); - $serviceLocator->setService( - 'BjyAuthorize\Guards', - $this->createMock('BjyAuthorize\Service\GuardsServiceFactory') + $this->createMock(RuleProvidersServiceFactory::class) ); - $serviceLocator->setService( + $serviceManager->setService('BjyAuthorize\Guards', $this->createMock(GuardsServiceFactory::class)); + $serviceManager->setService( 'BjyAuthorize\CacheKeyGenerator', function () { return 'acl'; } ); - $authorize = new Authorize(['cache_key' => 'acl'], $serviceLocator); + $authorize = new Authorize(['cache_key' => 'acl'], $serviceManager); $authorize->load(); } @@ -156,12 +161,11 @@ function () { */ public function testCanAddResourceInterfaceToLoadResource() { - $serviceLocator = $this->serviceLocator; - $serviceLocator->setAllowOverride(true); + $serviceManager = $this->serviceManager; + $serviceManager->setAllowOverride(true); - $resourceProviderMock = $this->getMockBuilder('BjyAuthorize\Provider\Resource\Config') + $resourceProviderMock = $this->getMockBuilder(ResourceConfig::class) ->disableOriginalConstructor() - ->setMethods(['getResources']) ->getMock(); $resourceProviderMock @@ -173,10 +177,10 @@ public function testCanAddResourceInterfaceToLoadResource() ) ); - $serviceLocator->setService('BjyAuthorize\Provider\Resource\Config', $resourceProviderMock); - $serviceLocator->setService('BjyAuthorize\ResourceProviders', [$resourceProviderMock]); + $serviceManager->setService(ResourceConfig::class, $resourceProviderMock); + $serviceManager->setService('BjyAuthorize\ResourceProviders', [$resourceProviderMock]); - $authorize = new Authorize(['cache_key' => 'acl'], $this->serviceLocator); + $authorize = new Authorize(['cache_key' => 'acl'], $this->serviceManager); $authorize->load(); $acl = $authorize->getAcl(); @@ -189,10 +193,10 @@ public function testCanAddResourceInterfaceToLoadResource() */ public function testCanAddTraversableResourceToLoadResource() { - $serviceLocator = $this->serviceLocator; - $serviceLocator->setAllowOverride(true); + $serviceManager = $this->serviceManager; + $serviceManager->setAllowOverride(true); - $resourceProviderMock = $this->getMockBuilder('BjyAuthorize\Provider\Resource\Config') + $resourceProviderMock = $this->getMockBuilder(ResourceConfig::class) ->disableOriginalConstructor() ->getMock(); @@ -205,10 +209,10 @@ public function testCanAddTraversableResourceToLoadResource() ) ); - $serviceLocator->setService('BjyAuthorize\Provider\Resource\Config', $resourceProviderMock); - $serviceLocator->setService('BjyAuthorize\ResourceProviders', [$resourceProviderMock]); + $serviceManager->setService(ResourceConfig::class, $resourceProviderMock); + $serviceManager->setService('BjyAuthorize\ResourceProviders', [$resourceProviderMock]); - $authorize = new Authorize(['cache_key' => 'acl'], $serviceLocator); + $authorize = new Authorize(['cache_key' => 'acl'], $serviceManager); $acl = $authorize->getAcl(); @@ -223,10 +227,10 @@ public function testCanAddNonTraversableResourceToLoadResourceThrowsInvalidArgum { $this->expectException('\InvalidArgumentException'); - $serviceLocator = $this->serviceLocator; - $serviceLocator->setAllowOverride(true); + $serviceManager = $this->serviceManager; + $serviceManager->setAllowOverride(true); - $resourceProviderMock = $this->getMockBuilder('BjyAuthorize\Provider\Resource\Config') + $resourceProviderMock = $this->getMockBuilder(ResourceConfig::class) ->disableOriginalConstructor() ->getMock(); @@ -239,10 +243,10 @@ public function testCanAddNonTraversableResourceToLoadResourceThrowsInvalidArgum ) ); - $serviceLocator->setService('BjyAuthorize\Provider\Resource\Config', $resourceProviderMock); - $serviceLocator->setService('BjyAuthorize\ResourceProviders', [$resourceProviderMock]); + $serviceManager->setService(ResourceConfig::class, $resourceProviderMock); + $serviceManager->setService('BjyAuthorize\ResourceProviders', [$resourceProviderMock]); - $authorize = new Authorize(['cache_key' => 'acl'], $this->serviceLocator); + $authorize = new Authorize(['cache_key' => 'acl'], $this->serviceManager); $authorize->load(); } @@ -251,10 +255,10 @@ public function testCanAddNonTraversableResourceToLoadResourceThrowsInvalidArgum */ public function testCanAddTraversableRoleToLoadRole() { - $serviceLocator = $this->serviceLocator; - $serviceLocator->setAllowOverride(true); + $serviceManager = $this->serviceManager; + $serviceManager->setAllowOverride(true); - $roleProviderMock = $this->getMockBuilder('BjyAuthorize\Provider\Role\Config') + $roleProviderMock = $this->getMockBuilder(RoleConfig::class) ->disableOriginalConstructor() ->getMock(); @@ -267,10 +271,10 @@ public function testCanAddTraversableRoleToLoadRole() ) ); - $serviceLocator->setService('BjyAuthorize\Provider\Role\Config', $roleProviderMock); - $serviceLocator->setService('BjyAuthorize\RoleProviders', [$roleProviderMock]); + $serviceManager->setService(RoleConfig::class, $roleProviderMock); + $serviceManager->setService('BjyAuthorize\RoleProviders', [$roleProviderMock]); - $authorize = new Authorize(['cache_key' => 'acl'], $this->serviceLocator); + $authorize = new Authorize(['cache_key' => 'acl'], $this->serviceManager); $authorize->load(); $acl = $authorize->getAcl(); diff --git a/tests/BjyAuthorizeTest/Service/BaseProvidersServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/BaseProvidersServiceFactoryTest.php index bc9c7ce..a64787a 100644 --- a/tests/BjyAuthorizeTest/Service/BaseProvidersServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/BaseProvidersServiceFactoryTest.php @@ -11,6 +11,9 @@ namespace BjyAuthorizeTest\Service; use \PHPUnit\Framework\TestCase; +use Interop\Container\ContainerInterface; +use BjyAuthorize\Service\BaseProvidersServiceFactory; +use BjyAuthorize\Provider\Resource\ProviderInterface; /** * Test for {@see \BjyAuthorize\Service\ResourceProvidersServiceFactory} @@ -20,23 +23,23 @@ class BaseProvidersServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\BaseProvidersServiceFactory::createService + * @covers \BjyAuthorize\Service\BaseProvidersServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = $this->getMockForAbstractClass('BjyAuthorize\\Service\\BaseProvidersServiceFactory'); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $foo = $this->createMock('BjyAuthorize\\Provider\\Resource\\ProviderInterface'); - $bar = $this->createMock('BjyAuthorize\\Provider\\Resource\\ProviderInterface'); - $config = [ + $factory = $this->getMockForAbstractClass(BaseProvidersServiceFactory::class); + $container = $this->createMock(ContainerInterface::class); + $foo = $this->createMock(ProviderInterface::class); + $bar = $this->createMock(ProviderInterface::class); + $config = [ 'providers' => [ - 'foo' => [], - 'bar' => [], + 'foo' => [], + 'bar' => [], __NAMESPACE__ . '\\MockProvider' => ['option' => 'value'], ], ]; - $serviceLocator + $container ->expects($this->any()) ->method('has') ->will( @@ -47,7 +50,7 @@ function ($serviceName) { ) ); - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with($this->logicalOr('BjyAuthorize\\Config', 'foo', 'bar')) @@ -67,7 +70,7 @@ function ($serviceName) use ($foo, $bar, $config) { ) ); - $providers = $factory->createService($serviceLocator); + $providers = $factory($container, BaseProvidersServiceFactory::class); $this->assertCount(3, $providers); $this->assertContains($foo, $providers); @@ -88,6 +91,6 @@ function ($item) { $this->assertInstanceOf(__NAMESPACE__ . '\\MockProvider', $invokableProvider); $this->assertSame(['option' => 'value'], $invokableProvider->options); - $this->assertSame($serviceLocator, $invokableProvider->serviceLocator); + $this->assertSame($container, $invokableProvider->container); } } diff --git a/tests/BjyAuthorizeTest/Service/CacheFactoryTest.php b/tests/BjyAuthorizeTest/Service/CacheFactoryTest.php index 85a786d..535b6d9 100644 --- a/tests/BjyAuthorizeTest/Service/CacheFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/CacheFactoryTest.php @@ -9,7 +9,9 @@ namespace BjyAuthorizeTest\Service; use BjyAuthorize\Service\CacheFactory; -use \PHPUnit\Framework\TestCase; +use Interop\Container\ContainerInterface; +use Laminas\Cache\Storage\Adapter\Memory; +use PHPUnit\Framework\TestCase; /** * PHPUnit tests for {@see \BjyAuthorize\Service\CacheFactory} @@ -19,23 +21,23 @@ class CacheFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\CacheFactory::createService + * @covers \BjyAuthorize\Service\CacheFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $container = $this->createMock(ContainerInterface::class); + $config = [ 'cache_options' => [ - 'adapter' => [ + 'adapter' => [ 'name' => 'memory', ], - 'plugins' => [ + 'plugins' => [ 'serializer', ] ] ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') @@ -43,6 +45,6 @@ public function testCreateService() $factory = new CacheFactory(); - $this->assertInstanceOf('Laminas\Cache\Storage\Adapter\Memory', $factory->createService($serviceLocator)); + $this->assertInstanceOf(Memory::class, $factory($container, CacheFactory::class)); } } diff --git a/tests/BjyAuthorizeTest/Service/CacheKeyGeneratorFactoryTest.php b/tests/BjyAuthorizeTest/Service/CacheKeyGeneratorFactoryTest.php index 8b81d9e..8af8389 100644 --- a/tests/BjyAuthorizeTest/Service/CacheKeyGeneratorFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/CacheKeyGeneratorFactoryTest.php @@ -9,7 +9,8 @@ namespace BjyAuthorizeTest\Service; use BjyAuthorize\Service\CacheKeyGeneratorFactory; -use \PHPUnit\Framework\TestCase; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * PHPUnit tests for {@see \BjyAuthorize\Service\CacheKeyGeneratorFactory} @@ -19,14 +20,14 @@ class CacheKeyGeneratorFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\CacheKeyGeneratorFactory::createService + * @covers \BjyAuthorize\Service\CacheKeyGeneratorFactory::__invoke */ - public function testCreateServiceReturnsDefaultCallable() + public function testInvokeReturnsDefaultCallable() { - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = []; + $container = $this->createMock(ContainerInterface::class); + $config = []; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') @@ -34,22 +35,22 @@ public function testCreateServiceReturnsDefaultCallable() $factory = new CacheKeyGeneratorFactory(); - $cacheKeyGenerator = $factory->createService($serviceLocator); + $cacheKeyGenerator = $factory($container, CacheKeyGeneratorFactory::class); $this->assertTrue(is_callable($cacheKeyGenerator)); $this->assertEquals('bjyauthorize_acl', $cacheKeyGenerator()); } /** - * @covers \BjyAuthorize\Service\CacheKeyGeneratorFactory::createService + * @covers \BjyAuthorize\Service\CacheKeyGeneratorFactory::__invoke */ - public function testCreateServiceReturnsCacheKeyGeneratorCallable() + public function testInvokeReturnsCacheKeyGeneratorCallable() { - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $container = $this->createMock(ContainerInterface::class); + $config = [ 'cache_key' => 'some_new_value' ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') @@ -57,7 +58,7 @@ public function testCreateServiceReturnsCacheKeyGeneratorCallable() $factory = new CacheKeyGeneratorFactory(); - $cacheKeyGenerator = $factory->createService($serviceLocator); + $cacheKeyGenerator = $factory($container, CacheKeyGeneratorFactory::class); $this->assertTrue(is_callable($cacheKeyGenerator)); $this->assertEquals('some_new_value', $cacheKeyGenerator()); } diff --git a/tests/BjyAuthorizeTest/Service/ConfigResourceProviderServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/ConfigResourceProviderServiceFactoryTest.php index 0ecb58b..e6baa18 100644 --- a/tests/BjyAuthorizeTest/Service/ConfigResourceProviderServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/ConfigResourceProviderServiceFactoryTest.php @@ -10,8 +10,10 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Provider\Resource\Config; use BjyAuthorize\Service\ConfigResourceProviderServiceFactory; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\ConfigResourceProviderServiceFactory} @@ -21,26 +23,26 @@ class ConfigResourceProviderServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\ConfigResourceProviderServiceFactory::createService + * @covers \BjyAuthorize\Service\ConfigResourceProviderServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new ConfigResourceProviderServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $factory = new ConfigResourceProviderServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $config = [ 'resource_providers' => [ - 'BjyAuthorize\Provider\Resource\Config' => [], + Config::class => [], ], ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $guard = $factory->createService($serviceLocator); + $guard = $factory($container, ConfigResourceProviderServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\Provider\\Resource\\Config', $guard); + $this->assertInstanceOf(Config::class, $guard); } } diff --git a/tests/BjyAuthorizeTest/Service/ConfigRoleProviderServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/ConfigRoleProviderServiceFactoryTest.php index baa650b..5529b91 100644 --- a/tests/BjyAuthorizeTest/Service/ConfigRoleProviderServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/ConfigRoleProviderServiceFactoryTest.php @@ -12,6 +12,8 @@ use \PHPUnit\Framework\TestCase; use BjyAuthorize\Service\ConfigRoleProviderServiceFactory; +use BjyAuthorize\Provider\Role\Config; +use Interop\Container\ContainerInterface; /** * Test for {@see \BjyAuthorize\Service\ConfigRoleProviderServiceFactory} @@ -21,26 +23,26 @@ class ConfigRoleProviderServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\ConfigRoleProviderServiceFactory::createService + * @covers \BjyAuthorize\Service\ConfigRoleProviderServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new ConfigRoleProviderServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $factory = new ConfigRoleProviderServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $config = [ 'role_providers' => [ - 'BjyAuthorize\Provider\Role\Config' => [], + Config::class => [], ], ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $guard = $factory->createService($serviceLocator); + $guard = $factory($container,ConfigRoleProviderServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\Provider\\Role\\Config', $guard); + $this->assertInstanceOf(Config::class, $guard); } } diff --git a/tests/BjyAuthorizeTest/Service/ConfigRuleProviderServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/ConfigRuleProviderServiceFactoryTest.php index 861c161..48135c8 100644 --- a/tests/BjyAuthorizeTest/Service/ConfigRuleProviderServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/ConfigRuleProviderServiceFactoryTest.php @@ -10,8 +10,10 @@ namespace BjyAuthorizeTest\Service; +use BjyAuthorize\Provider\Rule\Config; use BjyAuthorize\Service\ConfigRuleProviderServiceFactory; -use \PHPUnit\Framework\TestCase; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\ConfigRuleProviderServiceFactory} @@ -21,20 +23,20 @@ class ConfigRuleProviderServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\ConfigRuleProviderServiceFactory::createService + * @covers \BjyAuthorize\Service\ConfigRuleProviderServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new ConfigRuleProviderServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = ['rule_providers' => ['BjyAuthorize\\Provider\\Rule\\Config' => []]]; + $factory = new ConfigRuleProviderServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $config = ['rule_providers' => [Config::class => []]]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\\Config') ->will($this->returnValue($config)); - $this->assertInstanceOf('BjyAuthorize\\Provider\\Rule\\Config', $factory->createService($serviceLocator)); + $this->assertInstanceOf(Config::class, $factory($container, ConfigRuleProviderServiceFactory::class)); } } diff --git a/tests/BjyAuthorizeTest/Service/ConfigServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/ConfigServiceFactoryTest.php index d99c74e..aa39c9f 100644 --- a/tests/BjyAuthorizeTest/Service/ConfigServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/ConfigServiceFactoryTest.php @@ -10,8 +10,9 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; use BjyAuthorize\Service\ConfigServiceFactory; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\ConfigServiceFactory} @@ -21,18 +22,18 @@ class ConfigServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\ConfigServiceFactory::createService + * @covers \BjyAuthorize\Service\ConfigServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new ConfigServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); + $factory = new ConfigServiceFactory(); + $container = $this->createMock(ContainerInterface::class); - $serviceLocator + $container ->expects($this->any()) ->method('get') ->will($this->returnValue(['bjyauthorize' => ['foo' => 'bar']])); - $this->assertSame(['foo' => 'bar'], $factory->createService($serviceLocator)); + $this->assertSame(['foo' => 'bar'], $factory($container, ConfigServiceFactory::class)); } } diff --git a/tests/BjyAuthorizeTest/Service/ControllerGuardServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/ControllerGuardServiceFactoryTest.php index 7ba870d..fd0da7e 100644 --- a/tests/BjyAuthorizeTest/Service/ControllerGuardServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/ControllerGuardServiceFactoryTest.php @@ -10,8 +10,10 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Guard\Controller; use BjyAuthorize\Service\ControllerGuardServiceFactory; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\ControllerGuardServiceFactory} @@ -21,26 +23,26 @@ class ControllerGuardServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\ControllerGuardServiceFactory::createService + * @covers \BjyAuthorize\Service\ControllerGuardServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new ControllerGuardServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $factory = new ControllerGuardServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $config = [ 'guards' => [ - 'BjyAuthorize\\Guard\\Controller' => [], + Controller::class => [], ], ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $guard = $factory->createService($serviceLocator); + $guard = $factory($container, ControllerGuardServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\Guard\\Controller', $guard); + $this->assertInstanceOf(Controller::class, $guard); } } diff --git a/tests/BjyAuthorizeTest/Service/IdentityProviderServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/IdentityProviderServiceFactoryTest.php index fa37b38..ecd5c23 100644 --- a/tests/BjyAuthorizeTest/Service/IdentityProviderServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/IdentityProviderServiceFactoryTest.php @@ -10,8 +10,10 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Provider\Identity\ProviderInterface; use BjyAuthorize\Service\IdentityProviderServiceFactory; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\IdentityProviderServiceFactory} @@ -21,16 +23,16 @@ class IdentityProviderServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\IdentityProviderServiceFactory::createService + * @covers \BjyAuthorize\Service\IdentityProviderServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new IdentityProviderServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $identityProvider = $this->createMock('BjyAuthorize\\Provider\\Identity\\ProviderInterface'); - $config = ['identity_provider' => 'foo']; + $factory = new IdentityProviderServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $identityProvider = $this->createMock(ProviderInterface::class); + $config = ['identity_provider' => 'foo']; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with($this->logicalOr('BjyAuthorize\\Config', 'foo')) @@ -46,6 +48,6 @@ function ($serviceName) use ($identityProvider, $config) { ) ); - $this->assertSame($identityProvider, $factory->createService($serviceLocator)); + $this->assertSame($identityProvider, $factory($container, IdentityProviderServiceFactory::class)); } } diff --git a/tests/BjyAuthorizeTest/Service/LaminasDbRoleProviderServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/LaminasDbRoleProviderServiceFactoryTest.php index 9cbc79b..3be89c2 100644 --- a/tests/BjyAuthorizeTest/Service/LaminasDbRoleProviderServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/LaminasDbRoleProviderServiceFactoryTest.php @@ -12,6 +12,8 @@ use \PHPUnit\Framework\TestCase; use BjyAuthorize\Service\LaminasDbRoleProviderServiceFactory; +use BjyAuthorize\Provider\Role\LaminasDb; +use Interop\Container\ContainerInterface; /** * Test for {@see \BjyAuthorize\Service\LaminasDbRoleProviderServiceFactory} @@ -21,26 +23,26 @@ class LaminasDbRoleProviderServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\LaminasDbRoleProviderServiceFactory::createService + * @covers \BjyAuthorize\Service\LaminasDbRoleProviderServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new LaminasDbRoleProviderServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $factory = new LaminasDbRoleProviderServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $config = [ 'role_providers' => [ - 'BjyAuthorize\Provider\Role\LaminasDb' => [], + LaminasDb::class => [], ], ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $guard = $factory->createService($serviceLocator); + $guard = $factory($container, LaminasDbRoleProviderServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\Provider\\Role\\LaminasDb', $guard); + $this->assertInstanceOf(LaminasDb::class, $guard); } } diff --git a/tests/BjyAuthorizeTest/Service/MockProvider.php b/tests/BjyAuthorizeTest/Service/MockProvider.php index e7337af..f2cf280 100644 --- a/tests/BjyAuthorizeTest/Service/MockProvider.php +++ b/tests/BjyAuthorizeTest/Service/MockProvider.php @@ -11,6 +11,8 @@ namespace BjyAuthorizeTest\Service; use Laminas\ServiceManager\ServiceLocatorInterface; +use Interop\Container\Exception\ContainerException; +use Interop\Container\ContainerInterface; /** * @author Marco Pivetta s @@ -23,17 +25,17 @@ class MockProvider public $options; /** - * @var \Laminas\ServiceManager\ServiceLocatorInterface + * @var \Interop\Container\ContainerInterface */ - public $serviceLocator; + public $container; /** - * @param array $options - * @param \Laminas\ServiceManager\ServiceLocatorInterface $serviceLocator + * @param array $options + * @param \Interop\Container\ContainerInterface $container */ - public function __construct(array $options, ServiceLocatorInterface $serviceLocator) + public function __construct(array $options, ContainerInterface $container) { - $this->options = $options; - $this->serviceLocator = $serviceLocator; + $this->options = $options; + $this->container = $container; } } diff --git a/tests/BjyAuthorizeTest/Service/ObjectRepositoryRoleProviderFactoryTest.php b/tests/BjyAuthorizeTest/Service/ObjectRepositoryRoleProviderFactoryTest.php index 563325a..d9d0271 100644 --- a/tests/BjyAuthorizeTest/Service/ObjectRepositoryRoleProviderFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/ObjectRepositoryRoleProviderFactoryTest.php @@ -8,8 +8,12 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Provider\Role\ObjectRepositoryProvider; use BjyAuthorize\Service\ObjectRepositoryRoleProviderFactory; +use Doctrine\Persistence\ObjectManager; +use Doctrine\Persistence\ObjectRepository; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * {@see \BjyAuthorize\Service\ObjectRepositoryRoleProviderFactory} test @@ -18,53 +22,45 @@ */ class ObjectRepositoryRoleProviderFactoryTest extends TestCase { - private $locator; - private $entityManager; - private $repository; - private $factory; - - protected function setUp(): void - { - $this->locator = $this->createMock('Laminas\ServiceManager\ServiceLocatorInterface'); - $this->entityManager = $this->createMock('Doctrine\Common\Persistence\ObjectManager'); - $this->repository = $this->createMock('Doctrine\Common\Persistence\ObjectRepository'); - $this->factory = new ObjectRepositoryRoleProviderFactory(); - } - /** - * @covers \BjyAuthorize\Service\ObjectRepositoryRoleProviderFactory::createService + * @covers \BjyAuthorize\Service\ObjectRepositoryRoleProviderFactory::__invoke */ - public function testCreateService() + public function testInvoke() { + $container = $this->createMock(ContainerInterface::class); + $entityManager = $this->createMock(ObjectManager::class); + $repository = $this->createMock(ObjectRepository::class); + $factory = new ObjectRepositoryRoleProviderFactory(); + $testClassName = 'TheTestClass'; $config = [ 'role_providers' => [ - 'BjyAuthorize\Provider\Role\ObjectRepositoryProvider' => [ + ObjectRepositoryProvider::class => [ 'role_entity_class' => $testClassName, - 'object_manager' => 'doctrine.entitymanager.orm_default', + 'object_manager' => 'doctrine.entitymanager.orm_default', ], ], ]; - $this->entityManager->expects($this->once()) + $entityManager->expects($this->once()) ->method('getRepository') ->with($testClassName) - ->will($this->returnValue($this->repository)); + ->will($this->returnValue($repository)); - $this->locator->expects($this->at(0)) + $container->expects($this->at(0)) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $this->locator->expects($this->at(1)) + $container->expects($this->at(1)) ->method('get') ->with('doctrine.entitymanager.orm_default') - ->will($this->returnValue($this->entityManager)); + ->will($this->returnValue($entityManager)); $this->assertInstanceOf( - 'BjyAuthorize\Provider\Role\ObjectRepositoryProvider', - $this->factory->createService($this->locator) + ObjectRepositoryProvider::class, + $factory($container, ObjectRepositoryRoleProviderFactory::class) ); } } diff --git a/tests/BjyAuthorizeTest/Service/RoleCollectorServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/RoleCollectorServiceFactoryTest.php index e08118d..3012268 100644 --- a/tests/BjyAuthorizeTest/Service/RoleCollectorServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/RoleCollectorServiceFactoryTest.php @@ -10,8 +10,11 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Collector\RoleCollector; +use BjyAuthorize\Provider\Identity\ProviderInterface; use BjyAuthorize\Service\RoleCollectorServiceFactory; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\RoleCollectorServiceFactory} @@ -21,22 +24,22 @@ class RoleCollectorServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\RoleCollectorServiceFactory::createService + * @covers \BjyAuthorize\Service\RoleCollectorServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new RoleCollectorServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $identityProvider = $this->createMock('BjyAuthorize\\Provider\\Identity\\ProviderInterface'); + $factory = new RoleCollectorServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $identityProvider = $this->createMock(ProviderInterface::class); - $serviceLocator + $container ->expects($this->any()) ->method('get') - ->with('BjyAuthorize\Provider\Identity\ProviderInterface') + ->with(ProviderInterface::class) ->will($this->returnValue($identityProvider)); - $collector = $factory->createService($serviceLocator); + $collector = $factory($container, RoleCollectorServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\Collector\\RoleCollector', $collector); + $this->assertInstanceOf(RoleCollector::class, $collector); } } diff --git a/tests/BjyAuthorizeTest/Service/RouteGuardServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/RouteGuardServiceFactoryTest.php index 98dc195..398f0ac 100644 --- a/tests/BjyAuthorizeTest/Service/RouteGuardServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/RouteGuardServiceFactoryTest.php @@ -10,8 +10,11 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; +use BjyAuthorize\Guard\Route; use BjyAuthorize\Service\RouteGuardServiceFactory; +use BjyAuthorize\Service\UnauthorizedStrategyServiceFactory; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\RouteGuardServiceFactory} @@ -21,26 +24,26 @@ class RouteGuardServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\RouteGuardServiceFactory::createService + * @covers \BjyAuthorize\Service\RouteGuardServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new RouteGuardServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $factory = new RouteGuardServiceFactory(); + $container = $this->createMock(ContainerInterface::class); + $config = [ 'guards' => [ - 'BjyAuthorize\\Guard\\Route' => [], + Route::class => [], ], ]; - $serviceLocator + $container ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $guard = $factory->createService($serviceLocator); + $guard = $factory($container, UnauthorizedStrategyServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\Guard\\Route', $guard); + $this->assertInstanceOf(Route::class, $guard); } } diff --git a/tests/BjyAuthorizeTest/Service/UnauthorizedStrategyServiceFactoryTest.php b/tests/BjyAuthorizeTest/Service/UnauthorizedStrategyServiceFactoryTest.php index f9d2662..4614d28 100644 --- a/tests/BjyAuthorizeTest/Service/UnauthorizedStrategyServiceFactoryTest.php +++ b/tests/BjyAuthorizeTest/Service/UnauthorizedStrategyServiceFactoryTest.php @@ -10,8 +10,10 @@ namespace BjyAuthorizeTest\Service; -use \PHPUnit\Framework\TestCase; use BjyAuthorize\Service\UnauthorizedStrategyServiceFactory; +use BjyAuthorize\View\UnauthorizedStrategy; +use Interop\Container\ContainerInterface; +use PHPUnit\Framework\TestCase; /** * Test for {@see \BjyAuthorize\Service\UnauthorizedStrategyServiceFactory} @@ -21,25 +23,25 @@ class UnauthorizedStrategyServiceFactoryTest extends TestCase { /** - * @covers \BjyAuthorize\Service\UnauthorizedStrategyServiceFactory::createService + * @covers \BjyAuthorize\Service\UnauthorizedStrategyServiceFactory::__invoke */ - public function testCreateService() + public function testInvoke() { - $factory = new UnauthorizedStrategyServiceFactory(); - $serviceLocator = $this->createMock('Laminas\\ServiceManager\\ServiceLocatorInterface'); - $config = [ + $factory = new UnauthorizedStrategyServiceFactory(); + $containerInterface = $this->createMock(ContainerInterface::class); + $config = [ 'template' => 'foo/bar', ]; - $serviceLocator + $containerInterface ->expects($this->any()) ->method('get') ->with('BjyAuthorize\Config') ->will($this->returnValue($config)); - $strategy = $factory->createService($serviceLocator); + $strategy = $factory($containerInterface, UnauthorizedStrategyServiceFactory::class); - $this->assertInstanceOf('BjyAuthorize\\View\\UnauthorizedStrategy', $strategy); + $this->assertInstanceOf(UnauthorizedStrategy::class, $strategy); $this->assertSame('foo/bar', $strategy->getTemplate()); } } diff --git a/tests/TestConfiguration.php b/tests/TestConfiguration.php index bd39063..f954996 100644 --- a/tests/TestConfiguration.php +++ b/tests/TestConfiguration.php @@ -7,16 +7,15 @@ * @author Marco Pivetta */ -return array( - 'modules' => array( - 'ZfcBase', - 'ZfcUser', +return [ + 'modules' => [ + 'LmcUser', 'BjyAuthorize' - ), - 'module_listener_options' => array( - 'config_glob_paths' => array( + ], + 'module_listener_options' => [ + 'config_glob_paths' => [ __DIR__ . '/testing.config.php', - ), - 'module_paths' => array(), - ), -); + ], + 'module_paths' => [], + ], +]; diff --git a/view/zend-developer-tools/toolbar/bjy-authorize-role.phtml b/view/laminas-developer-tools/toolbar/bjy-authorize-role.phtml similarity index 80% rename from view/zend-developer-tools/toolbar/bjy-authorize-role.phtml rename to view/laminas-developer-tools/toolbar/bjy-authorize-role.phtml index cf05c37..a684605 100644 --- a/view/zend-developer-tools/toolbar/bjy-authorize-role.phtml +++ b/view/laminas-developer-tools/toolbar/bjy-authorize-role.phtml @@ -3,11 +3,11 @@ $roles = $collector->getCollectedRoles(); $rolesCount = count($roles); ?> -
-
+
+
BjyAuthorize Current Identity Roles - - + + escapeHtml(reset($roles)); @@ -18,11 +18,11 @@ $rolesCount = count($roles);
-
- - BjyAuthorize +
+ + BjyAuthorize
- Identity Roles - Identity Roles -
- - + + escapeHtml($role) ?>