From 7696e11a59c4a171e8e9e17083dbc8332408bec7 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Mon, 6 May 2019 23:55:26 +0200 Subject: [PATCH 01/11] working on twig 3 support --- composer.json | 4 +-- composer.lock | 57 ++++++++++++++++++++-------------------- src/Twig/MapLoader.php | 10 +++---- src/Twig/StackLoader.php | 2 +- 4 files changed, 36 insertions(+), 37 deletions(-) diff --git a/composer.json b/composer.json index ed87a66..bac1616 100644 --- a/composer.json +++ b/composer.json @@ -23,8 +23,8 @@ } ], "require": { - "php": "^7.1", - "twig/twig": "^2.8.1", + "php": "^7.2", + "twig/twig": "3.x-dev", "zendframework/zend-mvc": "^3.0", "zendframework/zend-view": "^2.7", "zendframework/zend-servicemanager": "^3.0", diff --git a/composer.lock b/composer.lock index b86f92d..f15de96 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "5d542868e371b6e830e9428a53ddc817", + "content-hash": "68ef3ee744610d1bb0035f078ca25d88", "packages": [ { "name": "container-interop/container-interop", @@ -205,20 +205,20 @@ }, { "name": "twig/twig", - "version": "v2.8.1", + "version": "3.x-dev", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "91cc2594d3143761ce0399c1caffd0b500ffe5b9" + "reference": "8d82f62418876c187499beb74d816c00a4be33f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/91cc2594d3143761ce0399c1caffd0b500ffe5b9", - "reference": "91cc2594d3143761ce0399c1caffd0b500ffe5b9", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/8d82f62418876c187499beb74d816c00a4be33f7", + "reference": "8d82f62418876c187499beb74d816c00a4be33f7", "shasum": "" }, "require": { - "php": "^7.0", + "php": "^7.2", "symfony/polyfill-ctype": "^1.8", "symfony/polyfill-mbstring": "^1.3" }, @@ -230,13 +230,10 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev" + "dev-master": "3.0-dev" } }, "autoload": { - "psr-0": { - "Twig_": "lib/" - }, "psr-4": { "Twig\\": "src/" } @@ -268,7 +265,7 @@ "keywords": [ "templating" ], - "time": "2019-04-16T17:14:24+00:00" + "time": "2019-05-01T14:00:56+00:00" }, { "name": "zendframework/zend-config", @@ -1481,16 +1478,16 @@ }, { "name": "phpdocumentor/reflection-docblock", - "version": "4.3.0", + "version": "4.3.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "94fd0001232e47129dd3504189fa1c7225010d08" + "reference": "bdd9f737ebc2a01c06ea7ff4308ec6697db9b53c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/94fd0001232e47129dd3504189fa1c7225010d08", - "reference": "94fd0001232e47129dd3504189fa1c7225010d08", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/bdd9f737ebc2a01c06ea7ff4308ec6697db9b53c", + "reference": "bdd9f737ebc2a01c06ea7ff4308ec6697db9b53c", "shasum": "" }, "require": { @@ -1528,7 +1525,7 @@ } ], "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", - "time": "2017-11-30T07:14:17+00:00" + "time": "2019-04-30T17:48:53+00:00" }, { "name": "phpdocumentor/type-resolver", @@ -1894,16 +1891,16 @@ }, { "name": "phpunit/phpunit", - "version": "7.5.8", + "version": "7.5.9", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c29c0525cf4572c11efe1db49a8b8aee9dfac58a" + "reference": "134669cf0eeac3f79bc7f0c793efbc158bffc160" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c29c0525cf4572c11efe1db49a8b8aee9dfac58a", - "reference": "c29c0525cf4572c11efe1db49a8b8aee9dfac58a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/134669cf0eeac3f79bc7f0c793efbc158bffc160", + "reference": "134669cf0eeac3f79bc7f0c793efbc158bffc160", "shasum": "" }, "require": { @@ -1974,7 +1971,7 @@ "testing", "xunit" ], - "time": "2019-03-26T13:23:54+00:00" + "time": "2019-04-19T15:50:46+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -2143,16 +2140,16 @@ }, { "name": "sebastian/environment", - "version": "4.1.0", + "version": "4.2.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "6fda8ce1974b62b14935adc02a9ed38252eca656" + "reference": "f2a2c8e1c97c11ace607a7a667d73d47c19fe404" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/6fda8ce1974b62b14935adc02a9ed38252eca656", - "reference": "6fda8ce1974b62b14935adc02a9ed38252eca656", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/f2a2c8e1c97c11ace607a7a667d73d47c19fe404", + "reference": "f2a2c8e1c97c11ace607a7a667d73d47c19fe404", "shasum": "" }, "require": { @@ -2167,7 +2164,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.1-dev" + "dev-master": "4.2-dev" } }, "autoload": { @@ -2192,7 +2189,7 @@ "environment", "hhvm" ], - "time": "2019-02-01T05:27:49+00:00" + "time": "2019-05-05T09:05:15+00:00" }, { "name": "sebastian/exporter", @@ -2704,11 +2701,13 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "twig/twig": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": "^7.1" + "php": "^7.2" }, "platform-dev": [] } diff --git a/src/Twig/MapLoader.php b/src/Twig/MapLoader.php index ea53bb4..a20140a 100644 --- a/src/Twig/MapLoader.php +++ b/src/Twig/MapLoader.php @@ -11,7 +11,7 @@ use function filemtime; use function sprintf; -class MapLoader implements Loader\LoaderInterface, Loader\SourceContextLoaderInterface +class MapLoader implements Loader\LoaderInterface { /** * Array of templates to filenames. @@ -42,7 +42,7 @@ public function add($name, $path) /** * {@inheritDoc} */ - public function exists($name) + public function exists($name): bool { return array_key_exists($name, $this->map); } @@ -50,7 +50,7 @@ public function exists($name) /** * {@inheritDoc} */ - public function getSourceContext($name) + public function getSourceContext($name): Source { if (!$this->exists($name)) { throw new Error\LoaderError(sprintf( @@ -70,7 +70,7 @@ public function getSourceContext($name) /** * {@inheritDoc} */ - public function getCacheKey($name) + public function getCacheKey($name): string { return $name; } @@ -78,7 +78,7 @@ public function getCacheKey($name) /** * {@inheritDoc} */ - public function isFresh($name, $time) + public function isFresh($name, $time): bool { return filemtime($this->map[$name]) <= $time; } diff --git a/src/Twig/StackLoader.php b/src/Twig/StackLoader.php index 486d60c..20e8698 100644 --- a/src/Twig/StackLoader.php +++ b/src/Twig/StackLoader.php @@ -60,7 +60,7 @@ public function getDefaultSuffix() * {@inheritDoc} * @throws Error\LoaderError */ - protected function findTemplate($name, $throw = true) + protected function findTemplate($name, $throw = true): string { $name = (string)$name; From c6a1fdb7a05edbb7fd770eda124f0570c582383e Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Tue, 7 May 2019 21:21:18 +0200 Subject: [PATCH 02/11] fixing tests --- composer.lock | 2 +- tests/ZfcTwigTest/View/TwigResolverTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.lock b/composer.lock index f15de96..7e10843 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "68ef3ee744610d1bb0035f078ca25d88", + "content-hash": "34c75291acaec49833d5ad5ac97d45ac", "packages": [ { "name": "container-interop/container-interop", diff --git a/tests/ZfcTwigTest/View/TwigResolverTest.php b/tests/ZfcTwigTest/View/TwigResolverTest.php index 2986ce1..394459a 100644 --- a/tests/ZfcTwigTest/View/TwigResolverTest.php +++ b/tests/ZfcTwigTest/View/TwigResolverTest.php @@ -29,7 +29,7 @@ public function testResolve() } /** - * @expectedException \Twig_Error_Loader + * @expectedException \Twig\Error\LoaderError * @expectedExceptionMessage Template "key2" is not defined. */ public function testResolveError() From 00492a9afe2afe244ff4a7913a6ce0dd59d06de7 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Tue, 7 May 2019 21:29:54 +0200 Subject: [PATCH 03/11] travis update --- .travis.yml | 9 --- composer.json | 2 +- composer.lock | 69 +++++++++++---------- tests/ZfcTwigTest/View/TwigRendererTest.php | 4 +- tests/ZfcTwigTest/View/TwigResolverTest.php | 9 ++- tests/ZfcTwigTest/View/TwigStrategyTest.php | 4 +- 6 files changed, 44 insertions(+), 53 deletions(-) diff --git a/.travis.yml b/.travis.yml index ec22b3a..96b93d1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,15 +14,6 @@ cache: matrix: include: - - php: 7.1 - env: - - DEPS=lowest - - php: 7.1 - env: - - DEPS=locked - - php: 7.1 - env: - - DEPS=latest - php: 7.2 env: - DEPS=lowest diff --git a/composer.json b/composer.json index daab47e..d37df45 100644 --- a/composer.json +++ b/composer.json @@ -43,7 +43,7 @@ "require-dev": { "zendframework/zend-navigation": "^2.7", "zendframework/zend-modulemanager": "^2.7", - "phpunit/phpunit": "^7.5" + "phpunit/phpunit": "^8.1.3" }, "replace": { "zf-commons/zfc-twig": "self.version" diff --git a/composer.lock b/composer.lock index 7e10843..153d7ef 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "34c75291acaec49833d5ad5ac97d45ac", + "content-hash": "2e3860b594362f9e15f566693e9d211a", "packages": [ { "name": "container-interop/container-interop", @@ -1639,40 +1639,40 @@ }, { "name": "phpunit/php-code-coverage", - "version": "6.1.4", + "version": "7.0.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d" + "reference": "0317a769a81845c390e19684d9ba25d7f6aa4707" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", - "reference": "807e6013b00af69b6c5d9ceb4282d0393dbb9d8d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/0317a769a81845c390e19684d9ba25d7f6aa4707", + "reference": "0317a769a81845c390e19684d9ba25d7f6aa4707", "shasum": "" }, "require": { "ext-dom": "*", "ext-xmlwriter": "*", - "php": "^7.1", - "phpunit/php-file-iterator": "^2.0", + "php": "^7.2", + "phpunit/php-file-iterator": "^2.0.2", "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0", + "phpunit/php-token-stream": "^3.0.1", "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^3.1 || ^4.0", + "sebastian/environment": "^4.1", "sebastian/version": "^2.0.1", "theseer/tokenizer": "^1.1" }, "require-dev": { - "phpunit/phpunit": "^7.0" + "phpunit/phpunit": "^8.0" }, "suggest": { - "ext-xdebug": "^2.6.0" + "ext-xdebug": "^2.6.1" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "6.1-dev" + "dev-master": "7.0-dev" } }, "autoload": { @@ -1698,7 +1698,7 @@ "testing", "xunit" ], - "time": "2018-10-31T16:06:48+00:00" + "time": "2019-02-26T07:38:26+00:00" }, { "name": "phpunit/php-file-iterator", @@ -1891,16 +1891,16 @@ }, { "name": "phpunit/phpunit", - "version": "7.5.9", + "version": "8.1.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "134669cf0eeac3f79bc7f0c793efbc158bffc160" + "reference": "2a676677982b484ee36b54961f570c02eabbe7e1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/134669cf0eeac3f79bc7f0c793efbc158bffc160", - "reference": "134669cf0eeac3f79bc7f0c793efbc158bffc160", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/2a676677982b484ee36b54961f570c02eabbe7e1", + "reference": "2a676677982b484ee36b54961f570c02eabbe7e1", "shasum": "" }, "require": { @@ -1910,27 +1910,25 @@ "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", + "ext-xmlwriter": "*", "myclabs/deep-copy": "^1.7", "phar-io/manifest": "^1.0.2", "phar-io/version": "^2.0", - "php": "^7.1", + "php": "^7.2", "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^6.0.7", + "phpunit/php-code-coverage": "^7.0", "phpunit/php-file-iterator": "^2.0.1", "phpunit/php-text-template": "^1.2.1", "phpunit/php-timer": "^2.1", "sebastian/comparator": "^3.0", "sebastian/diff": "^3.0", - "sebastian/environment": "^4.0", + "sebastian/environment": "^4.1", "sebastian/exporter": "^3.1", - "sebastian/global-state": "^2.0", + "sebastian/global-state": "^3.0", "sebastian/object-enumerator": "^3.0.3", "sebastian/resource-operations": "^2.0", "sebastian/version": "^2.0.1" }, - "conflict": { - "phpunit/phpunit-mock-objects": "*" - }, "require-dev": { "ext-pdo": "*" }, @@ -1945,7 +1943,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "7.5-dev" + "dev-master": "8.1-dev" } }, "autoload": { @@ -1971,7 +1969,7 @@ "testing", "xunit" ], - "time": "2019-04-19T15:50:46+00:00" + "time": "2019-04-19T15:52:00+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -2260,23 +2258,26 @@ }, { "name": "sebastian/global-state", - "version": "2.0.0", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4" + "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", - "reference": "e8ba02eed7bbbb9e59e43dedd3dddeff4a56b0c4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", + "reference": "edf8a461cf1d4005f19fb0b6b8b95a9f7fa0adc4", "shasum": "" }, "require": { - "php": "^7.0" + "php": "^7.2", + "sebastian/object-reflector": "^1.1.1", + "sebastian/recursion-context": "^3.0" }, "require-dev": { - "phpunit/phpunit": "^6.0" + "ext-dom": "*", + "phpunit/phpunit": "^8.0" }, "suggest": { "ext-uopz": "*" @@ -2284,7 +2285,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.0-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -2307,7 +2308,7 @@ "keywords": [ "global state" ], - "time": "2017-04-27T15:39:26+00:00" + "time": "2019-02-01T05:30:01+00:00" }, { "name": "sebastian/object-enumerator", diff --git a/tests/ZfcTwigTest/View/TwigRendererTest.php b/tests/ZfcTwigTest/View/TwigRendererTest.php index c22dffb..0f57038 100644 --- a/tests/ZfcTwigTest/View/TwigRendererTest.php +++ b/tests/ZfcTwigTest/View/TwigRendererTest.php @@ -15,7 +15,7 @@ class TwigRendererTest extends TestCase /** @var TwigRenderer */ protected $renderer; - public function setUp() + public function setUp(): void { parent::setUp(); @@ -43,7 +43,7 @@ public function testRenderWithNameAndValues() public function testRenderWithModelAndValues() { - /** @var \PHPUnit_Framework_MockObject_MockObject|ModelInterface $model */ + /** @var \PHPUnit\Framework\MockObject\MockObject|ModelInterface $model */ $model = $this->getMockBuilder(ModelInterface::class)->getMock(); $model->expects($this->exactly(1)) ->method('getTemplate') diff --git a/tests/ZfcTwigTest/View/TwigResolverTest.php b/tests/ZfcTwigTest/View/TwigResolverTest.php index 394459a..092580c 100644 --- a/tests/ZfcTwigTest/View/TwigResolverTest.php +++ b/tests/ZfcTwigTest/View/TwigResolverTest.php @@ -4,6 +4,7 @@ use PHPUnit\Framework\TestCase; use Twig\Environment; +use Twig\Error\LoaderError; use Twig\Loader; use Twig\TemplateWrapper; use ZfcTwig\View\TwigResolver; @@ -13,7 +14,7 @@ class TwigResolverTest extends TestCase /** @var TwigResolver */ protected $resolver; - protected function setUp() + protected function setUp(): void { parent::setUp(); @@ -28,12 +29,10 @@ public function testResolve() $this->assertInstanceOf(TemplateWrapper::class, $this->resolver->resolve('key1')); } - /** - * @expectedException \Twig\Error\LoaderError - * @expectedExceptionMessage Template "key2" is not defined. - */ public function testResolveError() { + $this->expectException(LoaderError::class); + $this->expectExceptionMessage('Template "key2" is not defined.'); $this->assertInstanceOf(TemplateWrapper::class, $this->resolver->resolve('key2')); } diff --git a/tests/ZfcTwigTest/View/TwigStrategyTest.php b/tests/ZfcTwigTest/View/TwigStrategyTest.php index 23767cc..bf367b3 100644 --- a/tests/ZfcTwigTest/View/TwigStrategyTest.php +++ b/tests/ZfcTwigTest/View/TwigStrategyTest.php @@ -19,7 +19,7 @@ class TwigStrategyTest extends TestCase /** @var TwigStrategy */ protected $strategy; - public function setUp() + public function setUp(): void { parent::setUp(); @@ -32,7 +32,7 @@ public function setUp() public function testSelectRendererWhenTemplateFound() { - /** @var \PHPUnit_Framework_MockObject_MockObject|ModelInterface $model */ + /** @var \PHPUnit\Framework\MockObject\MockObject|ModelInterface $model */ $model = $this->getMockBuilder(ModelInterface::class)->getMock(); $model->expects($this->at(0)) ->method('getTemplate') From 8a3685bc2e38e80578f45e0528328307c9771832 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Tue, 7 May 2019 22:28:52 +0200 Subject: [PATCH 04/11] FallbackFunction problem --- src/Twig/EnvironmentFactory.php | 11 ++++++++- src/Twig/FallbackFunction.php | 40 --------------------------------- 2 files changed, 10 insertions(+), 41 deletions(-) delete mode 100644 src/Twig/FallbackFunction.php diff --git a/src/Twig/EnvironmentFactory.php b/src/Twig/EnvironmentFactory.php index c0d925f..8e71c6b 100644 --- a/src/Twig/EnvironmentFactory.php +++ b/src/Twig/EnvironmentFactory.php @@ -5,6 +5,7 @@ use Interop\Container\ContainerInterface; use RuntimeException; use Twig\Environment; +use Twig\TwigFunction; use Zend\ServiceManager\Factory\FactoryInterface; use ZfcTwig\ModuleOptions; use function sprintf; @@ -40,7 +41,15 @@ public function __invoke(ContainerInterface $container, $requestedName, array $o $env->registerUndefinedFunctionCallback( function ($name) use ($helperPluginManager) { if ($helperPluginManager->has($name)) { - return new FallbackFunction($name); + return new TwigFunction( + $name, + sprintf( + '$this->env->getExtension("%s")->getRenderer()->plugin("%s")->__invoke', + Extension::class, + $name + ), + ['is_safe' => ['all']] + ); } return false; } diff --git a/src/Twig/FallbackFunction.php b/src/Twig/FallbackFunction.php deleted file mode 100644 index 46a6096..0000000 --- a/src/Twig/FallbackFunction.php +++ /dev/null @@ -1,40 +0,0 @@ -helper = $helper; - - parent::__construct($helper, $this->compile(), ['is_safe' => ['all']]); - } - - /** - * Compiles a function. - * - * @return string The PHP code for the function - */ - public function compile() - { - return sprintf( - '$this->env->getExtension("%s")->getRenderer()->plugin("%s")->__invoke', Extension::class, $this->helper - ); - } - -} From 19a6e624977dd28df672118fe7e700dc169e5f1c Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Tue, 7 May 2019 22:39:02 +0200 Subject: [PATCH 05/11] php-doc update --- src/Module.php | 5 ++- src/ModuleOptions.php | 66 +++++++++++++++++++-------------------- src/Twig/Extension.php | 4 +-- src/Twig/MapLoader.php | 10 +++--- src/Twig/StackLoader.php | 8 ++--- src/View/TwigRenderer.php | 34 ++++++++++---------- 6 files changed, 63 insertions(+), 64 deletions(-) diff --git a/src/Module.php b/src/Module.php index 1cbf213..09b5a21 100644 --- a/src/Module.php +++ b/src/Module.php @@ -17,9 +17,8 @@ class Module implements /** * @param EventInterface $e * @throws InvalidArgumentException - * @return array */ - public function onBootstrap(EventInterface $e) + public function onBootstrap(EventInterface $e): void { /** @var \Zend\Mvc\MvcEvent $e*/ $application = $e->getApplication(); @@ -51,7 +50,7 @@ public function onBootstrap(EventInterface $e) /** * @return array */ - public function getConfig() + public function getConfig(): array { return include __DIR__ . '/../config/module.config.php'; } diff --git a/src/ModuleOptions.php b/src/ModuleOptions.php index 34dfb8e..cd0f02d 100644 --- a/src/ModuleOptions.php +++ b/src/ModuleOptions.php @@ -9,12 +9,12 @@ class ModuleOptions extends AbstractOptions /** * @var string */ - protected $environmentLoader; + protected $environmentLoader = ''; /** * @var string */ - protected $environmentClass; + protected $environmentClass = ''; /** * @var array @@ -39,7 +39,7 @@ class ModuleOptions extends AbstractOptions /** * @var string */ - protected $suffix; + protected $suffix = ''; /** * @var bool @@ -58,9 +58,9 @@ class ModuleOptions extends AbstractOptions /** * @param boolean $disableZfmodel - * @return self + * @return $this */ - public function setDisableZfmodel($disableZfmodel) + public function setDisableZfmodel(bool $disableZfmodel): self { $this->disableZfmodel = $disableZfmodel; return $this; @@ -69,16 +69,16 @@ public function setDisableZfmodel($disableZfmodel) /** * @return boolean */ - public function getDisableZfmodel() + public function getDisableZfmodel(): bool { return $this->disableZfmodel; } /** * @param boolean $enableFallbackFunctions - * @return self + * @return $this */ - public function setEnableFallbackFunctions($enableFallbackFunctions) + public function setEnableFallbackFunctions(bool $enableFallbackFunctions): self { $this->enableFallbackFunctions = $enableFallbackFunctions; return $this; @@ -87,34 +87,34 @@ public function setEnableFallbackFunctions($enableFallbackFunctions) /** * @return boolean */ - public function getEnableFallbackFunctions() + public function getEnableFallbackFunctions(): bool { return $this->enableFallbackFunctions; } /** - * @param mixed $environmentLoader - * @return self + * @param string $environmentLoader + * @return $this */ - public function setEnvironmentLoader($environmentLoader) + public function setEnvironmentLoader(string $environmentLoader): self { $this->environmentLoader = $environmentLoader; return $this; } /** - * @return mixed + * @return string */ - public function getEnvironmentLoader() + public function getEnvironmentLoader(): string { return $this->environmentLoader; } /** * @param array $environmentOptions - * @return self + * @return $this */ - public function setEnvironmentOptions($environmentOptions) + public function setEnvironmentOptions(array $environmentOptions): self { $this->environmentOptions = $environmentOptions; return $this; @@ -123,16 +123,16 @@ public function setEnvironmentOptions($environmentOptions) /** * @return array */ - public function getEnvironmentOptions() + public function getEnvironmentOptions(): array { return $this->environmentOptions; } /** * @param array $extensions - * @return self + * @return $this */ - public function setExtensions($extensions) + public function setExtensions($extensions): self { $this->extensions = $extensions; return $this; @@ -141,16 +141,16 @@ public function setExtensions($extensions) /** * @return array */ - public function getExtensions() + public function getExtensions(): array { return $this->extensions; } /** * @param array $helperManager - * @return self + * @return $this */ - public function setHelperManager($helperManager) + public function setHelperManager($helperManager): self { $this->helperManager = $helperManager; return $this; @@ -159,16 +159,16 @@ public function setHelperManager($helperManager) /** * @return array */ - public function getHelperManager() + public function getHelperManager(): array { return $this->helperManager; } /** * @param array $loaderChain - * @return self + * @return $this */ - public function setLoaderChain($loaderChain) + public function setLoaderChain(array $loaderChain): self { $this->loaderChain = $loaderChain; return $this; @@ -177,16 +177,16 @@ public function setLoaderChain($loaderChain) /** * @return array */ - public function getLoaderChain() + public function getLoaderChain(): array { return $this->loaderChain; } /** * @param string $suffix - * @return self + * @return $this */ - public function setSuffix($suffix) + public function setSuffix(string $suffix): self { $this->suffix = $suffix; return $this; @@ -195,7 +195,7 @@ public function setSuffix($suffix) /** * @return string */ - public function getSuffix() + public function getSuffix(): string { return $this->suffix; } @@ -203,7 +203,7 @@ public function getSuffix() /** * @param string $environmentClass */ - public function setEnvironmentClass($environmentClass) + public function setEnvironmentClass(string $environmentClass) { $this->environmentClass = $environmentClass; } @@ -211,7 +211,7 @@ public function setEnvironmentClass($environmentClass) /** * @return string */ - public function getEnvironmentClass() + public function getEnvironmentClass(): string { return $this->environmentClass; } @@ -219,7 +219,7 @@ public function getEnvironmentClass() /** * @param array $globals */ - public function setGlobals($globals) + public function setGlobals(array $globals) { $this->globals = $globals; } @@ -227,7 +227,7 @@ public function setGlobals($globals) /** * @return array */ - public function getGlobals() + public function getGlobals(): array { return $this->globals; } diff --git a/src/Twig/Extension.php b/src/Twig/Extension.php index 6cad5d7..1768d6e 100644 --- a/src/Twig/Extension.php +++ b/src/Twig/Extension.php @@ -23,7 +23,7 @@ public function __construct(TwigRenderer $renderer) /** * @return TwigRenderer */ - public function getRenderer() + public function getRenderer(): TwigRenderer { return $this->renderer; } @@ -33,7 +33,7 @@ public function getRenderer() * * @return string The extension name */ - public function getName() + public function getName(): string { return __CLASS__; } diff --git a/src/Twig/MapLoader.php b/src/Twig/MapLoader.php index a20140a..0214218 100644 --- a/src/Twig/MapLoader.php +++ b/src/Twig/MapLoader.php @@ -27,7 +27,7 @@ class MapLoader implements Loader\LoaderInterface * @throws Error\LoaderError * @return MapLoader */ - public function add($name, $path) + public function add(string $name, string $path): MapLoader { if ($this->exists($name)) { throw new Error\LoaderError(sprintf( @@ -42,7 +42,7 @@ public function add($name, $path) /** * {@inheritDoc} */ - public function exists($name): bool + public function exists(string $name): bool { return array_key_exists($name, $this->map); } @@ -50,7 +50,7 @@ public function exists($name): bool /** * {@inheritDoc} */ - public function getSourceContext($name): Source + public function getSourceContext(string $name): Source { if (!$this->exists($name)) { throw new Error\LoaderError(sprintf( @@ -70,7 +70,7 @@ public function getSourceContext($name): Source /** * {@inheritDoc} */ - public function getCacheKey($name): string + public function getCacheKey(string $name): string { return $name; } @@ -78,7 +78,7 @@ public function getCacheKey($name): string /** * {@inheritDoc} */ - public function isFresh($name, $time): bool + public function isFresh(string $name, int $time): bool { return filemtime($this->map[$name]) <= $time; } diff --git a/src/Twig/StackLoader.php b/src/Twig/StackLoader.php index 20e8698..0c3734a 100644 --- a/src/Twig/StackLoader.php +++ b/src/Twig/StackLoader.php @@ -38,7 +38,7 @@ class StackLoader extends Loader\FilesystemLoader * * @return StackLoader */ - public function setDefaultSuffix($defaultSuffix) + public function setDefaultSuffix(string $defaultSuffix) { $this->defaultSuffix = (string)$defaultSuffix; $this->defaultSuffix = ltrim($this->defaultSuffix, '.'); @@ -51,7 +51,7 @@ public function setDefaultSuffix($defaultSuffix) * * @return string */ - public function getDefaultSuffix() + public function getDefaultSuffix(): string { return $this->defaultSuffix; } @@ -60,7 +60,7 @@ public function getDefaultSuffix() * {@inheritDoc} * @throws Error\LoaderError */ - protected function findTemplate($name, $throw = true): string + protected function findTemplate(string $name, bool $throw = true): string { $name = (string)$name; @@ -141,7 +141,7 @@ protected function findTemplate($name, $throw = true): string * @param string $name * @throws Error\LoaderError */ - private function validateName($name) + private function validateName(string $name): void { if (false !== strpos($name, "\0")) { throw new Error\LoaderError('A template name cannot contain NUL bytes.'); diff --git a/src/View/TwigRenderer.php b/src/View/TwigRenderer.php index 5d65d24..ca0ff43 100644 --- a/src/View/TwigRenderer.php +++ b/src/View/TwigRenderer.php @@ -88,7 +88,7 @@ public function __construct( * @param array $argv * @return mixed */ - public function __call($method, $argv) + public function __call(string $method, array $argv) { if (!isset($this->__pluginCache[$method])) { $this->__pluginCache[$method] = $this->plugin($method); @@ -101,9 +101,9 @@ public function __call($method, $argv) /** * @param boolean $canRenderTrees - * @return TwigRenderer + * @return $this */ - public function setCanRenderTrees($canRenderTrees) + public function setCanRenderTrees(bool $canRenderTrees): self { $this->canRenderTrees = $canRenderTrees; return $this; @@ -112,7 +112,7 @@ public function setCanRenderTrees($canRenderTrees) /** * @return boolean */ - public function canRenderTrees() + public function canRenderTrees(): bool { return $this->canRenderTrees; } @@ -124,7 +124,7 @@ public function canRenderTrees() * @param null|array $options Options to pass to plugin constructor (if not already instantiated) * @return \Zend\View\Helper\AbstractHelper */ - public function plugin($name, array $options = null) + public function plugin(string $name, array $options = null) { $helper = $this->getHelperPluginManager() ->setRenderer($this); @@ -143,7 +143,7 @@ public function plugin($name, array $options = null) * @return bool * @see \ZfcTwig\Twig\Environment::canLoadTemplate() */ - public function canRender($name) + public function canRender(string $name): bool { return $this->loader->exists($name); } @@ -157,7 +157,7 @@ public function canRender($name) * * @return Environment */ - public function getEngine() + public function getEngine(): Environment { return $this->environment; } @@ -166,9 +166,9 @@ public function getEngine() * Set the resolver used to map a template name to a resource the renderer may consume. * * @param ResolverInterface $resolver - * @return TwigRenderer + * @return $this */ - public function setResolver(ResolverInterface $resolver) + public function setResolver(ResolverInterface $resolver): self { $this->resolver = $resolver; return $this; @@ -176,9 +176,9 @@ public function setResolver(ResolverInterface $resolver) /** * @param HelperPluginManager $helperPluginManager - * @return TwigRenderer + * @return $this */ - public function setHelperPluginManager(HelperPluginManager $helperPluginManager) + public function setHelperPluginManager(HelperPluginManager $helperPluginManager): self { $helperPluginManager->setRenderer($this); $this->helperPluginManager = $helperPluginManager; @@ -186,9 +186,9 @@ public function setHelperPluginManager(HelperPluginManager $helperPluginManager) } /** - * @return \Zend\View\HelperPluginManager + * @return HelperPluginManager */ - public function getHelperPluginManager() + public function getHelperPluginManager(): HelperPluginManager { return $this->helperPluginManager; } @@ -196,16 +196,16 @@ public function getHelperPluginManager() /** * @return HelperPluginManager */ - public function getZendHelperPluginManager() + public function getZendHelperPluginManager(): HelperPluginManager { return $this->zendHelperPluginManager; } /** * @param HelperPluginManager $zendHelperPluginManager - * @return self + * @return $this */ - public function setZendHelperPluginManager($zendHelperPluginManager) + public function setZendHelperPluginManager(HelperPluginManager $zendHelperPluginManager): self { $this->zendHelperPluginManager = $zendHelperPluginManager; return $this; @@ -219,7 +219,7 @@ public function setZendHelperPluginManager($zendHelperPluginManager) * @return string|null The script output. * @throws \Zend\View\Exception\DomainException */ - public function render($nameOrModel, $values = null) + public function render($nameOrModel, $values = null): ?string { $model = null; From 6d99bd878b4514f995b41ed76a959a9e82a498a6 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Thu, 3 Oct 2019 10:18:56 +0200 Subject: [PATCH 06/11] merge --- composer.lock | 396 ++++++++++++++++++++++++++++---------------------- 1 file changed, 220 insertions(+), 176 deletions(-) diff --git a/composer.lock b/composer.lock index 153d7ef..e6960d0 100644 --- a/composer.lock +++ b/composer.lock @@ -88,16 +88,16 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.11.0", + "version": "v1.12.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "82ebae02209c21113908c229e9883c419720738a" + "reference": "550ebaac289296ce228a706d0867afc34687e3f4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/82ebae02209c21113908c229e9883c419720738a", - "reference": "82ebae02209c21113908c229e9883c419720738a", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/550ebaac289296ce228a706d0867afc34687e3f4", + "reference": "550ebaac289296ce228a706d0867afc34687e3f4", "shasum": "" }, "require": { @@ -109,7 +109,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.11-dev" + "dev-master": "1.12-dev" } }, "autoload": { @@ -126,12 +126,12 @@ ], "authors": [ { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" + "name": "Gert de Pagter", + "email": "BackEndTea@gmail.com" }, { - "name": "Gert de Pagter", - "email": "backendtea@gmail.com" + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" } ], "description": "Symfony polyfill for ctype functions", @@ -142,20 +142,20 @@ "polyfill", "portable" ], - "time": "2019-02-06T07:57:58+00:00" + "time": "2019-08-06T08:03:45+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.11.0", + "version": "v1.12.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "fe5e94c604826c35a32fa832f35bd036b6799609" + "reference": "b42a2f66e8f1b15ccf25652c3424265923eb4f17" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/fe5e94c604826c35a32fa832f35bd036b6799609", - "reference": "fe5e94c604826c35a32fa832f35bd036b6799609", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/b42a2f66e8f1b15ccf25652c3424265923eb4f17", + "reference": "b42a2f66e8f1b15ccf25652c3424265923eb4f17", "shasum": "" }, "require": { @@ -167,7 +167,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.11-dev" + "dev-master": "1.12-dev" } }, "autoload": { @@ -201,7 +201,7 @@ "portable", "shim" ], - "time": "2019-02-06T07:57:58+00:00" + "time": "2019-08-06T08:03:45+00:00" }, { "name": "twig/twig", @@ -209,23 +209,23 @@ "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "8d82f62418876c187499beb74d816c00a4be33f7" + "reference": "6a50ca063904a8bf657e95cd0cfa89db138dc7ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/8d82f62418876c187499beb74d816c00a4be33f7", - "reference": "8d82f62418876c187499beb74d816c00a4be33f7", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/6a50ca063904a8bf657e95cd0cfa89db138dc7ac", + "reference": "6a50ca063904a8bf657e95cd0cfa89db138dc7ac", "shasum": "" }, "require": { - "php": "^7.2", + "php": "^7.2.9", "symfony/polyfill-ctype": "^1.8", "symfony/polyfill-mbstring": "^1.3" }, "require-dev": { "psr/container": "^1.0", - "symfony/debug": "^2.7", - "symfony/phpunit-bridge": "^3.4.19|^4.1.8" + "symfony/debug": "^3.4|^4.2|^5.0", + "symfony/phpunit-bridge": "^4.4@dev|^5.0" }, "type": "library", "extra": { @@ -249,15 +249,15 @@ "homepage": "http://fabien.potencier.org", "role": "Lead Developer" }, - { - "name": "Armin Ronacher", - "email": "armin.ronacher@active-4.com", - "role": "Project Founder" - }, { "name": "Twig Team", "homepage": "https://twig.symfony.com/contributors", "role": "Contributors" + }, + { + "name": "Armin Ronacher", + "email": "armin.ronacher@active-4.com", + "role": "Project Founder" } ], "description": "Twig, the flexible, fast, and secure template language for PHP", @@ -265,20 +265,20 @@ "keywords": [ "templating" ], - "time": "2019-05-01T14:00:56+00:00" + "time": "2019-10-01T10:35:06+00:00" }, { "name": "zendframework/zend-config", - "version": "3.2.0", + "version": "3.3.0", "source": { "type": "git", "url": "https://github.com/zendframework/zend-config.git", - "reference": "6796f5dcba52c84ef2501d7313618989b5ef3023" + "reference": "012341361ae3cc97a99959e7cb7c9ebd04d49572" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-config/zipball/6796f5dcba52c84ef2501d7313618989b5ef3023", - "reference": "6796f5dcba52c84ef2501d7313618989b5ef3023", + "url": "https://api.github.com/repos/zendframework/zend-config/zipball/012341361ae3cc97a99959e7cb7c9ebd04d49572", + "reference": "012341361ae3cc97a99959e7cb7c9ebd04d49572", "shasum": "" }, "require": { @@ -306,8 +306,8 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.2.x-dev", - "dev-develop": "3.3.x-dev" + "dev-master": "3.3.x-dev", + "dev-develop": "3.4.x-dev" } }, "autoload": { @@ -325,20 +325,20 @@ "config", "zf" ], - "time": "2018-04-24T19:26:44+00:00" + "time": "2019-06-08T18:58:54+00:00" }, { "name": "zendframework/zend-escaper", - "version": "2.6.0", + "version": "2.6.1", "source": { "type": "git", "url": "https://github.com/zendframework/zend-escaper.git", - "reference": "31d8aafae982f9568287cb4dce987e6aff8fd074" + "reference": "3801caa21b0ca6aca57fa1c42b08d35c395ebd5f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-escaper/zipball/31d8aafae982f9568287cb4dce987e6aff8fd074", - "reference": "31d8aafae982f9568287cb4dce987e6aff8fd074", + "url": "https://api.github.com/repos/zendframework/zend-escaper/zipball/3801caa21b0ca6aca57fa1c42b08d35c395ebd5f", + "reference": "3801caa21b0ca6aca57fa1c42b08d35c395ebd5f", "shasum": "" }, "require": { @@ -370,7 +370,7 @@ "escaper", "zf" ], - "time": "2018-04-25T15:48:53+00:00" + "time": "2019-09-05T20:03:20+00:00" }, { "name": "zendframework/zend-eventmanager", @@ -483,16 +483,16 @@ }, { "name": "zendframework/zend-json", - "version": "3.1.0", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/zendframework/zend-json.git", - "reference": "4dd940e8e6f32f1d36ea6b0677ea57c540c7c19c" + "reference": "21c6027f3c4a5177cbef8ed08d1037b17188a0d8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-json/zipball/4dd940e8e6f32f1d36ea6b0677ea57c540c7c19c", - "reference": "4dd940e8e6f32f1d36ea6b0677ea57c540c7c19c", + "url": "https://api.github.com/repos/zendframework/zend-json/zipball/21c6027f3c4a5177cbef8ed08d1037b17188a0d8", + "reference": "21c6027f3c4a5177cbef8ed08d1037b17188a0d8", "shasum": "" }, "require": { @@ -529,20 +529,20 @@ "json", "zf" ], - "time": "2018-01-04T17:51:34+00:00" + "time": "2019-06-18T10:54:52+00:00" }, { "name": "zendframework/zend-loader", - "version": "2.6.0", + "version": "2.6.1", "source": { "type": "git", "url": "https://github.com/zendframework/zend-loader.git", - "reference": "78f11749ea340f6ca316bca5958eef80b38f9b6c" + "reference": "91da574d29b58547385b2298c020b257310898c6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-loader/zipball/78f11749ea340f6ca316bca5958eef80b38f9b6c", - "reference": "78f11749ea340f6ca316bca5958eef80b38f9b6c", + "url": "https://api.github.com/repos/zendframework/zend-loader/zipball/91da574d29b58547385b2298c020b257310898c6", + "reference": "91da574d29b58547385b2298c020b257310898c6", "shasum": "" }, "require": { @@ -574,7 +574,7 @@ "loader", "zf" ], - "time": "2018-04-30T15:20:54+00:00" + "time": "2019-09-04T19:38:14+00:00" }, { "name": "zendframework/zend-modulemanager", @@ -896,28 +896,28 @@ }, { "name": "zendframework/zend-session", - "version": "2.8.5", + "version": "2.9.0", "source": { "type": "git", "url": "https://github.com/zendframework/zend-session.git", - "reference": "2cfd90e1a2f6b066b9f908599251d8f64f07021b" + "reference": "0a0c7ae4d8be608e30ecff714c86164ccca19ca3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-session/zipball/2cfd90e1a2f6b066b9f908599251d8f64f07021b", - "reference": "2cfd90e1a2f6b066b9f908599251d8f64f07021b", + "url": "https://api.github.com/repos/zendframework/zend-session/zipball/0a0c7ae4d8be608e30ecff714c86164ccca19ca3", + "reference": "0a0c7ae4d8be608e30ecff714c86164ccca19ca3", "shasum": "" }, "require": { "php": "^5.6 || ^7.0", "zendframework/zend-eventmanager": "^2.6.2 || ^3.0", - "zendframework/zend-stdlib": "^2.7 || ^3.0" + "zendframework/zend-stdlib": "^3.2.1" }, "require-dev": { "container-interop/container-interop": "^1.1", "mongodb/mongodb": "^1.0.1", "php-mock/php-mock-phpunit": "^1.1.2 || ^2.0", - "phpunit/phpunit": "^5.7.5 || >=6.0.13 <6.5.0", + "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.16", "zendframework/zend-cache": "^2.6.1", "zendframework/zend-coding-standard": "~1.0.0", "zendframework/zend-db": "^2.7", @@ -936,8 +936,8 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.8-dev", - "dev-develop": "2.9-dev" + "dev-master": "2.9.x-dev", + "dev-develop": "2.10.x-dev" }, "zf": { "component": "Zend\\Session", @@ -953,13 +953,13 @@ "license": [ "BSD-3-Clause" ], - "description": "manage and preserve session data, a logical complement of cookie data, across multiple page requests by the same client", + "description": "Object-oriented interface to PHP sessions and storage", "keywords": [ "ZendFramework", "session", "zf" ], - "time": "2018-02-22T16:33:54+00:00" + "time": "2019-09-20T12:50:51+00:00" }, { "name": "zendframework/zend-stdlib", @@ -1274,16 +1274,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.9.1", + "version": "1.9.3", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "e6828efaba2c9b79f4499dae1d66ef8bfa7b2b72" + "reference": "007c053ae6f31bba39dfa19a7726f56e9763bbea" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/e6828efaba2c9b79f4499dae1d66ef8bfa7b2b72", - "reference": "e6828efaba2c9b79f4499dae1d66ef8bfa7b2b72", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/007c053ae6f31bba39dfa19a7726f56e9763bbea", + "reference": "007c053ae6f31bba39dfa19a7726f56e9763bbea", "shasum": "" }, "require": { @@ -1318,7 +1318,7 @@ "object", "object graph" ], - "time": "2019-04-07T13:18:21+00:00" + "time": "2019-08-09T12:45:53+00:00" }, { "name": "phar-io/manifest", @@ -1424,35 +1424,33 @@ }, { "name": "phpdocumentor/reflection-common", - "version": "1.0.1", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionCommon.git", - "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6" + "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", - "reference": "21bdeb5f65d7ebf9f43b1b25d404f87deab5bfb6", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionCommon/zipball/63a995caa1ca9e5590304cd845c15ad6d482a62a", + "reference": "63a995caa1ca9e5590304cd845c15ad6d482a62a", "shasum": "" }, "require": { - "php": ">=5.5" + "php": ">=7.1" }, "require-dev": { - "phpunit/phpunit": "^4.6" + "phpunit/phpunit": "~6" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "2.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src" - ] + "phpDocumentor\\Reflection\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -1474,30 +1472,30 @@ "reflection", "static analysis" ], - "time": "2017-09-11T18:02:19+00:00" + "time": "2018-08-07T13:53:10+00:00" }, { "name": "phpdocumentor/reflection-docblock", - "version": "4.3.1", + "version": "4.3.2", "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "bdd9f737ebc2a01c06ea7ff4308ec6697db9b53c" + "reference": "b83ff7cfcfee7827e1e78b637a5904fe6a96698e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/bdd9f737ebc2a01c06ea7ff4308ec6697db9b53c", - "reference": "bdd9f737ebc2a01c06ea7ff4308ec6697db9b53c", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/b83ff7cfcfee7827e1e78b637a5904fe6a96698e", + "reference": "b83ff7cfcfee7827e1e78b637a5904fe6a96698e", "shasum": "" }, "require": { "php": "^7.0", - "phpdocumentor/reflection-common": "^1.0.0", - "phpdocumentor/type-resolver": "^0.4.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", + "doctrine/instantiator": "^1.0.5", "mockery/mockery": "^1.0", "phpunit/phpunit": "^6.4" }, @@ -1525,41 +1523,40 @@ } ], "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-04-30T17:48:53+00:00" + "time": "2019-09-12T14:27:41+00:00" }, { "name": "phpdocumentor/type-resolver", - "version": "0.4.0", + "version": "1.0.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7" + "reference": "2e32a6d48972b2c1976ed5d8967145b6cec4a4a9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/9c977708995954784726e25d0cd1dddf4e65b0f7", - "reference": "9c977708995954784726e25d0cd1dddf4e65b0f7", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/2e32a6d48972b2c1976ed5d8967145b6cec4a4a9", + "reference": "2e32a6d48972b2c1976ed5d8967145b6cec4a4a9", "shasum": "" }, "require": { - "php": "^5.5 || ^7.0", - "phpdocumentor/reflection-common": "^1.0" + "php": "^7.1", + "phpdocumentor/reflection-common": "^2.0" }, "require-dev": { - "mockery/mockery": "^0.9.4", - "phpunit/phpunit": "^5.2||^4.8.24" + "ext-tokenizer": "^7.1", + "mockery/mockery": "~1", + "phpunit/phpunit": "^7.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.x-dev" } }, "autoload": { "psr-4": { - "phpDocumentor\\Reflection\\": [ - "src/" - ] + "phpDocumentor\\Reflection\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -1572,20 +1569,21 @@ "email": "me@mikevanriel.com" } ], - "time": "2017-07-14T14:27:02+00:00" + "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.8.0", + "version": "1.8.1", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "4ba436b55987b4bf311cb7c6ba82aa528aac0a06" + "reference": "1927e75f4ed19131ec9bcc3b002e07fb1173ee76" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/4ba436b55987b4bf311cb7c6ba82aa528aac0a06", - "reference": "4ba436b55987b4bf311cb7c6ba82aa528aac0a06", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/1927e75f4ed19131ec9bcc3b002e07fb1173ee76", + "reference": "1927e75f4ed19131ec9bcc3b002e07fb1173ee76", "shasum": "" }, "require": { @@ -1606,8 +1604,8 @@ } }, "autoload": { - "psr-0": { - "Prophecy\\": "src/" + "psr-4": { + "Prophecy\\": "src/Prophecy" } }, "notification-url": "https://packagist.org/downloads/", @@ -1635,20 +1633,20 @@ "spy", "stub" ], - "time": "2018-08-05T17:53:17+00:00" + "time": "2019-06-13T12:50:23+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "7.0.3", + "version": "7.0.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "0317a769a81845c390e19684d9ba25d7f6aa4707" + "reference": "aa0d179a13284c7420fc281fc32750e6cc7c9e2f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/0317a769a81845c390e19684d9ba25d7f6aa4707", - "reference": "0317a769a81845c390e19684d9ba25d7f6aa4707", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/aa0d179a13284c7420fc281fc32750e6cc7c9e2f", + "reference": "aa0d179a13284c7420fc281fc32750e6cc7c9e2f", "shasum": "" }, "require": { @@ -1657,17 +1655,17 @@ "php": "^7.2", "phpunit/php-file-iterator": "^2.0.2", "phpunit/php-text-template": "^1.2.1", - "phpunit/php-token-stream": "^3.0.1", + "phpunit/php-token-stream": "^3.1.1", "sebastian/code-unit-reverse-lookup": "^1.0.1", - "sebastian/environment": "^4.1", + "sebastian/environment": "^4.2.2", "sebastian/version": "^2.0.1", - "theseer/tokenizer": "^1.1" + "theseer/tokenizer": "^1.1.3" }, "require-dev": { - "phpunit/phpunit": "^8.0" + "phpunit/phpunit": "^8.2.2" }, "suggest": { - "ext-xdebug": "^2.6.1" + "ext-xdebug": "^2.7.2" }, "type": "library", "extra": { @@ -1698,7 +1696,7 @@ "testing", "xunit" ], - "time": "2019-02-26T07:38:26+00:00" + "time": "2019-09-17T06:24:36+00:00" }, { "name": "phpunit/php-file-iterator", @@ -1793,16 +1791,16 @@ }, { "name": "phpunit/php-timer", - "version": "2.1.1", + "version": "2.1.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-timer.git", - "reference": "8b389aebe1b8b0578430bda0c7c95a829608e059" + "reference": "1038454804406b0b5f5f520358e78c1c2f71501e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/8b389aebe1b8b0578430bda0c7c95a829608e059", - "reference": "8b389aebe1b8b0578430bda0c7c95a829608e059", + "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/1038454804406b0b5f5f520358e78c1c2f71501e", + "reference": "1038454804406b0b5f5f520358e78c1c2f71501e", "shasum": "" }, "require": { @@ -1838,20 +1836,20 @@ "keywords": [ "timer" ], - "time": "2019-02-20T10:12:59+00:00" + "time": "2019-06-07T04:22:29+00:00" }, { "name": "phpunit/php-token-stream", - "version": "3.0.1", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "c99e3be9d3e85f60646f152f9002d46ed7770d18" + "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/c99e3be9d3e85f60646f152f9002d46ed7770d18", - "reference": "c99e3be9d3e85f60646f152f9002d46ed7770d18", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/995192df77f63a59e47f025390d2d1fdf8f425ff", + "reference": "995192df77f63a59e47f025390d2d1fdf8f425ff", "shasum": "" }, "require": { @@ -1864,7 +1862,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.1-dev" } }, "autoload": { @@ -1887,46 +1885,47 @@ "keywords": [ "tokenizer" ], - "time": "2018-10-30T05:52:18+00:00" + "time": "2019-09-17T06:23:10+00:00" }, { "name": "phpunit/phpunit", - "version": "8.1.3", + "version": "8.3.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "2a676677982b484ee36b54961f570c02eabbe7e1" + "reference": "302faed7059fde575cf3403a78c730c5e3a62750" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/2a676677982b484ee36b54961f570c02eabbe7e1", - "reference": "2a676677982b484ee36b54961f570c02eabbe7e1", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/302faed7059fde575cf3403a78c730c5e3a62750", + "reference": "302faed7059fde575cf3403a78c730c5e3a62750", "shasum": "" }, "require": { - "doctrine/instantiator": "^1.1", + "doctrine/instantiator": "^1.2.0", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.7", - "phar-io/manifest": "^1.0.2", - "phar-io/version": "^2.0", + "myclabs/deep-copy": "^1.9.1", + "phar-io/manifest": "^1.0.3", + "phar-io/version": "^2.0.1", "php": "^7.2", - "phpspec/prophecy": "^1.7", - "phpunit/php-code-coverage": "^7.0", - "phpunit/php-file-iterator": "^2.0.1", + "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", - "sebastian/comparator": "^3.0", - "sebastian/diff": "^3.0", - "sebastian/environment": "^4.1", - "sebastian/exporter": "^3.1", - "sebastian/global-state": "^3.0", + "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", + "sebastian/resource-operations": "^2.0.1", + "sebastian/type": "^1.1.3", "sebastian/version": "^2.0.1" }, "require-dev": { @@ -1935,7 +1934,7 @@ "suggest": { "ext-soap": "*", "ext-xdebug": "*", - "phpunit/php-invoker": "^2.0" + "phpunit/php-invoker": "^2.0.0" }, "bin": [ "phpunit" @@ -1943,7 +1942,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "8.1-dev" + "dev-master": "8.3-dev" } }, "autoload": { @@ -1969,7 +1968,7 @@ "testing", "xunit" ], - "time": "2019-04-19T15:52:00+00:00" + "time": "2019-09-14T09:12:03+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -2191,16 +2190,16 @@ }, { "name": "sebastian/exporter", - "version": "3.1.0", + "version": "3.1.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "234199f4528de6d12aaa58b612e98f7d36adb937" + "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/234199f4528de6d12aaa58b612e98f7d36adb937", - "reference": "234199f4528de6d12aaa58b612e98f7d36adb937", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/68609e1261d215ea5b21b7987539cbfbe156ec3e", + "reference": "68609e1261d215ea5b21b7987539cbfbe156ec3e", "shasum": "" }, "require": { @@ -2227,6 +2226,10 @@ "BSD-3-Clause" ], "authors": [ + { + "name": "Sebastian Bergmann", + "email": "sebastian@phpunit.de" + }, { "name": "Jeff Welch", "email": "whatthejeff@gmail.com" @@ -2235,17 +2238,13 @@ "name": "Volker Dusch", "email": "github@wallbash.com" }, - { - "name": "Bernhard Schussek", - "email": "bschussek@2bepublished.at" - }, - { - "name": "Sebastian Bergmann", - "email": "sebastian@phpunit.de" - }, { "name": "Adam Harvey", "email": "aharvey@php.net" + }, + { + "name": "Bernhard Schussek", + "email": "bschussek@gmail.com" } ], "description": "Provides the functionality to export PHP variables for visualization", @@ -2254,7 +2253,7 @@ "export", "exporter" ], - "time": "2017-04-03T13:19:02+00:00" + "time": "2019-09-14T09:02:43+00:00" }, { "name": "sebastian/global-state", @@ -2497,6 +2496,52 @@ "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", @@ -2542,16 +2587,16 @@ }, { "name": "theseer/tokenizer", - "version": "1.1.2", + "version": "1.1.3", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "1c42705be2b6c1de5904f8afacef5895cab44bf8" + "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/1c42705be2b6c1de5904f8afacef5895cab44bf8", - "reference": "1c42705be2b6c1de5904f8afacef5895cab44bf8", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/11336f6f84e16a720dae9d8e6ed5019efa85a0f9", + "reference": "11336f6f84e16a720dae9d8e6ed5019efa85a0f9", "shasum": "" }, "require": { @@ -2578,20 +2623,20 @@ } ], "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", - "time": "2019-04-04T09:56:43+00:00" + "time": "2019-06-13T22:48:21+00:00" }, { "name": "webmozart/assert", - "version": "1.4.0", + "version": "1.5.0", "source": { "type": "git", "url": "https://github.com/webmozart/assert.git", - "reference": "83e253c8e0be5b0257b881e1827274667c5c17a9" + "reference": "88e6d84706d09a236046d686bbea96f07b3a34f4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/83e253c8e0be5b0257b881e1827274667c5c17a9", - "reference": "83e253c8e0be5b0257b881e1827274667c5c17a9", + "url": "https://api.github.com/repos/webmozart/assert/zipball/88e6d84706d09a236046d686bbea96f07b3a34f4", + "reference": "88e6d84706d09a236046d686bbea96f07b3a34f4", "shasum": "" }, "require": { @@ -2599,8 +2644,7 @@ "symfony/polyfill-ctype": "^1.8" }, "require-dev": { - "phpunit/phpunit": "^4.6", - "sebastian/version": "^1.0.1" + "phpunit/phpunit": "^4.8.36 || ^7.5.13" }, "type": "library", "extra": { @@ -2629,20 +2673,20 @@ "check", "validate" ], - "time": "2018-12-25T11:19:39+00:00" + "time": "2019-08-24T08:43:50+00:00" }, { "name": "zendframework/zend-navigation", - "version": "2.9.0", + "version": "2.9.1", "source": { "type": "git", "url": "https://github.com/zendframework/zend-navigation.git", - "reference": "a8b088f64929e172617e02d2089cc00573a61210" + "reference": "fd3c60b83e816cfb67b53c2193372ac19469a609" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-navigation/zipball/a8b088f64929e172617e02d2089cc00573a61210", - "reference": "a8b088f64929e172617e02d2089cc00573a61210", + "url": "https://api.github.com/repos/zendframework/zend-navigation/zipball/fd3c60b83e816cfb67b53c2193372ac19469a609", + "reference": "fd3c60b83e816cfb67b53c2193372ac19469a609", "shasum": "" }, "require": { @@ -2697,7 +2741,7 @@ "navigation", "zf" ], - "time": "2018-04-25T20:19:50+00:00" + "time": "2019-08-21T08:28:20+00:00" } ], "aliases": [], From bb09fa60197b57f038208c0210ddb5b5ab718eb1 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Mon, 11 Nov 2019 22:41:28 +0100 Subject: [PATCH 07/11] composer update --- composer.json | 2 +- composer.lock | 141 +++++++++++++++++++++++++------------------------- 2 files changed, 71 insertions(+), 72 deletions(-) diff --git a/composer.json b/composer.json index d37df45..c611c92 100644 --- a/composer.json +++ b/composer.json @@ -23,7 +23,7 @@ } ], "require": { - "php": "^7.2", + "php": "^7.2.9", "twig/twig": "3.x-dev", "zendframework/zend-mvc": "^3.0", "zendframework/zend-view": "^2.7", diff --git a/composer.lock b/composer.lock index e6960d0..cbe602a 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "2e3860b594362f9e15f566693e9d211a", + "content-hash": "45829e7ec4ed2494a7a41613defeee74", "packages": [ { "name": "container-interop/container-interop", @@ -209,12 +209,12 @@ "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "6a50ca063904a8bf657e95cd0cfa89db138dc7ac" + "reference": "d28774240a63d5db36dd47f21e4365ac57e18d77" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/6a50ca063904a8bf657e95cd0cfa89db138dc7ac", - "reference": "6a50ca063904a8bf657e95cd0cfa89db138dc7ac", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/d28774240a63d5db36dd47f21e4365ac57e18d77", + "reference": "d28774240a63d5db36dd47f21e4365ac57e18d77", "shasum": "" }, "require": { @@ -265,7 +265,7 @@ "keywords": [ "templating" ], - "time": "2019-10-01T10:35:06+00:00" + "time": "2019-11-11T16:57:14+00:00" }, { "name": "zendframework/zend-config", @@ -483,16 +483,16 @@ }, { "name": "zendframework/zend-json", - "version": "3.1.1", + "version": "3.1.2", "source": { "type": "git", "url": "https://github.com/zendframework/zend-json.git", - "reference": "21c6027f3c4a5177cbef8ed08d1037b17188a0d8" + "reference": "e9ddb1192d93fe7fff846ac895249c39db75132b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-json/zipball/21c6027f3c4a5177cbef8ed08d1037b17188a0d8", - "reference": "21c6027f3c4a5177cbef8ed08d1037b17188a0d8", + "url": "https://api.github.com/repos/zendframework/zend-json/zipball/e9ddb1192d93fe7fff846ac895249c39db75132b", + "reference": "e9ddb1192d93fe7fff846ac895249c39db75132b", "shasum": "" }, "require": { @@ -529,7 +529,7 @@ "json", "zf" ], - "time": "2019-06-18T10:54:52+00:00" + "time": "2019-10-09T13:56:13+00:00" }, { "name": "zendframework/zend-loader", @@ -578,16 +578,16 @@ }, { "name": "zendframework/zend-modulemanager", - "version": "2.8.2", + "version": "2.8.4", "source": { "type": "git", "url": "https://github.com/zendframework/zend-modulemanager.git", - "reference": "394df6e12248ac430a312d4693f793ee7120baa6" + "reference": "b2596d24b9a4e36a3cd114d35d3ad0918db9a243" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-modulemanager/zipball/394df6e12248ac430a312d4693f793ee7120baa6", - "reference": "394df6e12248ac430a312d4693f793ee7120baa6", + "url": "https://api.github.com/repos/zendframework/zend-modulemanager/zipball/b2596d24b9a4e36a3cd114d35d3ad0918db9a243", + "reference": "b2596d24b9a4e36a3cd114d35d3ad0918db9a243", "shasum": "" }, "require": { @@ -597,7 +597,7 @@ "zendframework/zend-stdlib": "^3.1 || ^2.7" }, "require-dev": { - "phpunit/phpunit": "^6.0.8 || ^5.7.15", + "phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.16", "zendframework/zend-coding-standard": "~1.0.0", "zendframework/zend-console": "^2.6", "zendframework/zend-di": "^2.6", @@ -614,8 +614,8 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "2.7-dev", - "dev-develop": "2.8-dev" + "dev-master": "2.8.x-dev", + "dev-develop": "2.9.x-dev" } }, "autoload": { @@ -628,13 +628,12 @@ "BSD-3-Clause" ], "description": "Modular application system for zend-mvc applications", - "homepage": "https://github.com/zendframework/zend-modulemanager", "keywords": [ "ZendFramework", "modulemanager", "zf" ], - "time": "2017-12-02T06:11:18+00:00" + "time": "2019-10-28T13:29:38+00:00" }, { "name": "zendframework/zend-mvc", @@ -710,23 +709,23 @@ }, { "name": "zendframework/zend-mvc-plugin-flashmessenger", - "version": "1.1.0", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/zendframework/zend-mvc-plugin-flashmessenger.git", - "reference": "1af2e2d69500da5ca31868c4817b6b7eb7e1cf47" + "reference": "b66064eb59d3b124a133d259aac3d9dd7cb81706" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-mvc-plugin-flashmessenger/zipball/1af2e2d69500da5ca31868c4817b6b7eb7e1cf47", - "reference": "1af2e2d69500da5ca31868c4817b6b7eb7e1cf47", + "url": "https://api.github.com/repos/zendframework/zend-mvc-plugin-flashmessenger/zipball/b66064eb59d3b124a133d259aac3d9dd7cb81706", + "reference": "b66064eb59d3b124a133d259aac3d9dd7cb81706", "shasum": "" }, "require": { "php": "^5.6 || ^7.0", "zendframework/zend-mvc": "^3.0", "zendframework/zend-session": "^2.8.5", - "zendframework/zend-stdlib": "^2.7 || ^3.0", + "zendframework/zend-stdlib": "^3.2.1", "zendframework/zend-view": "^2.10" }, "conflict": { @@ -740,8 +739,8 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1.x-dev", - "dev-develop": "1.2.x-dev" + "dev-master": "1.2.x-dev", + "dev-develop": "1.3.x-dev" }, "zf": { "component": "Zend\\Mvc\\Plugin\\FlashMessenger" @@ -762,7 +761,7 @@ "mvc", "zf" ], - "time": "2018-04-30T18:47:56+00:00" + "time": "2019-10-19T22:24:02+00:00" }, { "name": "zendframework/zend-router", @@ -896,16 +895,16 @@ }, { "name": "zendframework/zend-session", - "version": "2.9.0", + "version": "2.9.1", "source": { "type": "git", "url": "https://github.com/zendframework/zend-session.git", - "reference": "0a0c7ae4d8be608e30ecff714c86164ccca19ca3" + "reference": "c289c4d733ec23a389e25c7c451f4d062088511f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-session/zipball/0a0c7ae4d8be608e30ecff714c86164ccca19ca3", - "reference": "0a0c7ae4d8be608e30ecff714c86164ccca19ca3", + "url": "https://api.github.com/repos/zendframework/zend-session/zipball/c289c4d733ec23a389e25c7c451f4d062088511f", + "reference": "c289c4d733ec23a389e25c7c451f4d062088511f", "shasum": "" }, "require": { @@ -959,7 +958,7 @@ "session", "zf" ], - "time": "2019-09-20T12:50:51+00:00" + "time": "2019-10-28T19:40:43+00:00" }, { "name": "zendframework/zend-stdlib", @@ -1009,16 +1008,16 @@ }, { "name": "zendframework/zend-uri", - "version": "2.7.0", + "version": "2.7.1", "source": { "type": "git", "url": "https://github.com/zendframework/zend-uri.git", - "reference": "b2785cd38fe379a784645449db86f21b7739b1ee" + "reference": "bfc4a5b9a309711e968d7c72afae4ac50c650083" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-uri/zipball/b2785cd38fe379a784645449db86f21b7739b1ee", - "reference": "b2785cd38fe379a784645449db86f21b7739b1ee", + "url": "https://api.github.com/repos/zendframework/zend-uri/zipball/bfc4a5b9a309711e968d7c72afae4ac50c650083", + "reference": "bfc4a5b9a309711e968d7c72afae4ac50c650083", "shasum": "" }, "require": { @@ -1052,20 +1051,20 @@ "uri", "zf" ], - "time": "2019-02-27T21:39:04+00:00" + "time": "2019-10-07T13:35:33+00:00" }, { "name": "zendframework/zend-validator", - "version": "2.12.0", + "version": "2.12.2", "source": { "type": "git", "url": "https://github.com/zendframework/zend-validator.git", - "reference": "64c33668e5fa2d39c6289a878f927ea2b0850c30" + "reference": "fd24920c2afcf2a70d11f67c3457f8f509453a62" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-validator/zipball/64c33668e5fa2d39c6289a878f927ea2b0850c30", - "reference": "64c33668e5fa2d39c6289a878f927ea2b0850c30", + "url": "https://api.github.com/repos/zendframework/zend-validator/zipball/fd24920c2afcf2a70d11f67c3457f8f509453a62", + "reference": "fd24920c2afcf2a70d11f67c3457f8f509453a62", "shasum": "" }, "require": { @@ -1119,26 +1118,26 @@ "license": [ "BSD-3-Clause" ], - "description": "provides a set of commonly needed validators", - "homepage": "https://github.com/zendframework/zend-validator", + "description": "Validation classes for a wide range of domains, and the ability to chain validators to create complex validation criteria", "keywords": [ + "ZendFramework", "validator", - "zf2" + "zf" ], - "time": "2019-01-30T14:26:10+00:00" + "time": "2019-10-29T08:33:25+00:00" }, { "name": "zendframework/zend-view", - "version": "2.11.2", + "version": "2.11.3", "source": { "type": "git", "url": "https://github.com/zendframework/zend-view.git", - "reference": "4f5cb653ed4c64bb8d9bf05b294300feb00c67f2" + "reference": "e766457bd6ce13c5354e443bb949511b6904d7f5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zendframework/zend-view/zipball/4f5cb653ed4c64bb8d9bf05b294300feb00c67f2", - "reference": "4f5cb653ed4c64bb8d9bf05b294300feb00c67f2", + "url": "https://api.github.com/repos/zendframework/zend-view/zipball/e766457bd6ce13c5354e443bb949511b6904d7f5", + "reference": "e766457bd6ce13c5354e443bb949511b6904d7f5", "shasum": "" }, "require": { @@ -1206,28 +1205,28 @@ "license": [ "BSD-3-Clause" ], - "description": "provides a system of helpers, output filters, and variable escaping", - "homepage": "https://github.com/zendframework/zend-view", + "description": "Flexible view layer supporting and providing multiple view layers, helpers, and more", "keywords": [ + "ZendFramework", "view", - "zf2" + "zf" ], - "time": "2019-02-19T17:40:15+00:00" + "time": "2019-10-11T21:10:04+00:00" } ], "packages-dev": [ { "name": "doctrine/instantiator", - "version": "1.2.0", + "version": "1.3.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "a2c590166b2133a4633738648b6b064edae0814a" + "reference": "ae466f726242e637cebdd526a7d991b9433bacf1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/a2c590166b2133a4633738648b6b064edae0814a", - "reference": "a2c590166b2133a4633738648b6b064edae0814a", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/ae466f726242e637cebdd526a7d991b9433bacf1", + "reference": "ae466f726242e637cebdd526a7d991b9433bacf1", "shasum": "" }, "require": { @@ -1270,7 +1269,7 @@ "constructor", "instantiate" ], - "time": "2019-03-17T17:37:11+00:00" + "time": "2019-10-21T16:45:58+00:00" }, { "name": "myclabs/deep-copy", @@ -1574,22 +1573,22 @@ }, { "name": "phpspec/prophecy", - "version": "1.8.1", + "version": "1.9.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "1927e75f4ed19131ec9bcc3b002e07fb1173ee76" + "reference": "f6811d96d97bdf400077a0cc100ae56aa32b9203" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/1927e75f4ed19131ec9bcc3b002e07fb1173ee76", - "reference": "1927e75f4ed19131ec9bcc3b002e07fb1173ee76", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/f6811d96d97bdf400077a0cc100ae56aa32b9203", + "reference": "f6811d96d97bdf400077a0cc100ae56aa32b9203", "shasum": "" }, "require": { "doctrine/instantiator": "^1.0.2", "php": "^5.3|^7.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0", + "phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0|^5.0", "sebastian/comparator": "^1.1|^2.0|^3.0", "sebastian/recursion-context": "^1.0|^2.0|^3.0" }, @@ -1633,7 +1632,7 @@ "spy", "stub" ], - "time": "2019-06-13T12:50:23+00:00" + "time": "2019-10-03T11:07:50+00:00" }, { "name": "phpunit/php-code-coverage", @@ -1889,16 +1888,16 @@ }, { "name": "phpunit/phpunit", - "version": "8.3.5", + "version": "8.4.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "302faed7059fde575cf3403a78c730c5e3a62750" + "reference": "67f9e35bffc0dd52d55d565ddbe4230454fd6a4e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/302faed7059fde575cf3403a78c730c5e3a62750", - "reference": "302faed7059fde575cf3403a78c730c5e3a62750", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/67f9e35bffc0dd52d55d565ddbe4230454fd6a4e", + "reference": "67f9e35bffc0dd52d55d565ddbe4230454fd6a4e", "shasum": "" }, "require": { @@ -1942,7 +1941,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "8.3-dev" + "dev-master": "8.4-dev" } }, "autoload": { @@ -1968,7 +1967,7 @@ "testing", "xunit" ], - "time": "2019-09-14T09:12:03+00:00" + "time": "2019-11-06T09:42:23+00:00" }, { "name": "sebastian/code-unit-reverse-lookup", @@ -2752,7 +2751,7 @@ "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": "^7.2" + "php": "^7.2.9" }, "platform-dev": [] } From e153f156b258e1c28ce5de1df96a36395a99ff8f Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Wed, 20 Nov 2019 10:49:26 +0100 Subject: [PATCH 08/11] twig final release --- composer.json | 2 +- composer.lock | 37 ++++++++++++++++++------------------- 2 files changed, 19 insertions(+), 20 deletions(-) diff --git a/composer.json b/composer.json index c611c92..ea8d6d1 100644 --- a/composer.json +++ b/composer.json @@ -24,7 +24,7 @@ ], "require": { "php": "^7.2.9", - "twig/twig": "3.x-dev", + "twig/twig": "^3.0.0", "zendframework/zend-mvc": "^3.0", "zendframework/zend-view": "^2.7", "zendframework/zend-servicemanager": "^3.0", diff --git a/composer.lock b/composer.lock index cbe602a..bf4d191 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "45829e7ec4ed2494a7a41613defeee74", + "content-hash": "2cfce0160b889ba7d285051f8be1916c", "packages": [ { "name": "container-interop/container-interop", @@ -35,6 +35,7 @@ ], "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" }, { @@ -205,16 +206,16 @@ }, { "name": "twig/twig", - "version": "3.x-dev", + "version": "v3.0.0", "source": { "type": "git", "url": "https://github.com/twigphp/Twig.git", - "reference": "d28774240a63d5db36dd47f21e4365ac57e18d77" + "reference": "9b58bb8ac7a41d72fbb5a7dc643e07923e5ccc26" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/twigphp/Twig/zipball/d28774240a63d5db36dd47f21e4365ac57e18d77", - "reference": "d28774240a63d5db36dd47f21e4365ac57e18d77", + "url": "https://api.github.com/repos/twigphp/Twig/zipball/9b58bb8ac7a41d72fbb5a7dc643e07923e5ccc26", + "reference": "9b58bb8ac7a41d72fbb5a7dc643e07923e5ccc26", "shasum": "" }, "require": { @@ -265,7 +266,7 @@ "keywords": [ "templating" ], - "time": "2019-11-11T16:57:14+00:00" + "time": "2019-11-15T20:38:32+00:00" }, { "name": "zendframework/zend-config", @@ -1636,16 +1637,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "7.0.8", + "version": "7.0.9", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "aa0d179a13284c7420fc281fc32750e6cc7c9e2f" + "reference": "075572dd777ea8317196838f8b59b1de2a642abc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/aa0d179a13284c7420fc281fc32750e6cc7c9e2f", - "reference": "aa0d179a13284c7420fc281fc32750e6cc7c9e2f", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/075572dd777ea8317196838f8b59b1de2a642abc", + "reference": "075572dd777ea8317196838f8b59b1de2a642abc", "shasum": "" }, "require": { @@ -1695,7 +1696,7 @@ "testing", "xunit" ], - "time": "2019-09-17T06:24:36+00:00" + "time": "2019-11-20T08:52:29+00:00" }, { "name": "phpunit/php-file-iterator", @@ -2136,16 +2137,16 @@ }, { "name": "sebastian/environment", - "version": "4.2.2", + "version": "4.2.3", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "f2a2c8e1c97c11ace607a7a667d73d47c19fe404" + "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/f2a2c8e1c97c11ace607a7a667d73d47c19fe404", - "reference": "f2a2c8e1c97c11ace607a7a667d73d47c19fe404", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/464c90d7bdf5ad4e8a6aea15c091fec0603d4368", + "reference": "464c90d7bdf5ad4e8a6aea15c091fec0603d4368", "shasum": "" }, "require": { @@ -2185,7 +2186,7 @@ "environment", "hhvm" ], - "time": "2019-05-05T09:05:15+00:00" + "time": "2019-11-20T08:46:58+00:00" }, { "name": "sebastian/exporter", @@ -2745,9 +2746,7 @@ ], "aliases": [], "minimum-stability": "stable", - "stability-flags": { - "twig/twig": 20 - }, + "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, "platform": { From 3a3e975015d8d5aa9b186a63b27f1d7ad9085b89 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Wed, 20 Nov 2019 11:16:46 +0100 Subject: [PATCH 09/11] fix stackLoader return --- src/Twig/StackLoader.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Twig/StackLoader.php b/src/Twig/StackLoader.php index 0c3734a..064f199 100644 --- a/src/Twig/StackLoader.php +++ b/src/Twig/StackLoader.php @@ -60,7 +60,7 @@ public function getDefaultSuffix(): string * {@inheritDoc} * @throws Error\LoaderError */ - protected function findTemplate(string $name, bool $throw = true): string + protected function findTemplate(string $name, bool $throw = true): ?string { $name = (string)$name; @@ -73,7 +73,7 @@ protected function findTemplate(string $name, bool $throw = true): string if (isset($this->errorCache[$name])) { if (!$throw) { - return false; + return $this->cache[$name] = null; } throw new Error\LoaderError($this->errorCache[$name]); } @@ -95,7 +95,7 @@ protected function findTemplate(string $name, bool $throw = true): string ); if (!$throw) { - return false; + return $this->cache[$name] = null; } throw new Error\LoaderError($this->errorCache[$name]); @@ -110,7 +110,7 @@ protected function findTemplate(string $name, bool $throw = true): string $this->errorCache[$name] = sprintf('There are no registered paths for namespace "%s".', $namespace); if (!$throw) { - return false; + return $this->cache[$name] = null; } throw new Error\LoaderError($this->errorCache[$name]); } @@ -131,7 +131,7 @@ protected function findTemplate(string $name, bool $throw = true): string ); if (!$throw) { - return false; + return $this->cache[$name] = null; } throw new Error\LoaderError($this->errorCache[$name]); From 8b18123eaf8b035ff4d1303d25f74ca307b3066a Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Wed, 20 Nov 2019 21:39:24 +0100 Subject: [PATCH 10/11] test update dependency update --- composer.json | 4 +++- composer.lock | 12 ++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index ea8d6d1..d9a8095 100644 --- a/composer.json +++ b/composer.json @@ -4,6 +4,8 @@ "type": "library", "keywords": [ "twig", + "twig2", + "twig3", "module", "zf", "zf3" @@ -43,7 +45,7 @@ "require-dev": { "zendframework/zend-navigation": "^2.7", "zendframework/zend-modulemanager": "^2.7", - "phpunit/phpunit": "^8.1.3" + "phpunit/phpunit": "^8.4.3" }, "replace": { "zf-commons/zfc-twig": "self.version" diff --git a/composer.lock b/composer.lock index bf4d191..e078aad 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "content-hash": "2cfce0160b889ba7d285051f8be1916c", + "content-hash": "01b05f21a89fb554674849200d50764f", "packages": [ { "name": "container-interop/container-interop", @@ -1637,16 +1637,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "7.0.9", + "version": "7.0.10", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "075572dd777ea8317196838f8b59b1de2a642abc" + "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/075572dd777ea8317196838f8b59b1de2a642abc", - "reference": "075572dd777ea8317196838f8b59b1de2a642abc", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/f1884187926fbb755a9aaf0b3836ad3165b478bf", + "reference": "f1884187926fbb755a9aaf0b3836ad3165b478bf", "shasum": "" }, "require": { @@ -1696,7 +1696,7 @@ "testing", "xunit" ], - "time": "2019-11-20T08:52:29+00:00" + "time": "2019-11-20T13:55:58+00:00" }, { "name": "phpunit/php-file-iterator", From db444586562ab7291a542f96ed7a7386df8f3fc3 Mon Sep 17 00:00:00 2001 From: KoKsPfLaNzE Date: Wed, 20 Nov 2019 21:44:42 +0100 Subject: [PATCH 11/11] better stackLoader cache --- src/Twig/StackLoader.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Twig/StackLoader.php b/src/Twig/StackLoader.php index 064f199..6165bc2 100644 --- a/src/Twig/StackLoader.php +++ b/src/Twig/StackLoader.php @@ -67,6 +67,12 @@ protected function findTemplate(string $name, bool $throw = true): ?string // normalize name $name = preg_replace('#/{2,}#', '/', strtr($name, '\\', '/')); + // Ensure we have the expected file extension + $defaultSuffix = $this->getDefaultSuffix(); + if (pathinfo($name, PATHINFO_EXTENSION) != $defaultSuffix) { + $name .= '.' . $defaultSuffix; + } + if (isset($this->cache[$name])) { return $this->cache[$name]; } @@ -78,12 +84,6 @@ protected function findTemplate(string $name, bool $throw = true): ?string throw new Error\LoaderError($this->errorCache[$name]); } - // Ensure we have the expected file extension - $defaultSuffix = $this->getDefaultSuffix(); - if (pathinfo($name, PATHINFO_EXTENSION) != $defaultSuffix) { - $name .= '.' . $defaultSuffix; - } - $this->validateName($name); $namespace = '__main__';