diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ff71c521b55..a90006431d2 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ jobs: strategy: fail-fast: false matrix: - php-versions: ['7.3', '7.4'] + php-versions: ['7.3', '7.4', '8.0'] dependencies: ['highest'] composer-arguments: [''] # to run --ignore-platform-reqs in experimental builds static-analysis: ['no'] @@ -27,8 +27,8 @@ jobs: # experimental: false # dependencies: 'highest' - # Experimental build for PHP 8 - #- php-versions: '8.0' + # Experimental build for PHP nightly + #- php-versions: 'nightly' # composer-arguments: '--ignore-platform-reqs' # static-analysis: 'no' # experimental: true diff --git a/Neos.ContentRepository/Classes/Domain/Model/NodeData.php b/Neos.ContentRepository/Classes/Domain/Model/NodeData.php index 38159d86e09..631e03f1c89 100644 --- a/Neos.ContentRepository/Classes/Domain/Model/NodeData.php +++ b/Neos.ContentRepository/Classes/Domain/Model/NodeData.php @@ -558,7 +558,7 @@ function ($childNodeData) { * @param array $dimensions * @return integer The number of child nodes */ - public function getNumberOfChildNodes($nodeTypeFilter = null, Workspace $workspace, array $dimensions) + public function getNumberOfChildNodes($nodeTypeFilter, Workspace $workspace, array $dimensions) { return $this->nodeDataRepository->countByParentAndNodeType($this->path, $nodeTypeFilter, $workspace, $dimensions); } diff --git a/Neos.ContentRepository/Tests/Functional/Domain/NodesTest.php b/Neos.ContentRepository/Tests/Functional/Domain/NodesTest.php index b3a35c39a4c..d34d6f52fe8 100644 --- a/Neos.ContentRepository/Tests/Functional/Domain/NodesTest.php +++ b/Neos.ContentRepository/Tests/Functional/Domain/NodesTest.php @@ -1098,9 +1098,9 @@ public function nodesCanBeCopiedBefore() $childNodes = $rootNode->getChildNodes(); $names = new \stdClass(); $names->names = []; - array_walk($childNodes, function ($value, $key, &$names) { + array_walk($childNodes, function ($value, $key) use (&$names) { $names->names[] = $value->getName(); - }, $names); + }); self::assertSame(['fluss', 'baz', 'flux'], $names->names); } @@ -1119,9 +1119,9 @@ public function nodesCanBeCopiedAfter() $childNodes = $rootNode->getChildNodes(); $names = new \stdClass(); $names->names = []; - array_walk($childNodes, function ($value, $key, &$names) { + array_walk($childNodes, function ($value, $key) use (&$names) { $names->names[] = $value->getName(); - }, $names); + }); self::assertSame(['baz', 'fluss', 'flux'], $names->names); } @@ -1174,9 +1174,9 @@ public function nodesAreCopiedBeforeRecursively() $names = new \stdClass(); $names->names = []; - array_walk($copiedChildNodes, function ($value, $key, &$names) { + array_walk($copiedChildNodes, function ($value, $key) use (&$names) { $names->names[] = $value->getName(); - }, $names); + }); self::assertSame(['capacitor', 'second', 'third'], $names->names); } @@ -1197,9 +1197,9 @@ public function nodesAreCopiedAfterRecursively() $names = new \stdClass(); $names->names = []; - array_walk($copiedChildNodes, function ($value, $key, &$names) { + array_walk($copiedChildNodes, function ($value, $key) use (&$names) { $names->names[] = $value->getName(); - }, $names); + }); self::assertSame(['capacitor', 'second', 'third'], $names->names); } diff --git a/Neos.ContentRepository/Tests/Unit/Domain/Service/NodeServiceTest.php b/Neos.ContentRepository/Tests/Unit/Domain/Service/NodeServiceTest.php index c62308a7026..fae6de971ac 100644 --- a/Neos.ContentRepository/Tests/Unit/Domain/Service/NodeServiceTest.php +++ b/Neos.ContentRepository/Tests/Unit/Domain/Service/NodeServiceTest.php @@ -17,6 +17,7 @@ use Neos\ContentRepository\Domain\Model\NodeType; use Neos\ContentRepository\Domain\Service\NodeService; use Neos\ContentRepository\Domain\Service\NodeTypeManager; +use Neos\Flow\Utility\Algorithms; /** * Testcase for the NodeService @@ -196,7 +197,7 @@ public function createChildNodesTryToCreateAllConfiguredChildNodes() { $nodeService = $this->createNodeService(); - $mockNode = $this->getMockBuilder(Node::class)->disableOriginalConstructor()->getMock(); + $mockNode = $this->getMockBuilder(Node::class)->disableOriginalConstructor()->onlyMethods(['getNodeType', 'createNode', 'getIdentifier'])->getMock(); $mockNodeType = $this->mockNodeType('Neos.ContentRepository.Testing:Content'); $firstChildNodeType = $this->mockNodeType('Neos.ContentRepository.Testing:Content'); @@ -209,6 +210,8 @@ public function createChildNodesTryToCreateAllConfiguredChildNodes() 'second-child-node-name' => $secondChildNodeType ])); + $mockNode->method('getIdentifier')->willReturn(Algorithms::generateUUID()); + $mockNode->expects(self::once()) ->method('getNodeType') ->will(self::returnValue($mockNodeType)); diff --git a/Neos.ContentRepository/composer.json b/Neos.ContentRepository/composer.json index c1bd62666b4..134bfd5e41c 100644 --- a/Neos.ContentRepository/composer.json +++ b/Neos.ContentRepository/composer.json @@ -6,7 +6,7 @@ "GPL-3.0-or-later" ], "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/flow": "*", "neos/cache": "*", "neos/eel": "*", @@ -126,4 +126,4 @@ "Neos.Flow-20201109224100" ] } -} \ No newline at end of file +} diff --git a/Neos.Diff/composer.json b/Neos.Diff/composer.json index 0da337d1324..880cd4c93a9 100644 --- a/Neos.Diff/composer.json +++ b/Neos.Diff/composer.json @@ -4,7 +4,7 @@ "license": "BSD-3-Clause", "description": "This is a comprehensive library for generating differences between two strings or arrays", "require": { - "php": "^7.3" + "php": "^7.3 || ^8.0" }, "autoload": { "psr-4": { diff --git a/Neos.Fusion/Classes/Core/Cache/ContentCache.php b/Neos.Fusion/Classes/Core/Cache/ContentCache.php index cc4e3d1ba89..7d494431422 100644 --- a/Neos.Fusion/Classes/Core/Cache/ContentCache.php +++ b/Neos.Fusion/Classes/Core/Cache/ContentCache.php @@ -157,7 +157,7 @@ public function createUncachedSegment($content, $fusionPath, array $contextVaria * @param string $cacheDiscriminator The evaluated cache discriminator value * @return string The original content, but with additional markers added */ - public function createDynamicCachedSegment($content, $fusionPath, array $contextVariables, array $cacheIdentifierValues, array $tags = [], $lifetime = null, $cacheDiscriminator) + public function createDynamicCachedSegment($content, $fusionPath, array $contextVariables, array $cacheIdentifierValues, array $tags, $lifetime, $cacheDiscriminator) { $metadata = implode(',', $tags); if ($lifetime !== null) { diff --git a/Neos.Fusion/composer.json b/Neos.Fusion/composer.json index 1bfe2c2a6a8..b45903a5e26 100644 --- a/Neos.Fusion/composer.json +++ b/Neos.Fusion/composer.json @@ -6,7 +6,7 @@ "GPL-3.0-or-later" ], "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/flow": "*", "neos/fluid-adaptor": "*", "neos/cache": "*", diff --git a/Neos.Media.Browser/composer.json b/Neos.Media.Browser/composer.json index 9bdc413af8a..b224454b28e 100644 --- a/Neos.Media.Browser/composer.json +++ b/Neos.Media.Browser/composer.json @@ -6,7 +6,7 @@ "GPL-3.0-or-later" ], "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/media": "self.version", "neos/content-repository": "self.version", "neos/neos": "self.version", @@ -15,7 +15,7 @@ "neos/utility-files": "*", "neos/utility-mediatypes": "*", "neos/error-messages": "*", - "doctrine/common": "^2.7", + "doctrine/common": "^2.7 || ^3.0", "doctrine/orm": "^2.6" }, "autoload": { diff --git a/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetAssetCollectionConditionGenerator.php b/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetAssetCollectionConditionGenerator.php index ff6b04d1d79..0112b309dfc 100644 --- a/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetAssetCollectionConditionGenerator.php +++ b/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetAssetCollectionConditionGenerator.php @@ -11,7 +11,7 @@ * source code. */ -use Doctrine\Common\Persistence\Mapping\ClassMetadata; +use Doctrine\Persistence\Mapping\ClassMetadata; use Doctrine\ORM\EntityManagerInterface; use Doctrine\ORM\Query\Filter\SQLFilter as DoctrineSqlFilter; use Neos\Flow\Annotations as Flow; diff --git a/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetTagConditionGenerator.php b/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetTagConditionGenerator.php index 0c8c6006715..1a27881dcd8 100644 --- a/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetTagConditionGenerator.php +++ b/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetTagConditionGenerator.php @@ -11,7 +11,7 @@ * source code. */ -use Doctrine\Common\Persistence\Mapping\ClassMetadata; +use Doctrine\Persistence\Mapping\ClassMetadata; use Doctrine\ORM\EntityManagerInterface; use Doctrine\ORM\Query\Filter\SQLFilter as DoctrineSqlFilter; use Neos\Flow\Annotations as Flow; diff --git a/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetWithoutAssetCollectionConditionGenerator.php b/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetWithoutAssetCollectionConditionGenerator.php index 39d622db28c..a786aa8fa24 100644 --- a/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetWithoutAssetCollectionConditionGenerator.php +++ b/Neos.Media/Classes/Security/Authorization/Privilege/Doctrine/AssetWithoutAssetCollectionConditionGenerator.php @@ -11,7 +11,7 @@ * source code. */ -use Doctrine\Common\Persistence\Mapping\ClassMetadata; +use Doctrine\Persistence\Mapping\ClassMetadata; use Doctrine\ORM\EntityManagerInterface; use Doctrine\ORM\Query\Filter\SQLFilter as DoctrineSqlFilter; use Neos\Flow\Annotations as Flow; diff --git a/Neos.Media/composer.json b/Neos.Media/composer.json index 4f758bf834c..5e0cea78686 100644 --- a/Neos.Media/composer.json +++ b/Neos.Media/composer.json @@ -6,7 +6,7 @@ "GPL-3.0-or-later" ], "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/imagine": "^3.1.0", "neos/flow": "*", "neos/cache": "*", @@ -14,7 +14,7 @@ "neos/utility-objecthandling": "*", "neos/utility-arrays": "*", "imagine/imagine": "*", - "doctrine/common": "^2.7", + "doctrine/common": "^2.7 || ^3.0", "doctrine/orm": "^2.6", "doctrine/dbal": "^2.8" }, @@ -123,4 +123,4 @@ "Neos.Flow-20201109224100" ] } -} \ No newline at end of file +} diff --git a/Neos.Neos/composer.json b/Neos.Neos/composer.json index 73ff4ac08b5..97fdb217236 100644 --- a/Neos.Neos/composer.json +++ b/Neos.Neos/composer.json @@ -6,7 +6,7 @@ ], "description": "An open source Content Application Platform based on Flow. A set of core Content Management features is resting within a larger context that allows you to build a perfectly customized experience for your users.", "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/diff": "~7.1.0", "neos/flow": "~7.1.0", "neos/media-browser": "~7.1.0", diff --git a/Neos.NodeTypes.Form/composer.json b/Neos.NodeTypes.Form/composer.json index a6afa7af1de..15876766cc7 100644 --- a/Neos.NodeTypes.Form/composer.json +++ b/Neos.NodeTypes.Form/composer.json @@ -6,7 +6,7 @@ "GPL-3.0-or-later" ], "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/neos": "*", "neos/form": "*", "neos/nodetypes-basemixins": "*" diff --git a/Neos.SiteKickstarter/composer.json b/Neos.SiteKickstarter/composer.json index 853bdad23d8..f22aca94b08 100755 --- a/Neos.SiteKickstarter/composer.json +++ b/Neos.SiteKickstarter/composer.json @@ -4,7 +4,7 @@ "description": "A simple generator for Neos assets, like sites and plugins.", "license": ["GPL-3.0-or-later"], "require": { - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/flow": "*", "neos/utility-files": "*", "neos/fluid-adaptor": "*", diff --git a/composer.json b/composer.json index 8ab5ea64fed..2a9b2a2b39b 100644 --- a/composer.json +++ b/composer.json @@ -8,7 +8,7 @@ "require": { "neos/flow-development-collection": "7.1.x-dev", "neos/neos-setup": "^1.0", - "php": "^7.3", + "php": "^7.3 || ^8.0", "neos/flow": "*", "neos/cache": "*", "neos/eel": "*", @@ -22,7 +22,7 @@ "neos/utility-unicode": "*", "neos/utility-mediatypes": "*", "neos/error-messages": "*", - "doctrine/common": "^2.7", + "doctrine/common": "^2.7 || ^3.0", "neos/imagine": "^3.1.0", "imagine/imagine": "*", "doctrine/dbal": "^2.8",