From 8e568291b0d2717eb517ab9b79b741743019ff35 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Fri, 13 Oct 2023 09:03:33 +0200 Subject: [PATCH 01/12] FEATURE: NodeMigration with target workspace --- .../src/Command/ExecuteMigration.php | 33 +++---------------- .../src/NodeMigrationService.php | 20 +++++++---- .../Features/Bootstrap/MigrationsTrait.php | 7 ++-- .../NodeMigrationCommandController.php | 12 +++++-- 4 files changed, 30 insertions(+), 42 deletions(-) diff --git a/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php b/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php index ed34f8d0a43..65f5fab56e6 100644 --- a/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php +++ b/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php @@ -22,16 +22,6 @@ */ final class ExecuteMigration { - /** - * @var MigrationConfiguration - */ - private $migrationConfiguration; - - /** - * @var WorkspaceName - */ - private $workspaceName; - /** * This property exists mostly for testing, to make the command handler fully deterministic. * @@ -55,42 +45,29 @@ final class ExecuteMigration /** * ExecuteMigration constructor. - * @param MigrationConfiguration $migrationConfiguration - * @param WorkspaceName $workspaceName * @param ContentStreamId[] $contentStreamIdsForWriting */ public function __construct( - MigrationConfiguration $migrationConfiguration, - WorkspaceName $workspaceName, + private readonly MigrationConfiguration $migrationConfiguration, + private readonly WorkspaceName $workspaceName, + private readonly ?WorkspaceName $targetWorkspaceName, array $contentStreamIdsForWriting = [] ) { - $this->migrationConfiguration = $migrationConfiguration; - $this->workspaceName = $workspaceName; $this->contentStreamIdsForWriting = array_values($contentStreamIdsForWriting); } - /** - * @return MigrationConfiguration - */ public function getMigrationConfiguration(): MigrationConfiguration { return $this->migrationConfiguration; } - /** - * @return WorkspaceName - */ public function getWorkspaceName(): WorkspaceName { return $this->workspaceName; } - public function getOrCreateContentStreamIdForWriting(int $index): ContentStreamId + public function getTargetWorkspaceName(): ?WorkspaceName { - if (isset($this->contentStreamIdsForWriting[$index])) { - return $this->contentStreamIdsForWriting[$index]; - } - - return ContentStreamId::create(); + return $this->targetWorkspaceName; } } diff --git a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php index ccf503359f6..5cde0a8d8a7 100644 --- a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php +++ b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php @@ -66,22 +66,30 @@ public function executeMigration(ExecuteMigration $command): void ), 1611688225); } - foreach ($command->getMigrationConfiguration()->getMigration() as $step => $migrationDescription) { - $contentStreamForWriting = $command->getOrCreateContentStreamIdForWriting($step); + if ($command->getTargetWorkspaceName() !== null) { + $targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName()); + } + + if ($targetWorkspace) { + $targetContentStreamId = $targetWorkspace->currentContentStreamId; + } else { + $targetContentStreamId = ContentStreamId::create(); $this->contentRepository->handle( CreateWorkspace::create( - WorkspaceName::fromString($contentStreamForWriting->value), + $command->getTargetWorkspaceName() ?? WorkspaceName::fromString($targetContentStreamId->value), $workspace->workspaceName, - WorkspaceTitle::fromString($contentStreamForWriting->value), + WorkspaceTitle::fromString($command->getTargetWorkspaceName()?->value ?? $targetContentStreamId->value), WorkspaceDescription::fromString(''), - $contentStreamForWriting, + $targetContentStreamId, ) )->block(); + } + foreach ($command->getMigrationConfiguration()->getMigration() as $migrationDescription) { /** array $migrationDescription */ $this->executeSubMigrationAndBlock( $migrationDescription, $workspace->currentContentStreamId, - $contentStreamForWriting + $targetContentStreamId ); } } diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php index 154a8337ea7..69d9624dd44 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php @@ -35,12 +35,9 @@ trait MigrationsTrait */ public function iRunTheFollowingNodeMigration(string $workspaceName, string $contentStreams, PyStringNode $string): void { + // TODO: Replace ContentStream with Workspace $migrationConfiguration = new MigrationConfiguration(Yaml::parse($string->getRaw())); - $contentStreamIds = array_map( - fn (string $cs) => ContentStreamId::fromString($cs), - explode(',', $contentStreams) - ); - $command = new ExecuteMigration($migrationConfiguration, WorkspaceName::fromString($workspaceName), $contentStreamIds); + $command = new ExecuteMigration($migrationConfiguration, WorkspaceName::fromString($workspaceName), null); /** @var NodeMigrationService $nodeMigrationService */ $nodeMigrationService = $this->getContentRepositoryService(new NodeMigrationServiceFactory()); diff --git a/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php b/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php index d600334d299..e6fa84bc972 100644 --- a/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php +++ b/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php @@ -34,7 +34,6 @@ #[Flow\Scope('singleton')] class NodeMigrationCommandController extends CommandController { - public function __construct( private readonly MigrationFactory $migrationFactory, private readonly ContentRepositoryRegistry $contentRepositoryRegistry, @@ -49,13 +48,16 @@ public function __construct( * * @param string $version The version of the migration configuration you want to use. * @param string $workspace The workspace where the migration should be applied; by default "live" + * @param ?string $targetWorkspace The workspace where the migration result should end; by default "live". If set to null, each migration creates a new workspace for selectiv publishing. * @param boolean $force Confirm application of this migration, only needed if the given migration contains any warnings. * @return void * @throws StopCommandException * @see neos.contentrepositoryregistry:nodemigration:execute */ - public function executeCommand(string $version, string $workspace = 'live', bool $force = false, string $contentRepositoryIdentifier = 'default'): void + public function executeCommand(string $version, string $workspace = 'live', ?string $targetWorkspace = 'live', bool $force = false, string $contentRepositoryIdentifier = 'default'): void { + $workspace = WorkspaceName::fromString($workspace); + $targetWorkspace = $targetWorkspace === null ?: WorkspaceName::fromString($targetWorkspace); $contentRepositoryId = ContentRepositoryId::fromString($contentRepositoryIdentifier); try { @@ -73,9 +75,13 @@ public function executeCommand(string $version, string $workspace = 'live', bool $nodeMigrationService->executeMigration( new ExecuteMigration( $migrationConfiguration, - WorkspaceName::fromString($workspace) + $workspace, + $targetWorkspace, ) ); + + // Rebase depending workspaces? + $this->outputLine(); $this->outputLine('Successfully applied migration.'); } catch (MigrationException $e) { From dc35ae954f783e335e3087cc8d3b694042e04150 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 Nov 2023 16:46:15 +0100 Subject: [PATCH 02/12] TASK: Node migration command overhaul --- .../src/Command/ExecuteMigration.php | 44 +++++------------ .../src/NodeMigrationService.php | 49 ++++++++++++++----- .../NodeMigrationCommandController.php | 28 +++++++---- 3 files changed, 67 insertions(+), 54 deletions(-) diff --git a/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php b/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php index 65f5fab56e6..22e23dc01c6 100644 --- a/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php +++ b/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php @@ -14,7 +14,6 @@ namespace Neos\ContentRepository\NodeMigration\Command; -use Neos\ContentRepository\Core\SharedModel\Workspace\ContentStreamId; use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceName; /** @@ -22,38 +21,12 @@ */ final class ExecuteMigration { - /** - * This property exists mostly for testing, to make the command handler fully deterministic. - * - * A migration file is structured like this: - * migrations: [ - * {filters: ... transformations: ...}, - * {filters: ... transformations: ...} - * ] - * For every "submigration" (i.e. every "line" from above), we fork a new content stream, - * to make the migration roll-back-able. - * In the first "submigration", we use the base content stream identifier (of $workspaceName) for *reading*, and - * use the first content stream identifier of this list for writing. - * In the second "submigration", we use the content stream of the *first* submigration for reading, and the next one - * from this list for writing. - * - * This effectively makes all changes of the first submigration visible in the next submigration. - * - * @var ContentStreamId[] - */ - private $contentStreamIdsForWriting; - - /** - * ExecuteMigration constructor. - * @param ContentStreamId[] $contentStreamIdsForWriting - */ public function __construct( private readonly MigrationConfiguration $migrationConfiguration, - private readonly WorkspaceName $workspaceName, - private readonly ?WorkspaceName $targetWorkspaceName, - array $contentStreamIdsForWriting = [] + private readonly WorkspaceName $sourceWorkspaceName, + private readonly WorkspaceName $targetWorkspaceName, + private readonly bool $publishOnSuccess, ) { - $this->contentStreamIdsForWriting = array_values($contentStreamIdsForWriting); } public function getMigrationConfiguration(): MigrationConfiguration @@ -61,13 +34,18 @@ public function getMigrationConfiguration(): MigrationConfiguration return $this->migrationConfiguration; } - public function getWorkspaceName(): WorkspaceName + public function getSourceWorkspaceName(): WorkspaceName { - return $this->workspaceName; + return $this->sourceWorkspaceName; } - public function getTargetWorkspaceName(): ?WorkspaceName + public function getTargetWorkspaceName(): WorkspaceName { return $this->targetWorkspaceName; } + + public function getPublishOnSuccess(): bool + { + return $this->publishOnSuccess; + } } diff --git a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php index 5cde0a8d8a7..14e470c75df 100644 --- a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php +++ b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php @@ -17,6 +17,11 @@ use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceDescription; use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceName; use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceTitle; +use Neos\ContentRepository\Core\Projection\Workspace\Workspace; +use Neos\Neos\PendingChangesProjection\ChangeProjection; +use Neos\ContentRepository\Core\Feature\WorkspacePublication\Command\PublishWorkspace; +use Neos\ContentRepository\Core\Feature\WorkspaceModification\Command\DeleteWorkspace; +use Neos\Neos\PendingChangesProjection\ChangeFinder; /** * Node Migrations are manually written adjustments to the Node tree; @@ -58,40 +63,55 @@ public function __construct( public function executeMigration(ExecuteMigration $command): void { - $workspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getWorkspaceName()); - if ($workspace === null) { + $sourceWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getSourceWorkspaceName()); + if ($sourceWorkspace === null) { throw new WorkspaceDoesNotExist(sprintf( 'The workspace %s does not exist', - $command->getWorkspaceName()->value + $command->getSourceWorkspaceName()->value ), 1611688225); } - if ($command->getTargetWorkspaceName() !== null) { - $targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName()); - } + $targetWorkspaceWasCreated = false; + if ($targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName())) { + if (!$this->workspaceIsEmpty($targetWorkspace)) { + throw new MigrationException(sprintf('Target workspace "%s" already exists an is not empty. Please clear the workspace before.', $targetWorkspace->workspaceName->value)); + } - if ($targetWorkspace) { $targetContentStreamId = $targetWorkspace->currentContentStreamId; + } else { $targetContentStreamId = ContentStreamId::create(); $this->contentRepository->handle( CreateWorkspace::create( - $command->getTargetWorkspaceName() ?? WorkspaceName::fromString($targetContentStreamId->value), - $workspace->workspaceName, - WorkspaceTitle::fromString($command->getTargetWorkspaceName()?->value ?? $targetContentStreamId->value), + $command->getTargetWorkspaceName(), + $sourceWorkspace->workspaceName, + WorkspaceTitle::fromString($command->getTargetWorkspaceName()->value), WorkspaceDescription::fromString(''), $targetContentStreamId, ) )->block(); + $targetWorkspaceWasCreated = true; } foreach ($command->getMigrationConfiguration()->getMigration() as $migrationDescription) { /** array $migrationDescription */ $this->executeSubMigrationAndBlock( $migrationDescription, - $workspace->currentContentStreamId, + $sourceWorkspace->currentContentStreamId, $targetContentStreamId ); } + + if ($command->getPublishOnSuccess() === true) { + $this->contentRepository->handle( + PublishWorkspace::create($command->getTargetWorkspaceName()) + ); + + if ($targetWorkspaceWasCreated === true) { + $this->contentRepository->handle( + DeleteWorkspace::create($command->getTargetWorkspaceName()) + ); + } + } } /** @@ -180,4 +200,11 @@ protected function executeSubMigrationAndBlock( } } } + + private function workspaceIsEmpty(Workspace $workspace): bool + { + return $this->contentRepository + ->projectionState(ChangeFinder::class) + ->countByContentStreamId($workspace->currentContentStreamId) === 0; + } } diff --git a/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php b/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php index e6fa84bc972..fd5a92ebfe6 100644 --- a/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php +++ b/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php @@ -47,17 +47,18 @@ public function __construct( * Do the configured migrations in the given migration. * * @param string $version The version of the migration configuration you want to use. - * @param string $workspace The workspace where the migration should be applied; by default "live" - * @param ?string $targetWorkspace The workspace where the migration result should end; by default "live". If set to null, each migration creates a new workspace for selectiv publishing. + * @param string $sourceWorkspace The workspace where the migration should be applied; by default "live" + * @param bool $publishOnSuccess If true, the changes get published automatically after successful apply (default: true). * @param boolean $force Confirm application of this migration, only needed if the given migration contains any warnings. + * @param string $contentRepositoryIdentifier * @return void * @throws StopCommandException * @see neos.contentrepositoryregistry:nodemigration:execute */ - public function executeCommand(string $version, string $workspace = 'live', ?string $targetWorkspace = 'live', bool $force = false, string $contentRepositoryIdentifier = 'default'): void + public function executeCommand(string $version, string $sourceWorkspace = 'live', bool $publishOnSuccess = true, bool $force = false, string $contentRepositoryIdentifier = 'default'): void { - $workspace = WorkspaceName::fromString($workspace); - $targetWorkspace = $targetWorkspace === null ?: WorkspaceName::fromString($targetWorkspace); + $sourceWorkspaceName = WorkspaceName::fromString($sourceWorkspace); + $targetWorkspaceName = WorkspaceName::fromString(sprintf('migration-%s-%s', $sourceWorkspaceName->value, $version)); $contentRepositoryId = ContentRepositoryId::fromString($contentRepositoryIdentifier); try { @@ -75,18 +76,25 @@ public function executeCommand(string $version, string $workspace = 'live', ?str $nodeMigrationService->executeMigration( new ExecuteMigration( $migrationConfiguration, - $workspace, - $targetWorkspace, + $sourceWorkspaceName, + $targetWorkspaceName, + $publishOnSuccess ) ); - // Rebase depending workspaces? - $this->outputLine(); $this->outputLine('Successfully applied migration.'); + if ($publishOnSuccess) { + $this->outputLine('You should rebase all outdated workspaces to ensure every workspace get the changes immediately. `./flow workspace:rebaseoutdated`'); + } else { + $this->outputLine(sprintf('We created a workspace "%s" for review. Please review changes an publish them to "%s".', $targetWorkspaceName->value, $sourceWorkspaceName->value)); + $this->outputLine('You should rebase all outdated workspaces after publishing to ensure every workspace get the changes immediately. `./flow workspace:rebaseoutdated`'); + } + } catch (MigrationException $e) { $this->outputLine(); - $this->outputLine('Error: ' . $e->getMessage()); + $this->outputLine('Error on applying node migrations:'); + $this->outputLine($e->getMessage()); $this->quit(1); } } From 046024948298d9045878ce73905b63d0d13235ae Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 Nov 2023 16:53:46 +0100 Subject: [PATCH 03/12] TASK: Node migration command overhaul --- .../AddDimensionShineThrough.feature | 12 ++++----- .../AddNewProperty_NoDimensions.feature | 2 +- .../ChangePropertyValue_Dimensions.feature | 10 +++---- .../ChangePropertyValue_NoDimensions.feature | 12 ++++----- .../Filter_NodeName_NoDimensions.feature | 2 +- ...lter_PropertyNotEmpty_NoDimensions.feature | 2 +- .../Filter_PropertyValue_NoDimensions.feature | 2 +- .../Migration/MoveDimensionSpacePoint.feature | 8 +++--- .../NodeTypeAdjustment_Dimensions.feature | 2 +- .../NodeTypeAdjustment_NoDimensions.feature | 2 +- .../Migration/RemoveNodes_Dimensions.feature | 14 +++++----- .../RemoveProperty_NoDimensions.feature | 4 +-- .../RenameNodeAggregate_Dimensions.feature | 4 +-- .../RenameProperty_NoDimensions.feature | 2 +- .../StripTagsOnProperty_NoDimensions.feature | 2 +- .../Features/Bootstrap/MigrationsTrait.php | 26 ++++++++++++++----- .../FrontendRouting/Dimensions.feature | 4 +-- 17 files changed, 61 insertions(+), 49 deletions(-) diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature index 2c1b41dcd60..f3847500990 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature @@ -61,7 +61,7 @@ Feature: Add Dimension Specialization Given I change the content dimensions in content repository "default" to: | Identifier | Values | Generalizations | | language | mul, de, ch | ch->de->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -156,7 +156,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, ch | ch->de->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -200,7 +200,7 @@ Feature: Add Dimension Specialization | sourceOrigin | {"language":"de"} | | targetOrigin | {"language":"en"} | - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - @@ -214,7 +214,7 @@ Feature: Add Dimension Specialization Then the last command should have thrown an exception of type "DimensionSpacePointAlreadyExists" Scenario: Error case - the target dimension is not configured - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - @@ -233,7 +233,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, foo | de->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - @@ -252,7 +252,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, foo | de->mul, foo->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature index 8bf55a12488..008519d978e 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature @@ -53,7 +53,7 @@ Feature: Add New Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature index f094e12c200..4667cd8b1e5 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature @@ -57,7 +57,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints Scenario: change materialized "de" node, should shine through in "ch", but not in "en" - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -129,7 +129,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | targetOrigin | {"language":"ch"} | And the graph projection is fully up to date - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -176,7 +176,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | targetOrigin | {"language":"ch"} | And the graph projection is fully up to date - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -215,7 +215,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints Scenario: matching only happens based on originDimensionSpacePoint, not on visibleDimensionSpacePoints - we try to change CH, but should not see any modification (includeSpecializations = FALSE - default) - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -252,7 +252,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | text | "Original text" | Scenario: matching only happens based on originDimensionSpacePoint, not on visibleDimensionSpacePoints - we try to change CH, but should not see any modification (includeSpecializations = TRUE) - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature index db580202967..3349f01f0a5 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature @@ -43,7 +43,7 @@ Feature: Change Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -74,7 +74,7 @@ Feature: Change Property | text | "fixed value" | Scenario: Ignoring transformation if property does not exist on node - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -98,7 +98,7 @@ Feature: Change Property | text | "Original text" | Scenario: replacement using default currentValuePlaceholder - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -121,7 +121,7 @@ Feature: Change Property | text | "bla Original text" | Scenario: replacement using alternative currentValuePlaceholder - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -145,7 +145,7 @@ Feature: Change Property | text | "bla Original text" | Scenario: using search/replace - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -169,7 +169,7 @@ Feature: Change Property | text | "alternative text" | Scenario: using search/replace including placeholder (all options) - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature index 51e75cc63c8..53200a0e0bb 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature @@ -67,7 +67,7 @@ Feature: Filter - Node Name Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature index 7fe4dc3fa01..95ee1a791e9 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature @@ -78,7 +78,7 @@ Feature: Filter - Property not empty Scenario: PropertyNotEmpty - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature index 7bca2e345b6..df5682f5d49 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature @@ -78,7 +78,7 @@ Feature: Filter - Property Value Scenario: PropertyValue - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature index 73512873b28..f844ad4662a 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature @@ -59,7 +59,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, de_DE | de_DE->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -109,7 +109,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, de_DE | de_DE->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -144,7 +144,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, ch | ch->mul | - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - @@ -158,7 +158,7 @@ Feature: Move dimension space point Then the last command should have thrown an exception of type "DimensionSpacePointAlreadyExists" Scenario: Error case - the target dimension is not configured - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature index 3b433612102..fd648d947c9 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature @@ -60,7 +60,7 @@ Feature: Adjust node types with a node migration 'Neos.ContentRepository.Testing:OtherDocument': [] """ # we should be able to rename the node type - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature index 511099385b9..e40539ed828 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature @@ -58,7 +58,7 @@ Feature: Adjust node types with a node migration 'Neos.ContentRepository.Testing:OtherDocument': [] """ # we should be able to rename the node type - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature index 7c07c7fe455..3c62603fd9f 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature @@ -55,7 +55,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a given dimension space point removes the node with all virtual specializations - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -98,7 +98,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a given dimension space point removes the node without shine-throughs with strategy "allSpecializations" - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -144,7 +144,7 @@ Feature: Remove Nodes Scenario: allVariants is not supported in RemoveNode, as this would violate the filter configuration potentially - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - @@ -168,7 +168,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a virtual specialization (gsw) - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -214,7 +214,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a shine-through dimension space point (gsw) - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -255,7 +255,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a shine-through dimension space point (DE,gsw) - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -300,7 +300,7 @@ Feature: Remove Nodes Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (DE,gsw) - variant 2 - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature index 814dd9e5f2d..d7dc4c95ecf 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature @@ -43,7 +43,7 @@ Feature: Remove Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -71,7 +71,7 @@ Feature: Remove Property And I expect this node to have no properties Scenario: Ignoring transformation if property does not exist on node - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature index 0dbe9995e01..1c5d7c03190 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature @@ -56,7 +56,7 @@ Feature: Rename Node Aggregate Scenario: Rename Node Aggregate - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -92,7 +92,7 @@ Feature: Rename Node Aggregate Scenario: Rename Node Aggregate will fail when restricted to a single Dimension - When I run the following node migration for workspace "live", creating content streams "migration-cs" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature index bfba5f15260..8a0515c7729 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature @@ -56,7 +56,7 @@ Feature: Rename Property newText: type: string """ - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature index d075f010fc1..f38796e4ae6 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature @@ -43,7 +43,7 @@ Feature: Strip Tags on Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php index 69d9624dd44..329edf1be36 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php @@ -31,13 +31,17 @@ trait MigrationsTrait use CRTestSuiteRuntimeVariables; /** - * @When I run the following node migration for workspace :workspaceName, creating content streams :contentStreams: + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName: */ - public function iRunTheFollowingNodeMigration(string $workspaceName, string $contentStreams, PyStringNode $string): void + public function iRunTheFollowingNodeMigration(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string, bool $publishingOnSuccess = true): void { - // TODO: Replace ContentStream with Workspace $migrationConfiguration = new MigrationConfiguration(Yaml::parse($string->getRaw())); - $command = new ExecuteMigration($migrationConfiguration, WorkspaceName::fromString($workspaceName), null); + $command = new ExecuteMigration( + $migrationConfiguration, + WorkspaceName::fromString($sourceWorkspaceName), + WorkspaceName::fromString($targetWorkspaceName), + $publishingOnSuccess + ); /** @var NodeMigrationService $nodeMigrationService */ $nodeMigrationService = $this->getContentRepositoryService(new NodeMigrationServiceFactory()); @@ -45,12 +49,20 @@ public function iRunTheFollowingNodeMigration(string $workspaceName, string $con } /** - * @When I run the following node migration for workspace :workspaceName, creating content streams :contentStreams and exceptions are caught: + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName, without publishing on success: */ - public function iRunTheFollowingNodeMigrationAndExceptionsAreCaught(string $workspaceName, string $contentStreams, PyStringNode $string): void + public function iRunTheFollowingNodeMigrationWithoutPublishingOnSuccess(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string): void + { + $this->iRunTheFollowingNodeMigration($sourceWorkspaceName, $targetWorkspaceName, $string, false); + } + + /** + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName and exceptions are caught: + */ + public function iRunTheFollowingNodeMigrationAndExceptionsAreCaught(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string): void { try { - $this->iRunTheFollowingNodeMigration($workspaceName, $contentStreams, $string); + $this->iRunTheFollowingNodeMigration($sourceWorkspaceName, $targetWorkspaceName, $string); } catch (\Exception $exception) { $this->lastCommandException = $exception; } diff --git a/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature b/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature index c6a9da1b7bf..66e68b4bc4f 100644 --- a/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature +++ b/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature @@ -188,7 +188,7 @@ Feature: Routing functionality with multiple content dimensions en: '' """ - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - @@ -258,7 +258,7 @@ Feature: Routing functionality with multiple content dimensions en: '' """ And the node "carl-destinode" in content stream "cs-identifier" and dimension '{"market":"DE", "language":"at"}' should not resolve to an URL - When I run the following node migration for workspace "live", creating content streams "migration-cs": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace": """yaml migration: - From a7b60f74abf3d0e26f7b6983ebeebab650b433eb Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 21:50:55 +0200 Subject: [PATCH 04/12] TASK: Fix existing behat tests, to work with workspaces instead of contentstreams --- .../AddDimensionShineThrough.feature | 36 +++---- .../AddNewProperty_NoDimensions.feature | 10 +- .../ChangePropertyValue_Dimensions.feature | 60 ++++++------ .../ChangePropertyValue_NoDimensions.feature | 38 ++++---- .../Filter_NodeName_NoDimensions.feature | 16 ++-- ...lter_PropertyNotEmpty_NoDimensions.feature | 20 ++-- .../Filter_PropertyValue_NoDimensions.feature | 20 ++-- .../Migration/MoveDimensionSpacePoint.feature | 20 ++-- .../NodeTypeAdjustment_Dimensions.feature | 14 +-- .../NodeTypeAdjustment_NoDimensions.feature | 8 +- .../Migration/RemoveNodes_Dimensions.feature | 96 +++++++++---------- .../RemoveProperty_NoDimensions.feature | 14 +-- .../RenameNodeAggregate_Dimensions.feature | 8 +- .../RenameProperty_NoDimensions.feature | 8 +- .../StripTagsOnProperty_NoDimensions.feature | 8 +- .../src/NodeMigrationService.php | 4 +- .../Features/Bootstrap/MigrationsTrait.php | 14 ++- .../Features/Bootstrap/ProjectedNodeTrait.php | 13 +++ 18 files changed, 214 insertions(+), 193 deletions(-) diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature index 82179de44aa..bc8818e6b3e 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature @@ -60,7 +60,7 @@ Feature: Add Dimension Specialization Given I change the content dimensions in content repository "default" to: | Identifier | Values | Generalizations | | language | mul, de, ch | ch->de->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -74,7 +74,7 @@ Feature: Add Dimension Specialization # the original content stream has not been touched When I am in the active content stream of workspace "live" And I am in dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" And I expect this node to have the following properties: | Key | Value | @@ -84,14 +84,14 @@ Feature: Add Dimension Specialization # now, we find the node underneath both DimensionSpacePoints - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "hello" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} # shine through added - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" And I expect this node to have the following properties: | Key | Value | @@ -104,28 +104,28 @@ Feature: Add Dimension Specialization # finally, we MODIFY the node and ensure that the modification is visible in both DSPs (as otherwise the shine through would not have worked # as expected) # migration-cs is the actual name of the temporary workspace - And I am in workspace "migration-cs" + And I am in workspace "migration-workspace" And the command SetNodeProperties is executed with payload: | Key | Value | | nodeAggregateId | "sir-david-nodenborough" | | originDimensionSpacePoint | {"language": "de"} | | propertyValues | {"text": "changed"} | And the graph projection is fully up to date - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "changed" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} # ch shines through to the DE node - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "changed" | # the original content stream was untouched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "hello" | @@ -148,7 +148,7 @@ Feature: Add Dimension Specialization When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" # we change the dimension configuration @@ -156,7 +156,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, ch | ch->de->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -169,17 +169,17 @@ Feature: Add Dimension Specialization """ # the original content stream has not been touched - When I am in content stream "cs-identifier" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" # The visibility edges were modified - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" When I run integrity violation detection diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature index dbc2feabb80..974241a4e1c 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature @@ -51,7 +51,7 @@ Feature: Add New Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -76,17 +76,17 @@ Feature: Add New Property """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - Then I expect node aggregate identifier "other" to lead to node migration-cs;other;{} + Then I get the node with id "other" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature index fa08b92f120..69b75490852 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature @@ -55,7 +55,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints Scenario: change materialized "de" node, should shine through in "ch", but not in "en" - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -80,39 +80,39 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in the active content stream of workspace "live" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node was changed inside the new content stream, but only in DE (and shined through to CH; not in EN) - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in content stream "migration-cs" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | @@ -126,7 +126,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | targetOrigin | {"language":"ch"} | And the graph projection is fully up to date - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -149,14 +149,14 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # the node was changed inside the new content stream, but only in DE - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "ch"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + Then I get the node with id "sir-david-nodenborough" # !!! CH is still unmodified And I expect this node to have the following properties: | Key | Value | @@ -172,7 +172,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | targetOrigin | {"language":"ch"} | And the graph projection is fully up to date - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -196,14 +196,14 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # the node was changed inside the new content stream in DE and EN - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "ch"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + Then I get the node with id "sir-david-nodenborough" # !!! CH is modified now And I expect this node to have the following properties: | Key | Value | @@ -211,7 +211,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints Scenario: matching only happens based on originDimensionSpacePoint, not on visibleDimensionSpacePoints - we try to change CH, but should not see any modification (includeSpecializations = FALSE - default) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -235,20 +235,20 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # neither DE or CH is modified - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | Scenario: matching only happens based on originDimensionSpacePoint, not on visibleDimensionSpacePoints - we try to change CH, but should not see any modification (includeSpecializations = TRUE) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -273,14 +273,14 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # neither DE or CH is modified - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature index adc3578091d..ba7b09ad80b 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature @@ -42,7 +42,7 @@ Feature: Change Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -60,20 +60,20 @@ Feature: Change Property """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node type was changed inside the new content stream - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | Scenario: Ignoring transformation if property does not exist on node - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -90,14 +90,14 @@ Feature: Change Property newSerializedValue: 'fixed value' """ # we did not change anything because notExisting does not exist - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | Scenario: replacement using default currentValuePlaceholder - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -113,14 +113,14 @@ Feature: Change Property property: 'text' newSerializedValue: 'bla {current}' """ - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "bla Original text" | Scenario: replacement using alternative currentValuePlaceholder - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -137,14 +137,14 @@ Feature: Change Property currentValuePlaceholder: '{otherPlaceholder}' newSerializedValue: 'bla {otherPlaceholder}' """ - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "bla Original text" | Scenario: using search/replace - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -161,14 +161,14 @@ Feature: Change Property search: 'Original' replace: 'alternative' """ - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "alternative text" | Scenario: using search/replace including placeholder (all options) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -186,8 +186,8 @@ Feature: Change Property search: 'Original' replace: 'alternative' """ - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "bla alternative text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature index fb942948dd2..ca76bb27cc7 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature @@ -64,7 +64,7 @@ Feature: Filter - Node Name Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -82,31 +82,31 @@ Feature: Filter - Node Name """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "na-name1" to lead to node cs-identifier;na-name1;{} + Then I get the node with id "na-name1" And I expect this node to have the following properties: | Key | Value | | text | "Original name1" | - Then I expect node aggregate identifier "na-name2" to lead to node cs-identifier;na-name2;{} + Then I get the node with id "na-name2" And I expect this node to have the following properties: | Key | Value | | text | "Original name2" | - Then I expect node aggregate identifier "na-without-name" to lead to node cs-identifier;na-without-name;{} + Then I get the node with id "na-without-name" And I expect this node to have the following properties: | Key | Value | | text | "no node name" | # we filter based on the node name - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "na-name1" to lead to node migration-cs;na-name1;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "na-name1" # only changed here And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - Then I expect node aggregate identifier "na-name2" to lead to node migration-cs;na-name2;{} + Then I get the node with id "na-name2" And I expect this node to have the following properties: | Key | Value | | text | "Original name2" | - Then I expect node aggregate identifier "na-without-name" to lead to node migration-cs;na-without-name;{} + Then I get the node with id "na-without-name" And I expect this node to have the following properties: | Key | Value | | text | "no node name" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature index 55d4c9c3a38..f4116a9d6b6 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature @@ -74,7 +74,7 @@ Feature: Filter - Property not empty Scenario: PropertyNotEmpty - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -92,34 +92,34 @@ Feature: Filter - Property not empty """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "na-name1" to lead to node cs-identifier;na-name1;{} + Then I get the node with id "na-name1" And I expect this node to have the following properties: | Key | Value | | text | "Original name1" | - Then I expect node aggregate identifier "na-name2" to lead to node cs-identifier;na-name2;{} + Then I get the node with id "na-name2" And I expect this node to have the following properties: | Key | Value | | text | "" | - Then I expect node aggregate identifier "na-null-value" to lead to node cs-identifier;na-null-value;{} + Then I get the node with id "na-null-value" And I expect this node to have no properties - Then I expect node aggregate identifier "na-no-text" to lead to node cs-identifier;na-no-text;{} + Then I get the node with id "na-no-text" And I expect this node to not have the property "text" # we filter based on the node name - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "na-name1" to lead to node migration-cs;na-name1;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "na-name1" # only changed here And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - Then I expect node aggregate identifier "na-name2" to lead to node migration-cs;na-name2;{} + Then I get the node with id "na-name2" And I expect this node to have the following properties: | Key | Value | | text | "" | - Then I expect node aggregate identifier "na-null-value" to lead to node migration-cs;na-null-value;{} + Then I get the node with id "na-null-value" And I expect this node to have no properties - Then I expect node aggregate identifier "na-no-text" to lead to node migration-cs;na-no-text;{} + Then I get the node with id "na-no-text" And I expect this node to not have the property "text" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature index 439bf2a8ef2..b2b565a7fa1 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature @@ -74,7 +74,7 @@ Feature: Filter - Property Value Scenario: PropertyValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -93,34 +93,34 @@ Feature: Filter - Property Value """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "na-name1" to lead to node cs-identifier;na-name1;{} + Then I get the node with id "na-name1" And I expect this node to have the following properties: | Key | Value | | text | "Original name1" | - Then I expect node aggregate identifier "na-name2" to lead to node cs-identifier;na-name2;{} + Then I get the node with id "na-name2" And I expect this node to have the following properties: | Key | Value | | text | "value2" | - Then I expect node aggregate identifier "na-null-value" to lead to node cs-identifier;na-null-value;{} + Then I get the node with id "na-null-value" And I expect this node to have no properties - Then I expect node aggregate identifier "na-no-text" to lead to node cs-identifier;na-no-text;{} + Then I get the node with id "na-no-text" And I expect this node to not have the property "text" # we filter based on the node name - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "na-name1" to lead to node migration-cs;na-name1;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "na-name1" # only changed here And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - Then I expect node aggregate identifier "na-name2" to lead to node migration-cs;na-name2;{} + Then I get the node with id "na-name2" And I expect this node to have the following properties: | Key | Value | | text | "value2" | - Then I expect node aggregate identifier "na-null-value" to lead to node migration-cs;na-null-value;{} + Then I get the node with id "na-null-value" And I expect this node to have no properties - Then I expect node aggregate identifier "na-no-text" to lead to node migration-cs;na-no-text;{} + Then I get the node with id "na-no-text" And I expect this node to not have the property "text" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature index 2ed1bd2e875..ad242f97e45 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature @@ -58,7 +58,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, de_DE | de_DE->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -71,15 +71,15 @@ Feature: Move dimension space point """ # the original content stream has not been touched When I am in content stream "cs-identifier" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # we find the node underneath the new DimensionSpacePoint, but not underneath the old. - When I am in content stream "migration-cs" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "de_DE"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de_DE"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de_DE"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" When I run integrity violation detection @@ -99,7 +99,7 @@ Feature: Move dimension space point When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" # we change the dimension configuration @@ -107,7 +107,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, de_DE | de_DE->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -123,14 +123,14 @@ Feature: Move dimension space point When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" # The visibility edges were modified - When I am in content stream "migration-cs" and dimension space point {"language": "de_DE"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de_DE"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de_DE"} + Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" When I run integrity violation detection diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature index 316e1e7c234..cfc7b2459ec 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature @@ -59,7 +59,7 @@ Feature: Adjust node types with a node migration 'Neos.ContentRepository.Testing:OtherDocument': [] """ # we should be able to rename the node type - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -76,18 +76,18 @@ Feature: Adjust node types with a node migration """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # ... also in the fallback dimension When I am in the active content stream of workspace "live" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # the node type was changed inside the new content stream - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" # ... also in the fallback dimension - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature index a84ac887c54..c9754df42ec 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature @@ -57,7 +57,7 @@ Feature: Adjust node types with a node migration 'Neos.ContentRepository.Testing:OtherDocument': [] """ # we should be able to rename the node type - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -74,10 +74,10 @@ Feature: Adjust node types with a node migration """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # the node type was changed inside the new content stream - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature index e341a6d6227..87459353e4d 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature @@ -53,7 +53,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a given dimension space point removes the node with all virtual specializations - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -73,30 +73,30 @@ Feature: Remove Nodes """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "gsw"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in de and gsw (virtual specialization) - When I am in content stream "migration-cs" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "gsw"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a given dimension space point removes the node without shine-throughs with strategy "allSpecializations" - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -119,23 +119,23 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "gsw"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in de and gsw, since it is a specialization - When I am in content stream "migration-cs" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "gsw"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors @@ -166,7 +166,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a virtual specialization (gsw) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -189,30 +189,30 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "gsw"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" - When I am in content stream "migration-cs" and dimension space point {"language": "gsw"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (gsw) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -230,30 +230,30 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "gsw"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in content stream "migration-cs" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + Then I get the node with id "sir-david-nodenborough" - When I am in content stream "migration-cs" and dimension space point {"language": "gsw"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (DE,gsw) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -276,29 +276,29 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "gsw"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in content stream "migration-cs" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "gsw"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (DE,gsw) - variant 2 - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -314,22 +314,22 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {"language": "de"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "gsw"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "de"} + Then I get the node with id "sir-david-nodenborough" When I am in the active content stream of workspace "live" and dimension space point {"language": "en"} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{"language": "en"} + Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in content stream "migration-cs" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "gsw"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in content stream "migration-cs" and dimension space point {"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I run integrity violation detection diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature index ad49623d765..12c788d3233 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature @@ -42,7 +42,7 @@ Feature: Remove Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -59,18 +59,18 @@ Feature: Remove Property """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node type was changed inside the new content stream - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have no properties Scenario: Ignoring transformation if property does not exist on node - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -86,8 +86,8 @@ Feature: Remove Property property: 'notExisting' """ # we did not change anything because notExisting does not exist - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature index 39def2747c3..3c122c4857f 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature @@ -54,7 +54,7 @@ Feature: Rename Node Aggregate Scenario: Rename Node Aggregate - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -79,13 +79,13 @@ Feature: Rename Node Aggregate Then I expect the node "sir-david-nodenborough" to have the name "foo" # the node was changed inside the new content stream, across all dimensions - When I am in content stream "migration-cs" and dimension space point {"language": "de"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect the node "sir-david-nodenborough" to have the name "other" - When I am in content stream "migration-cs" and dimension space point {"language": "ch"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} Then I expect the node "sir-david-nodenborough" to have the name "other" - When I am in content stream "migration-cs" and dimension space point {"language": "en"} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} Then I expect the node "sir-david-nodenborough" to have the name "other" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature index 043bad53aef..df0030b17df 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature @@ -55,7 +55,7 @@ Feature: Rename Property newText: type: string """ - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -73,14 +73,14 @@ Feature: Rename Property """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node type was changed inside the new content stream - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | newText | "Original text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature index 3a12db2ae47..6a72c684305 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature @@ -42,7 +42,7 @@ Feature: Strip Tags on Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: """yaml migration: - @@ -59,14 +59,14 @@ Feature: Strip Tags on Property """ # the original content stream has not been touched When I am in the active content stream of workspace "live" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node cs-identifier;sir-david-nodenborough;{} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original

text

" | # the node type was changed inside the new content stream - When I am in content stream "migration-cs" and dimension space point {} - Then I expect node aggregate identifier "sir-david-nodenborough" to lead to node migration-cs;sir-david-nodenborough;{} + When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | diff --git a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php index 4822357331c..69df2c84e3e 100644 --- a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php +++ b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php @@ -76,16 +76,16 @@ public function executeMigration(ExecuteMigration $command): void } } else { - $targetContentStreamId = ContentStreamId::create(); $this->contentRepository->handle( CreateWorkspace::create( $command->getTargetWorkspaceName(), $sourceWorkspace->workspaceName, WorkspaceTitle::fromString($command->getTargetWorkspaceName()->value), WorkspaceDescription::fromString(''), - $targetContentStreamId, + ContentStreamId::create(), ) )->block(); + $targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName()); $targetWorkspaceWasCreated = true; } foreach ($command->getMigrationConfiguration()->getMigration() as $migrationDescription) { diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php index a5998e1d2aa..08ec2afa823 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php @@ -33,7 +33,7 @@ trait MigrationsTrait /** * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName: */ - public function iRunTheFollowingNodeMigration(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string, bool $publishingOnSuccess = true): void + public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string, bool $publishingOnSuccess = true): void { $migrationConfiguration = new MigrationConfiguration(Yaml::parse($string->getRaw())); $command = new ExecuteMigration( @@ -48,12 +48,20 @@ public function iRunTheFollowingNodeMigration(string $sourceWorkspaceName, strin $nodeMigrationService->executeMigration($command); } + /** + * @When I run the following node migration for workspace :sourceWorkspaceName: + */ + public function iRunTheFollowingNodeMigration(string $sourceWorkspaceName, PyStringNode $string): void + { + $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, sprintf("migration-%s-%s", $sourceWorkspaceName, sha1($string->getRaw())), $string); + } + /** * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName, without publishing on success: */ public function iRunTheFollowingNodeMigrationWithoutPublishingOnSuccess(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string): void { - $this->iRunTheFollowingNodeMigration($sourceWorkspaceName, $targetWorkspaceName, $string, false); + $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $string, false); } /** @@ -62,7 +70,7 @@ public function iRunTheFollowingNodeMigrationWithoutPublishingOnSuccess(string $ public function iRunTheFollowingNodeMigrationAndExceptionsAreCaught(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string): void { try { - $this->iRunTheFollowingNodeMigration($sourceWorkspaceName, $targetWorkspaceName, $string); + $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $string); } catch (\Exception $exception) { $this->lastCommandException = $exception; } diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php index bee6d1ffec9..58cb6025035 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php @@ -72,6 +72,19 @@ public function iGetTheNodeAtPath(string $serializedNodePath): void }); } + /** + * @Then /^I get the node with id "([^"]*)"$/ + * @param string $id + * @throws \Exception + */ + public function iGetTheNodeWithId(string $id): void + { + $nodeAggregateId = NodeAggregateId::fromString($id); + $this->initializeCurrentNodeFromContentSubgraph(function (ContentSubgraphInterface $subgraph) use ($nodeAggregateId) { + return $subgraph->findNodeById($nodeAggregateId); + }); + } + /** * @Then /^I expect a node identified by (.*) to exist in the content graph$/ * @param string $serializedNodeDiscriminator From 9dc4d02e95604d4c902e7e8c9ed4f3e936e83557 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 21:59:48 +0200 Subject: [PATCH 05/12] TASK: Add behat test for "publishing on success" --- .../PublishingOnSuccess_NoDimensions.feature | 65 +++++++++++++++++++ .../Features/Bootstrap/MigrationsTrait.php | 10 +-- 2 files changed, 66 insertions(+), 9 deletions(-) create mode 100644 Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature new file mode 100644 index 00000000000..ce8837f390a --- /dev/null +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature @@ -0,0 +1,65 @@ +@contentrepository @adapters=DoctrineDBAL +Feature: Publishing on Success + + Background: + Given using no content dimensions + And using the following node types: + """yaml + 'Neos.ContentRepository:Root': + constraints: + nodeTypes: + 'Neos.ContentRepository.Testing:Document': true + 'Neos.ContentRepository.Testing:Document': + properties: + text: + type: string + """ + And using identifier "default", I define a content repository + And I am in content repository "default" + And the command CreateRootWorkspace is executed with payload: + | Key | Value | + | workspaceName | "live" | + | workspaceTitle | "Live" | + | workspaceDescription | "The live workspace" | + | newContentStreamId | "cs-identifier" | + And the graph projection is fully up to date + And I am in the active content stream of workspace "live" + And the command CreateRootNodeAggregateWithNode is executed with payload: + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | + And the graph projection is fully up to date + # Node /document + When the command CreateNodeAggregateWithNode is executed with payload: + | Key | Value | + | nodeAggregateId | "sir-david-nodenborough" | + | nodeTypeName | "Neos.ContentRepository.Testing:Document" | + | originDimensionSpacePoint | {} | + | parentNodeAggregateId | "lady-eleonode-rootford" | + | initialPropertyValues | {"text": "Original text"} | + And the graph projection is fully up to date + + + Scenario: Fixed newValue + When I run the following node migration for workspace "live", creating target workspace "migration-workspace", with publishing on success: + """yaml + migration: + - + filters: + - + type: 'NodeType' + settings: + nodeType: 'Neos.ContentRepository.Testing:Document' + transformations: + - + type: 'ChangePropertyValue' + settings: + property: 'text' + newSerializedValue: 'fixed value' + """ + + When I am in the active content stream of workspace "live" and dimension space point {} + Then I get the node with id "sir-david-nodenborough" + And I expect this node to have the following properties: + | Key | Value | + | text | "fixed value" | diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php index 08ec2afa823..f87d8a487fb 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php @@ -31,7 +31,7 @@ trait MigrationsTrait use CRTestSuiteRuntimeVariables; /** - * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName: + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName, with publishing on success: */ public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string, bool $publishingOnSuccess = true): void { @@ -48,14 +48,6 @@ public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceW $nodeMigrationService->executeMigration($command); } - /** - * @When I run the following node migration for workspace :sourceWorkspaceName: - */ - public function iRunTheFollowingNodeMigration(string $sourceWorkspaceName, PyStringNode $string): void - { - $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, sprintf("migration-%s-%s", $sourceWorkspaceName, sha1($string->getRaw())), $string); - } - /** * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName, without publishing on success: */ From 42804ae26605d0f63cef9915259dfba9b64fc142 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 22:04:47 +0200 Subject: [PATCH 06/12] TASK: Fix Formating --- .../AddDimensionShineThrough.feature | 6 +-- .../ChangePropertyValue_Dimensions.feature | 6 +-- .../ChangePropertyValue_NoDimensions.feature | 6 +-- .../Filter_NodeName_NoDimensions.feature | 6 +-- ...lter_PropertyNotEmpty_NoDimensions.feature | 6 +-- .../Filter_PropertyValue_NoDimensions.feature | 6 +-- .../NodeTypeAdjustment_Dimensions.feature | 26 ++++++------- .../NodeTypeAdjustment_NoDimensions.feature | 6 +-- .../Migration/RemoveNodes_Dimensions.feature | 6 +-- .../RemoveProperty_NoDimensions.feature | 6 +-- .../RenameNodeAggregate_Dimensions.feature | 38 +++++++++---------- .../RenameProperty_NoDimensions.feature | 28 +++++++------- .../StripTagsOnProperty_NoDimensions.feature | 28 +++++++------- 13 files changed, 87 insertions(+), 87 deletions(-) diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature index bc8818e6b3e..8989ed9a872 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature @@ -40,9 +40,9 @@ Feature: Add Dimension Specialization And the graph projection is fully up to date And I am in workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature index 69b75490852..71490c176aa 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature @@ -31,9 +31,9 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document (in "de") When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature index ba7b09ad80b..edc07ba8937 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature @@ -26,9 +26,9 @@ Feature: Change Property And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature index ca76bb27cc7..0ddbaa17dc9 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature @@ -26,9 +26,9 @@ Feature: Filter - Node Name And I am in the active content stream of workspace "live" And the graph projection is fully up to date And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /name1 When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature index f4116a9d6b6..18ca0625e8a 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature @@ -26,9 +26,9 @@ Feature: Filter - Property not empty And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /name1 (has text value set) When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature index b2b565a7fa1..718bdbcaa05 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature @@ -26,9 +26,9 @@ Feature: Filter - Property Value And I am in the active content stream of workspace "live" And the graph projection is fully up to date And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /name1 (has text value set) When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature index cfc7b2459ec..834dd38acb2 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature @@ -24,25 +24,25 @@ Feature: Adjust node types with a node migration # SETUP ######################## When the command CreateRootWorkspace is executed with payload: - | Key | Value | - | workspaceName | "live" | - | workspaceTitle | "Live" | - | workspaceDescription | "The live workspace" | - | newContentStreamId | "cs-identifier" | + | Key | Value | + | workspaceName | "live" | + | workspaceTitle | "Live" | + | workspaceDescription | "The live workspace" | + | newContentStreamId | "cs-identifier" | And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "sir-david-nodenborough" | - | nodeTypeName | "Neos.ContentRepository.Testing:Document" | - | originDimensionSpacePoint | {"language": "de"} | - | parentNodeAggregateId | "lady-eleonode-rootford" | + | Key | Value | + | nodeAggregateId | "sir-david-nodenborough" | + | nodeTypeName | "Neos.ContentRepository.Testing:Document" | + | originDimensionSpacePoint | {"language": "de"} | + | parentNodeAggregateId | "lady-eleonode-rootford" | And the graph projection is fully up to date ######################## diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature index c9754df42ec..9639d1cc32b 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature @@ -30,9 +30,9 @@ Feature: Adjust node types with a node migration And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature index 87459353e4d..411d6ed3f4d 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature @@ -29,9 +29,9 @@ Feature: Remove Nodes And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document (in "de") When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature index 12c788d3233..c203d92d6f2 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature @@ -26,9 +26,9 @@ Feature: Remove Property And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature index 3c122c4857f..31fdde05afe 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature @@ -21,35 +21,35 @@ Feature: Rename Node Aggregate And I am in content repository "default" And the command CreateRootWorkspace is executed with payload: - | Key | Value | - | workspaceName | "live" | - | workspaceTitle | "Live" | - | workspaceDescription | "The live workspace" | - | newContentStreamId | "cs-identifier" | + | Key | Value | + | workspaceName | "live" | + | workspaceTitle | "Live" | + | workspaceDescription | "The live workspace" | + | newContentStreamId | "cs-identifier" | And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document (in "de") When the command CreateNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "sir-david-nodenborough" | - | nodeTypeName | "Neos.ContentRepository.Testing:Document" | - | nodeName | "foo" | - | originDimensionSpacePoint | {"language": "de"} | - | parentNodeAggregateId | "lady-eleonode-rootford" | - | initialPropertyValues | {"text": "Original text"} | + | Key | Value | + | nodeAggregateId | "sir-david-nodenborough" | + | nodeTypeName | "Neos.ContentRepository.Testing:Document" | + | nodeName | "foo" | + | originDimensionSpacePoint | {"language": "de"} | + | parentNodeAggregateId | "lady-eleonode-rootford" | + | initialPropertyValues | {"text": "Original text"} | And the graph projection is fully up to date # Node /document (in "en") When the command CreateNodeVariant is executed with payload: - | Key | Value | - | nodeAggregateId | "sir-david-nodenborough" | - | sourceOrigin | {"language":"de"} | - | targetOrigin | {"language":"en"} | + | Key | Value | + | nodeAggregateId | "sir-david-nodenborough" | + | sourceOrigin | {"language":"de"} | + | targetOrigin | {"language":"en"} | And the graph projection is fully up to date diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature index df0030b17df..5ba1f2808fb 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature @@ -18,26 +18,26 @@ Feature: Rename Property And I am in content repository "default" And the command CreateRootWorkspace is executed with payload: - | Key | Value | - | workspaceName | "live" | - | workspaceTitle | "Live" | - | workspaceDescription | "The live workspace" | - | newContentStreamId | "cs-identifier" | + | Key | Value | + | workspaceName | "live" | + | workspaceTitle | "Live" | + | workspaceDescription | "The live workspace" | + | newContentStreamId | "cs-identifier" | And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "sir-david-nodenborough" | - | nodeTypeName | "Neos.ContentRepository.Testing:Document" | - | originDimensionSpacePoint | {} | - | parentNodeAggregateId | "lady-eleonode-rootford" | - | initialPropertyValues | {"text": "Original text"} | + | Key | Value | + | nodeAggregateId | "sir-david-nodenborough" | + | nodeTypeName | "Neos.ContentRepository.Testing:Document" | + | originDimensionSpacePoint | {} | + | parentNodeAggregateId | "lady-eleonode-rootford" | + | initialPropertyValues | {"text": "Original text"} | And the graph projection is fully up to date diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature index 6a72c684305..884623a92ea 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature @@ -18,26 +18,26 @@ Feature: Strip Tags on Property And I am in content repository "default" And the command CreateRootWorkspace is executed with payload: - | Key | Value | - | workspaceName | "live" | - | workspaceTitle | "Live" | - | workspaceDescription | "The live workspace" | - | newContentStreamId | "cs-identifier" | + | Key | Value | + | workspaceName | "live" | + | workspaceTitle | "Live" | + | workspaceDescription | "The live workspace" | + | newContentStreamId | "cs-identifier" | And the graph projection is fully up to date And I am in the active content stream of workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "lady-eleonode-rootford" | - | nodeTypeName | "Neos.ContentRepository:Root" | + | Key | Value | + | nodeAggregateId | "lady-eleonode-rootford" | + | nodeTypeName | "Neos.ContentRepository:Root" | And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: - | Key | Value | - | nodeAggregateId | "sir-david-nodenborough" | - | nodeTypeName | "Neos.ContentRepository.Testing:Document" | - | originDimensionSpacePoint | {} | - | parentNodeAggregateId | "lady-eleonode-rootford" | - | initialPropertyValues | {"text": "Original

text

"} | + | Key | Value | + | nodeAggregateId | "sir-david-nodenborough" | + | nodeTypeName | "Neos.ContentRepository.Testing:Document" | + | originDimensionSpacePoint | {} | + | parentNodeAggregateId | "lady-eleonode-rootford" | + | initialPropertyValues | {"text": "Original

text

"} | And the graph projection is fully up to date From 3b536c802ea3cb54c6ccb3b34934562ca4e3d8c2 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 22:18:31 +0200 Subject: [PATCH 07/12] TASK: Fix existing behat tests, to work with workspaces instead of contentstreams --- .../Behavior/Features/FrontendRouting/Dimensions.feature | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature b/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature index a4767ff311c..f851dbd5e2b 100644 --- a/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature +++ b/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature @@ -188,7 +188,7 @@ Feature: Routing functionality with multiple content dimensions en: '' """ - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-cs", without publishing on success: """yaml migration: - @@ -259,7 +259,7 @@ Feature: Routing functionality with multiple content dimensions en: '' """ And the node "carl-destinode" in content stream "cs-identifier" and dimension '{"market":"DE", "language":"at"}' should not resolve to an URL - When I run the following node migration for workspace "live", creating target workspace "migration-workspace": + When I run the following node migration for workspace "live", creating target workspace "migration-cs", without publishing on success: """yaml migration: - From 28c55148d6aea4f7713c8eaed61e38a5a52652af Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 22:24:15 +0200 Subject: [PATCH 08/12] TASK: Fix existing behat tests, to work with workspaces instead of contentstreams --- .../AddDimensionShineThrough.feature | 12 +++---- .../AddNewProperty_NoDimensions.feature | 2 +- .../ChangePropertyValue_Dimensions.feature | 22 ++++++------ .../ChangePropertyValue_NoDimensions.feature | 12 +++---- .../Filter_NodeName_NoDimensions.feature | 2 +- ...lter_PropertyNotEmpty_NoDimensions.feature | 2 +- .../Filter_PropertyValue_NoDimensions.feature | 2 +- .../Migration/MoveDimensionSpacePoint.feature | 6 ++-- .../NodeTypeAdjustment_Dimensions.feature | 4 +-- .../NodeTypeAdjustment_NoDimensions.feature | 2 +- .../PublishingOnSuccess_NoDimensions.feature | 4 +-- .../Migration/RemoveNodes_Dimensions.feature | 36 +++++++++---------- .../RemoveProperty_NoDimensions.feature | 4 +-- .../RenameNodeAggregate_Dimensions.feature | 6 ++-- .../RenameProperty_NoDimensions.feature | 2 +- .../StripTagsOnProperty_NoDimensions.feature | 2 +- 16 files changed, 60 insertions(+), 60 deletions(-) diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature index 6f7dd574d56..ad0d913e4c8 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature @@ -84,12 +84,12 @@ Feature: Add Dimension Specialization # now, we find the node underneath both DimensionSpacePoints - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "hello" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} # shine through added Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" @@ -111,12 +111,12 @@ Feature: Add Dimension Specialization | originDimensionSpacePoint | {"language": "de"} | | propertyValues | {"text": "changed"} | And the graph projection is fully up to date - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "changed" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} # ch shines through to the DE node Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: @@ -169,14 +169,14 @@ Feature: Add Dimension Specialization """ # the original content stream has not been touched - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" Then I get the node with id "sir-david-nodenborough" When VisibilityConstraints are set to "frontend" # The visibility edges were modified - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" Then I get the node with id "sir-david-nodenborough" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature index bdb1de11570..ddd655691ca 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature @@ -81,7 +81,7 @@ Feature: Add New Property | Key | Value | | text | "Original text" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature index 62ff59b6a8f..7a2a5fb03b0 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature @@ -99,19 +99,19 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # the node was changed inside the new content stream, but only in DE (and shined through to CH; not in EN) - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -149,13 +149,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # the node was changed inside the new content stream, but only in DE - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I get the node with id "sir-david-nodenborough" # !!! CH is still unmodified And I expect this node to have the following properties: @@ -196,13 +196,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # the node was changed inside the new content stream in DE and EN - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I get the node with id "sir-david-nodenborough" # !!! CH is modified now And I expect this node to have the following properties: @@ -235,13 +235,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # neither DE or CH is modified - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -273,13 +273,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints """ # neither DE or CH is modified - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature index 1d3cf4912b5..58adbf21454 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature @@ -66,7 +66,7 @@ Feature: Change Property | text | "Original text" | # the node type was changed inside the new content stream - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -90,7 +90,7 @@ Feature: Change Property newSerializedValue: 'fixed value' """ # we did not change anything because notExisting does not exist - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -113,7 +113,7 @@ Feature: Change Property property: 'text' newSerializedValue: 'bla {current}' """ - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -137,7 +137,7 @@ Feature: Change Property currentValuePlaceholder: '{otherPlaceholder}' newSerializedValue: 'bla {otherPlaceholder}' """ - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -161,7 +161,7 @@ Feature: Change Property search: 'Original' replace: 'alternative' """ - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | @@ -186,7 +186,7 @@ Feature: Change Property search: 'Original' replace: 'alternative' """ - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature index 7f831a5c36d..128f96c13d7 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature @@ -96,7 +96,7 @@ Feature: Filter - Node Name | text | "no node name" | # we filter based on the node name - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "na-name1" # only changed here And I expect this node to have the following properties: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature index eadb8e97493..a29255725d3 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature @@ -107,7 +107,7 @@ Feature: Filter - Property not empty And I expect this node to not have the property "text" # we filter based on the node name - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "na-name1" # only changed here And I expect this node to have the following properties: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature index 030ad38f252..23cc6432644 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature @@ -108,7 +108,7 @@ Feature: Filter - Property Value And I expect this node to not have the property "text" # we filter based on the node name - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "na-name1" # only changed here And I expect this node to have the following properties: diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature index 6ddadfb2874..b5900ef36de 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature @@ -76,9 +76,9 @@ Feature: Move dimension space point # we find the node underneath the new DimensionSpacePoint, but not underneath the old. - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de_DE"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de_DE"} Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:Document" @@ -127,7 +127,7 @@ Feature: Move dimension space point When VisibilityConstraints are set to "frontend" # The visibility edges were modified - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de_DE"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de_DE"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" Then I get the node with id "sir-david-nodenborough" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature index 534f174547e..75318032b9e 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature @@ -84,10 +84,10 @@ Feature: Adjust node types with a node migration And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # the node type was changed inside the new content stream - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" # ... also in the fallback dimension - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature index 2d4a29b09e0..aa1770080dc 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature @@ -78,6 +78,6 @@ Feature: Adjust node types with a node migration And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # the node type was changed inside the new content stream - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature index ce8837f390a..4466143f2ec 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature @@ -23,7 +23,7 @@ Feature: Publishing on Success | workspaceDescription | "The live workspace" | | newContentStreamId | "cs-identifier" | And the graph projection is fully up to date - And I am in the active content stream of workspace "live" + And I am in workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: | Key | Value | | nodeAggregateId | "lady-eleonode-rootford" | @@ -58,7 +58,7 @@ Feature: Publishing on Success newSerializedValue: 'fixed value' """ - When I am in the active content stream of workspace "live" and dimension space point {} + When I am in workspace "live" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature index 535efa97561..a42cac0d65e 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature @@ -82,13 +82,13 @@ Feature: Remove Nodes Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in de and gsw (virtual specialization) - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} + When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection @@ -128,13 +128,13 @@ Feature: Remove Nodes Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in de and gsw, since it is a specialization - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} + When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection @@ -198,13 +198,13 @@ Feature: Remove Nodes Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} + When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection @@ -239,13 +239,13 @@ Feature: Remove Nodes Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I get the node with id "sir-david-nodenborough" - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} + When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I get the node with id "sir-david-nodenborough" When I run integrity violation detection @@ -285,13 +285,13 @@ Feature: Remove Nodes Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} + When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I run integrity violation detection @@ -323,13 +323,13 @@ Feature: Remove Nodes Then I get the node with id "sir-david-nodenborough" # the node was removed inside the new content stream, but only in gsw - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "gsw"} + When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I run integrity violation detection diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature index 2360af225b5..20cc555d28c 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature @@ -65,7 +65,7 @@ Feature: Remove Property | text | "Original text" | # the node type was changed inside the new content stream - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have no properties @@ -86,7 +86,7 @@ Feature: Remove Property property: 'notExisting' """ # we did not change anything because notExisting does not exist - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature index 92fabc5c2be..d8415ad7278 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature @@ -79,13 +79,13 @@ Feature: Rename Node Aggregate Then I expect the node "sir-david-nodenborough" to have the name "foo" # the node was changed inside the new content stream, across all dimensions - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "de"} + When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect the node "sir-david-nodenborough" to have the name "other" - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "ch"} + When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I expect the node "sir-david-nodenborough" to have the name "other" - When I am in the active content stream of workspace "migration-workspace" and dimension space point {"language": "en"} + When I am in workspace "migration-workspace" and dimension space point {"language": "en"} Then I expect the node "sir-david-nodenborough" to have the name "other" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature index c7c641bc45a..9f27fa9db7b 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature @@ -79,7 +79,7 @@ Feature: Rename Property | text | "Original text" | # the node type was changed inside the new content stream - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature index 28270afd619..60d98f8ac3f 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature @@ -65,7 +65,7 @@ Feature: Strip Tags on Property | text | "Original

text

" | # the node type was changed inside the new content stream - When I am in the active content stream of workspace "migration-workspace" and dimension space point {} + When I am in workspace "migration-workspace" and dimension space point {} Then I get the node with id "sir-david-nodenborough" And I expect this node to have the following properties: | Key | Value | From e1243cc495ffed6950e528f7fef766d36e42bb59 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 22:29:48 +0200 Subject: [PATCH 09/12] TASK: Check for existence of target workspace --- .../src/NodeMigrationService.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php index 274a912e1b1..dce023d4071 100644 --- a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php +++ b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php @@ -88,6 +88,11 @@ public function executeMigration(ExecuteMigration $command): void $targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName()); $targetWorkspaceWasCreated = true; } + + if($targetWorkspace === null) { + throw new MigrationException(sprintf('Target workspace "%s" could not loaded nor created.', $targetWorkspace->workspaceName->value)); + } + foreach ($command->getMigrationConfiguration()->getMigration() as $migrationDescription) { /** array $migrationDescription */ $this->executeSubMigrationAndBlock( From fcf7afb25a70d211ee8055c17370b74f511a831c Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Sun, 12 May 2024 22:40:46 +0200 Subject: [PATCH 10/12] TASK: Check for existence of target workspace --- .../src/NodeMigrationService.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php index dce023d4071..b12e2126b12 100644 --- a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php +++ b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php @@ -90,7 +90,7 @@ public function executeMigration(ExecuteMigration $command): void } if($targetWorkspace === null) { - throw new MigrationException(sprintf('Target workspace "%s" could not loaded nor created.', $targetWorkspace->workspaceName->value)); + throw new MigrationException(sprintf('Target workspace "%s" could not loaded nor created.', $command->getTargetWorkspaceName()->value)); } foreach ($command->getMigrationConfiguration()->getMigration() as $migrationDescription) { From 45a9b31658814a7f06c79651d1eed45e08af7699 Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Tue, 4 Jun 2024 00:14:28 +0200 Subject: [PATCH 11/12] FEATURE: Allow to provide contentStreamId from outside --- .../AddDimensionShineThrough.feature | 30 ++++----- .../AddNewProperty_NoDimensions.feature | 8 +-- .../ChangePropertyValue_Dimensions.feature | 38 ++++++------ .../ChangePropertyValue_NoDimensions.feature | 26 ++++---- .../Filter_NodeName_NoDimensions.feature | 14 ++--- ...lter_PropertyNotEmpty_NoDimensions.feature | 18 +++--- .../Filter_PropertyValue_NoDimensions.feature | 18 +++--- .../Migration/MoveDimensionSpacePoint.feature | 18 +++--- .../NodeTypeAdjustment_Dimensions.feature | 10 +-- .../NodeTypeAdjustment_NoDimensions.feature | 6 +- .../PublishingOnSuccess_NoDimensions.feature | 7 +-- .../Migration/RemoveNodes_Dimensions.feature | 62 +++++++++---------- .../RemoveProperty_NoDimensions.feature | 10 +-- .../RenameNodeAggregate_Dimensions.feature | 4 +- .../RenameProperty_NoDimensions.feature | 6 +- .../StripTagsOnProperty_NoDimensions.feature | 6 +- .../src/Command/ExecuteMigration.php | 30 ++------- .../src/NodeMigrationService.php | 24 +++---- .../Features/Bootstrap/MigrationsTrait.php | 19 +++--- .../Features/Bootstrap/ProjectedNodeTrait.php | 14 ----- .../NodeMigrationCommandController.php | 4 +- .../FrontendRouting/Dimensions.feature | 4 +- 22 files changed, 172 insertions(+), 204 deletions(-) diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature index 20562e501e0..3a1b492d362 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddDimensionShineThrough.feature @@ -57,7 +57,7 @@ Feature: Add Dimension Specialization Given I change the content dimensions in content repository "default" to: | Identifier | Values | Generalizations | | language | mul, de, ch | ch->de->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -71,7 +71,7 @@ Feature: Add Dimension Specialization # the original content stream has not been touched When I am in workspace "live" And I am in dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language":"de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" And I expect this node to have the following properties: | Key | Value | @@ -82,13 +82,13 @@ Feature: Add Dimension Specialization # now, we find the node underneath both DimensionSpacePoints When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language":"de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "hello" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} # shine through added - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language":"de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" And I expect this node to have the following properties: | Key | Value | @@ -108,20 +108,20 @@ Feature: Add Dimension Specialization | originDimensionSpacePoint | {"language": "de"} | | propertyValues | {"text": "changed"} | When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language":"de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "changed" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} # ch shines through to the DE node - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language":"de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "changed" | # the original content stream was untouched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language":"de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "hello" | @@ -143,7 +143,7 @@ Feature: Add Dimension Specialization When I am in workspace "live" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language":"de"} to exist in the content graph When VisibilityConstraints are set to "frontend" # we change the dimension configuration @@ -151,7 +151,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, ch | ch->de->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -167,14 +167,14 @@ Feature: Add Dimension Specialization When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language":"de"} to exist in the content graph When VisibilityConstraints are set to "frontend" # The visibility edges were modified When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language":"de"} to exist in the content graph When VisibilityConstraints are set to "frontend" When I run integrity violation detection @@ -194,7 +194,7 @@ Feature: Add Dimension Specialization | sourceOrigin | {"language":"de"} | | targetOrigin | {"language":"en"} | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - @@ -208,7 +208,7 @@ Feature: Add Dimension Specialization Then the last command should have thrown an exception of type "DimensionSpacePointAlreadyExists" Scenario: Error case - the target dimension is not configured - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - @@ -227,7 +227,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, foo | de->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - @@ -246,7 +246,7 @@ Feature: Add Dimension Specialization | Identifier | Values | Generalizations | | language | mul, de, foo | de->mul, foo->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature index 50ca33b3286..b17a6ef86b0 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/AddNewProperty_NoDimensions.feature @@ -47,7 +47,7 @@ Feature: Add New Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -72,17 +72,17 @@ Feature: Add New Property """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | - Then I get the node with id "other" + Then I expect a node identified by migration-cs;other;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature index 7f271fefc69..db052a12e43 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_Dimensions.feature @@ -51,7 +51,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints Scenario: change materialized "de" node, should shine through in "ch", but not in "en" - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -76,19 +76,19 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in workspace "live" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | @@ -96,19 +96,19 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # the node was changed inside the new content stream, but only in DE (and shined through to CH; not in EN) When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | When I am in workspace "migration-workspace" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "en"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | @@ -121,7 +121,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | sourceOrigin | {"language":"de"} | | targetOrigin | {"language":"ch"} | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -145,13 +145,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # the node was changed inside the new content stream, but only in DE When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "ch"} to exist in the content graph # !!! CH is still unmodified And I expect this node to have the following properties: | Key | Value | @@ -166,7 +166,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints | sourceOrigin | {"language":"de"} | | targetOrigin | {"language":"ch"} | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -191,13 +191,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # the node was changed inside the new content stream in DE and EN When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph # !!! CH is modified now And I expect this node to have the following properties: | Key | Value | @@ -205,7 +205,7 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints Scenario: matching only happens based on originDimensionSpacePoint, not on visibleDimensionSpacePoints - we try to change CH, but should not see any modification (includeSpecializations = FALSE - default) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -230,19 +230,19 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # neither DE or CH is modified When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | Scenario: matching only happens based on originDimensionSpacePoint, not on visibleDimensionSpacePoints - we try to change CH, but should not see any modification (includeSpecializations = TRUE) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -268,13 +268,13 @@ Feature: Change Property Value across dimensions; and test DimensionSpacePoints # neither DE or CH is modified When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature index 0bc83db77f9..841d8aeb2cd 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/ChangePropertyValue_NoDimensions.feature @@ -39,7 +39,7 @@ Feature: Change Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -57,20 +57,20 @@ Feature: Change Property """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node type was changed inside the new content stream When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | Scenario: Ignoring transformation if property does not exist on node - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -88,13 +88,13 @@ Feature: Change Property """ # we did not change anything because notExisting does not exist When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | Scenario: replacement using default currentValuePlaceholder - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -111,13 +111,13 @@ Feature: Change Property newSerializedValue: 'bla {current}' """ When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "bla Original text" | Scenario: replacement using alternative currentValuePlaceholder - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -135,13 +135,13 @@ Feature: Change Property newSerializedValue: 'bla {otherPlaceholder}' """ When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "bla Original text" | Scenario: using search/replace - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -159,13 +159,13 @@ Feature: Change Property replace: 'alternative' """ When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "alternative text" | Scenario: using search/replace including placeholder (all options) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -184,7 +184,7 @@ Feature: Change Property replace: 'alternative' """ When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "bla alternative text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature index 2816f849092..541e7536d75 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_NodeName_NoDimensions.feature @@ -59,7 +59,7 @@ Feature: Filter - Node Name Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -77,31 +77,31 @@ Feature: Filter - Node Name """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "na-name1" + Then I expect a node identified by cs-identifier;na-name1;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original name1" | - Then I get the node with id "na-name2" + Then I expect a node identified by cs-identifier;na-name2;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original name2" | - Then I get the node with id "na-without-name" + Then I expect a node identified by cs-identifier;na-without-name;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "no node name" | # we filter based on the node name When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "na-name1" + Then I expect a node identified by migration-cs;na-name1;{} to exist in the content graph # only changed here And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - Then I get the node with id "na-name2" + Then I expect a node identified by migration-cs;na-name2;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original name2" | - Then I get the node with id "na-without-name" + Then I expect a node identified by migration-cs;na-without-name;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "no node name" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature index 6e05126ac41..af0abbb43bc 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyNotEmpty_NoDimensions.feature @@ -68,7 +68,7 @@ Feature: Filter - Property not empty Scenario: PropertyNotEmpty - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -86,34 +86,34 @@ Feature: Filter - Property not empty """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "na-name1" + Then I expect a node identified by cs-identifier;na-name1;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original name1" | - Then I get the node with id "na-name2" + Then I expect a node identified by cs-identifier;na-name2;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "" | - Then I get the node with id "na-null-value" + Then I expect a node identified by cs-identifier;na-null-value;{} to exist in the content graph And I expect this node to have no properties - Then I get the node with id "na-no-text" + Then I expect a node identified by cs-identifier;na-no-text;{} to exist in the content graph And I expect this node to not have the property "text" # we filter based on the node name When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "na-name1" + Then I expect a node identified by migration-cs;na-name1;{} to exist in the content graph # only changed here And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - Then I get the node with id "na-name2" + Then I expect a node identified by migration-cs;na-name2;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "" | - Then I get the node with id "na-null-value" + Then I expect a node identified by migration-cs;na-null-value;{} to exist in the content graph And I expect this node to have no properties - Then I get the node with id "na-no-text" + Then I expect a node identified by migration-cs;na-no-text;{} to exist in the content graph And I expect this node to not have the property "text" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature index 93ba46a53d8..565637cc62c 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/Filter_PropertyValue_NoDimensions.feature @@ -68,7 +68,7 @@ Feature: Filter - Property Value Scenario: PropertyValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -87,34 +87,34 @@ Feature: Filter - Property Value """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "na-name1" + Then I expect a node identified by cs-identifier;na-name1;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original name1" | - Then I get the node with id "na-name2" + Then I expect a node identified by cs-identifier;na-name2;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "value2" | - Then I get the node with id "na-null-value" + Then I expect a node identified by cs-identifier;na-null-value;{} to exist in the content graph And I expect this node to have no properties - Then I get the node with id "na-no-text" + Then I expect a node identified by cs-identifier;na-no-text;{} to exist in the content graph And I expect this node to not have the property "text" # we filter based on the node name When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "na-name1" + Then I expect a node identified by migration-cs;na-name1;{} to exist in the content graph # only changed here And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | - Then I get the node with id "na-name2" + Then I expect a node identified by migration-cs;na-name2;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "value2" | - Then I get the node with id "na-null-value" + Then I expect a node identified by migration-cs;na-null-value;{} to exist in the content graph And I expect this node to have no properties - Then I get the node with id "na-no-text" + Then I expect a node identified by migration-cs;na-no-text;{} to exist in the content graph And I expect this node to not have the property "text" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature index c13afa6446a..90bf3b31b01 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/MoveDimensionSpacePoint.feature @@ -55,7 +55,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, de_DE | de_DE->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -68,7 +68,7 @@ Feature: Move dimension space point """ # the original content stream has not been touched When I am in content stream "cs-identifier" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" @@ -76,7 +76,7 @@ Feature: Move dimension space point When I am in workspace "migration-workspace" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I am in workspace "migration-workspace" and dimension space point {"language": "de_DE"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de_DE"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" When I run integrity violation detection @@ -95,7 +95,7 @@ Feature: Move dimension space point When I am in workspace "live" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When VisibilityConstraints are set to "frontend" # we change the dimension configuration @@ -103,7 +103,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, de_DE | de_DE->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -119,14 +119,14 @@ Feature: Move dimension space point When I am in workspace "live" and dimension space point {"language": "de"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When VisibilityConstraints are set to "frontend" # The visibility edges were modified When I am in workspace "migration-workspace" and dimension space point {"language": "de_DE"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When VisibilityConstraints are set to "withoutRestrictions" - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de_DE"} to exist in the content graph When VisibilityConstraints are set to "frontend" When I run integrity violation detection @@ -138,7 +138,7 @@ Feature: Move dimension space point | Identifier | Values | Generalizations | | language | mul, ch | ch->mul | - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - @@ -152,7 +152,7 @@ Feature: Move dimension space point Then the last command should have thrown an exception of type "DimensionSpacePointAlreadyExists" Scenario: Error case - the target dimension is not configured - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature index ad23af1b2e7..8b1992b26ba 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_Dimensions.feature @@ -56,7 +56,7 @@ Feature: Adjust node types with a node migration 'Neos.ContentRepository.Testing:OtherDocument': [] """ # we should be able to rename the node type - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -73,18 +73,18 @@ Feature: Adjust node types with a node migration """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # ... also in the fallback dimension When I am in workspace "live" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # the node type was changed inside the new content stream When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" # ... also in the fallback dimension When I am in workspace "migration-workspace" and dimension space point {"language": "ch"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature index 4e6d4ce2322..e3e8696ddf0 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/NodeTypeAdjustment_NoDimensions.feature @@ -54,7 +54,7 @@ Feature: Adjust node types with a node migration 'Neos.ContentRepository.Testing:OtherDocument': [] """ # we should be able to rename the node type - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -71,10 +71,10 @@ Feature: Adjust node types with a node migration """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:Document" # the node type was changed inside the new content stream When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to be of type "Neos.ContentRepository.Testing:OtherDocument" diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature index 4466143f2ec..813741197ec 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/PublishingOnSuccess_NoDimensions.feature @@ -22,13 +22,11 @@ Feature: Publishing on Success | workspaceTitle | "Live" | | workspaceDescription | "The live workspace" | | newContentStreamId | "cs-identifier" | - And the graph projection is fully up to date And I am in workspace "live" And the command CreateRootNodeAggregateWithNode is executed with payload: | Key | Value | | nodeAggregateId | "lady-eleonode-rootford" | | nodeTypeName | "Neos.ContentRepository:Root" | - And the graph projection is fully up to date # Node /document When the command CreateNodeAggregateWithNode is executed with payload: | Key | Value | @@ -37,11 +35,10 @@ Feature: Publishing on Success | originDimensionSpacePoint | {} | | parentNodeAggregateId | "lady-eleonode-rootford" | | initialPropertyValues | {"text": "Original text"} | - And the graph projection is fully up to date Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", with publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", with publishing on success: """yaml migration: - @@ -59,7 +56,7 @@ Feature: Publishing on Success """ When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "fixed value" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature index d88c836c7c4..f3e2bab3a14 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveNodes_Dimensions.feature @@ -49,7 +49,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a given dimension space point removes the node with all virtual specializations - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -69,13 +69,13 @@ Feature: Remove Nodes """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "gsw"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph # the node was removed inside the new content stream, but only in de and gsw (virtual specialization) When I am in workspace "migration-workspace" and dimension space point {"language": "de"} @@ -85,14 +85,14 @@ Feature: Remove Nodes Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I am in workspace "migration-workspace" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "en"} to exist in the content graph When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a given dimension space point removes the node without shine-throughs with strategy "allSpecializations" - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -115,13 +115,13 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "gsw"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph # the node was removed inside the new content stream, but only in de and gsw, since it is a specialization When I am in workspace "migration-workspace" and dimension space point {"language": "de"} @@ -131,14 +131,14 @@ Feature: Remove Nodes Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I am in workspace "migration-workspace" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "en"} to exist in the content graph When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: allVariants is not supported in RemoveNode, as this would violate the filter configuration potentially - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - @@ -162,7 +162,7 @@ Feature: Remove Nodes Scenario: Remove nodes in a virtual specialization (gsw) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -185,30 +185,30 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "gsw"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph # the node was removed inside the new content stream, but only in gsw When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I am in workspace "migration-workspace" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "en"} to exist in the content graph When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (gsw) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -226,30 +226,30 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "gsw"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph # the node was removed inside the new content stream, but only in gsw When I am in workspace "migration-workspace" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "migration-workspace" and dimension space point {"language": "gsw"} Then I expect node aggregate identifier "sir-david-nodenborough" to lead to no node When I am in workspace "migration-workspace" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{"language": "en"} to exist in the content graph When I run integrity violation detection Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (DE,gsw) - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -272,13 +272,13 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "gsw"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph # the node was removed inside the new content stream, but only in gsw When I am in workspace "migration-workspace" and dimension space point {"language": "de"} @@ -294,7 +294,7 @@ Feature: Remove Nodes Then I expect the integrity violation detection result to contain exactly 0 errors Scenario: Remove nodes in a shine-through dimension space point (DE,gsw) - variant 2 - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -310,13 +310,13 @@ Feature: Remove Nodes # the original content stream has not been touched When I am in workspace "live" and dimension space point {"language": "de"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "gsw"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "de"} to exist in the content graph When I am in workspace "live" and dimension space point {"language": "en"} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{"language": "en"} to exist in the content graph # the node was removed inside the new content stream, but only in gsw When I am in workspace "migration-workspace" and dimension space point {"language": "de"} diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature index 2f029450042..a2d81a9f503 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RemoveProperty_NoDimensions.feature @@ -39,7 +39,7 @@ Feature: Remove Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -56,18 +56,18 @@ Feature: Remove Property """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node type was changed inside the new content stream When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have no properties Scenario: Ignoring transformation if property does not exist on node - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -84,7 +84,7 @@ Feature: Remove Property """ # we did not change anything because notExisting does not exist When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature index c57fb022d66..32cfbd39cf5 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameNodeAggregate_Dimensions.feature @@ -50,7 +50,7 @@ Feature: Rename Node Aggregate Scenario: Rename Node Aggregate - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -86,7 +86,7 @@ Feature: Rename Node Aggregate Scenario: Rename Node Aggregate will fail when restricted to a single Dimension - When I run the following node migration for workspace "live", creating target workspace "migration-workspace" and exceptions are caught: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs" and exceptions are caught: """yaml migration: - diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature index 383d3e176b2..d382353d5ec 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/RenameProperty_NoDimensions.feature @@ -52,7 +52,7 @@ Feature: Rename Property newText: type: string """ - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -70,14 +70,14 @@ Feature: Rename Property """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | # the node type was changed inside the new content stream When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | newText | "Original text" | diff --git a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature index ce925b3c219..4584a2df214 100644 --- a/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature +++ b/Neos.ContentRepository.BehavioralTests/Tests/Behavior/Features/EventSourced/Migration/StripTagsOnProperty_NoDimensions.feature @@ -39,7 +39,7 @@ Feature: Strip Tags on Property Scenario: Fixed newValue - When I run the following node migration for workspace "live", creating target workspace "migration-workspace", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-workspace" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -56,14 +56,14 @@ Feature: Strip Tags on Property """ # the original content stream has not been touched When I am in workspace "live" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by cs-identifier;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original

text

" | # the node type was changed inside the new content stream When I am in workspace "migration-workspace" and dimension space point {} - Then I get the node with id "sir-david-nodenborough" + Then I expect a node identified by migration-cs;sir-david-nodenborough;{} to exist in the content graph And I expect this node to have the following properties: | Key | Value | | text | "Original text" | diff --git a/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php b/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php index 22e23dc01c6..cd4e43931ba 100644 --- a/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php +++ b/Neos.ContentRepository.NodeMigration/src/Command/ExecuteMigration.php @@ -14,6 +14,7 @@ namespace Neos\ContentRepository\NodeMigration\Command; +use Neos\ContentRepository\Core\SharedModel\Workspace\ContentStreamId; use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceName; /** @@ -22,30 +23,11 @@ final class ExecuteMigration { public function __construct( - private readonly MigrationConfiguration $migrationConfiguration, - private readonly WorkspaceName $sourceWorkspaceName, - private readonly WorkspaceName $targetWorkspaceName, - private readonly bool $publishOnSuccess, + public readonly MigrationConfiguration $migrationConfiguration, + public readonly WorkspaceName $sourceWorkspaceName, + public readonly WorkspaceName $targetWorkspaceName, + public readonly bool $publishOnSuccess, + public readonly ContentStreamId $contentStreamId, ) { } - - public function getMigrationConfiguration(): MigrationConfiguration - { - return $this->migrationConfiguration; - } - - public function getSourceWorkspaceName(): WorkspaceName - { - return $this->sourceWorkspaceName; - } - - public function getTargetWorkspaceName(): WorkspaceName - { - return $this->targetWorkspaceName; - } - - public function getPublishOnSuccess(): bool - { - return $this->publishOnSuccess; - } } diff --git a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php index 358cb9699b9..ba7279ce0c2 100644 --- a/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php +++ b/Neos.ContentRepository.NodeMigration/src/NodeMigrationService.php @@ -61,16 +61,16 @@ public function __construct( public function executeMigration(ExecuteMigration $command): void { - $sourceWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getSourceWorkspaceName()); + $sourceWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->sourceWorkspaceName); if ($sourceWorkspace === null) { throw new WorkspaceDoesNotExist(sprintf( 'The workspace %s does not exist', - $command->getSourceWorkspaceName()->value + $command->sourceWorkspaceName->value ), 1611688225); } $targetWorkspaceWasCreated = false; - if ($targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName())) { + if ($targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->targetWorkspaceName)) { if (!$this->workspaceIsEmpty($targetWorkspace)) { throw new MigrationException(sprintf('Target workspace "%s" already exists an is not empty. Please clear the workspace before.', $targetWorkspace->workspaceName->value)); } @@ -78,22 +78,22 @@ public function executeMigration(ExecuteMigration $command): void } else { $this->contentRepository->handle( CreateWorkspace::create( - $command->getTargetWorkspaceName(), + $command->targetWorkspaceName, $sourceWorkspace->workspaceName, - WorkspaceTitle::fromString($command->getTargetWorkspaceName()->value), + WorkspaceTitle::fromString($command->targetWorkspaceName->value), WorkspaceDescription::fromString(''), - ContentStreamId::create(), + $command->contentStreamId, ) ); - $targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->getTargetWorkspaceName()); + $targetWorkspace = $this->contentRepository->getWorkspaceFinder()->findOneByName($command->targetWorkspaceName); $targetWorkspaceWasCreated = true; } if($targetWorkspace === null) { - throw new MigrationException(sprintf('Target workspace "%s" could not loaded nor created.', $command->getTargetWorkspaceName()->value)); + throw new MigrationException(sprintf('Target workspace "%s" could not loaded nor created.', $command->targetWorkspaceName->value)); } - foreach ($command->getMigrationConfiguration()->getMigration() as $migrationDescription) { + foreach ($command->migrationConfiguration->getMigration() as $migrationDescription) { /** array $migrationDescription */ $this->executeSubMigrationAndBlock( $migrationDescription, @@ -102,14 +102,14 @@ public function executeMigration(ExecuteMigration $command): void ); } - if ($command->getPublishOnSuccess() === true) { + if ($command->publishOnSuccess === true) { $this->contentRepository->handle( - PublishWorkspace::create($command->getTargetWorkspaceName()) + PublishWorkspace::create($command->targetWorkspaceName) ); if ($targetWorkspaceWasCreated === true) { $this->contentRepository->handle( - DeleteWorkspace::create($command->getTargetWorkspaceName()) + DeleteWorkspace::create($command->targetWorkspaceName) ); } } diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php index f87d8a487fb..ac71554698b 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php @@ -31,16 +31,17 @@ trait MigrationsTrait use CRTestSuiteRuntimeVariables; /** - * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName, with publishing on success: + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName on contentStreamId :contentStreamId, with publishing on success: */ - public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string, bool $publishingOnSuccess = true): void + public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceWorkspaceName, string $targetWorkspaceName, string $contentStreamId, PyStringNode $string, bool $publishingOnSuccess = true): void { $migrationConfiguration = new MigrationConfiguration(Yaml::parse($string->getRaw())); $command = new ExecuteMigration( $migrationConfiguration, WorkspaceName::fromString($sourceWorkspaceName), WorkspaceName::fromString($targetWorkspaceName), - $publishingOnSuccess + $publishingOnSuccess, + ContentStreamId::fromString($contentStreamId) ); /** @var NodeMigrationService $nodeMigrationService */ @@ -49,20 +50,20 @@ public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceW } /** - * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName, without publishing on success: + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName on contentStreamId :contentStreamId, without publishing on success: */ - public function iRunTheFollowingNodeMigrationWithoutPublishingOnSuccess(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string): void + public function iRunTheFollowingNodeMigrationWithoutPublishingOnSuccess(string $sourceWorkspaceName, string $targetWorkspaceName, string $contentStreamId, PyStringNode $string): void { - $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $string, false); + $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $contentStreamId, $string,false); } /** - * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName and exceptions are caught: + * @When I run the following node migration for workspace :sourceWorkspaceName, creating target workspace :targetWorkspaceName on contentStreamId :contentStreamId and exceptions are caught: */ - public function iRunTheFollowingNodeMigrationAndExceptionsAreCaught(string $sourceWorkspaceName, string $targetWorkspaceName, PyStringNode $string): void + public function iRunTheFollowingNodeMigrationAndExceptionsAreCaught(string $sourceWorkspaceName, string $targetWorkspaceName, string $contentStreamId, PyStringNode $string): void { try { - $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $string); + $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $contentStreamId, $string); } catch (\Exception $exception) { $this->lastCommandException = $exception; } diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php index 32b745ec6a1..b227c5660b6 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/ProjectedNodeTrait.php @@ -19,7 +19,6 @@ use Neos\ContentRepository\Core\ContentGraphFinder; use Neos\ContentRepository\Core\Feature\SubtreeTagging\Dto\SubtreeTag; use Neos\ContentRepository\Core\NodeType\NodeTypeName; -use Neos\ContentRepository\Core\Projection\ContentGraph\ContentGraphInterface; use Neos\ContentRepository\Core\Projection\ContentGraph\ContentSubgraphInterface; use Neos\ContentRepository\Core\Projection\ContentGraph\Filter\FindBackReferencesFilter; use Neos\ContentRepository\Core\Projection\ContentGraph\Filter\FindChildNodesFilter; @@ -73,19 +72,6 @@ public function iGetTheNodeAtPath(string $serializedNodePath): void }); } - /** - * @Then /^I get the node with id "([^"]*)"$/ - * @param string $id - * @throws \Exception - */ - public function iGetTheNodeWithId(string $id): void - { - $nodeAggregateId = NodeAggregateId::fromString($id); - $this->initializeCurrentNodeFromContentSubgraph(function (ContentSubgraphInterface $subgraph) use ($nodeAggregateId) { - return $subgraph->findNodeById($nodeAggregateId); - }); - } - /** * @Then /^I expect a node identified by (.*) to exist in the content graph$/ * @param string $serializedNodeDiscriminator diff --git a/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php b/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php index aa7e6b2479c..4a76c8b4e87 100644 --- a/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php +++ b/Neos.ContentRepositoryRegistry/Classes/Command/NodeMigrationCommandController.php @@ -13,6 +13,7 @@ */ use Neos\ContentRepository\Core\SharedModel\ContentRepository\ContentRepositoryId; +use Neos\ContentRepository\Core\SharedModel\Workspace\ContentStreamId; use Neos\ContentRepository\Core\SharedModel\Workspace\WorkspaceName; use Neos\ContentRepository\NodeMigration\Command\ExecuteMigration; use Neos\ContentRepository\NodeMigration\Command\MigrationConfiguration; @@ -78,7 +79,8 @@ public function executeCommand(string $version, string $sourceWorkspace = 'live' $migrationConfiguration, $sourceWorkspaceName, $targetWorkspaceName, - $publishOnSuccess + $publishOnSuccess, + ContentStreamId::create() ) ); diff --git a/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature b/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature index 7aebd1d1387..f0e4169fe36 100644 --- a/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature +++ b/Neos.Neos/Tests/Behavior/Features/FrontendRouting/Dimensions.feature @@ -183,7 +183,7 @@ Feature: Routing functionality with multiple content dimensions en: '' """ - When I run the following node migration for workspace "live", creating target workspace "migration-cs", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-cs" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - @@ -252,7 +252,7 @@ Feature: Routing functionality with multiple content dimensions en: '' """ And the node "carl-destinode" in content stream "cs-identifier" and dimension '{"market":"DE", "language":"at"}' should not resolve to an URL - When I run the following node migration for workspace "live", creating target workspace "migration-cs", without publishing on success: + When I run the following node migration for workspace "live", creating target workspace "migration-cs" on contentStreamId "migration-cs", without publishing on success: """yaml migration: - From 2cb31783c05a1d261da0d84e9417a9bfafe32daf Mon Sep 17 00:00:00 2001 From: Denny Lubitz Date: Tue, 4 Jun 2024 00:27:32 +0200 Subject: [PATCH 12/12] FEATURE: Allow to provide contentStreamId from outside --- .../Classes/Behavior/Features/Bootstrap/MigrationsTrait.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php index ac71554698b..b02a8e2abed 100644 --- a/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php +++ b/Neos.ContentRepository.TestSuite/Classes/Behavior/Features/Bootstrap/MigrationsTrait.php @@ -54,7 +54,7 @@ public function iRunTheFollowingNodeMigrationWithTargetWorkspace(string $sourceW */ public function iRunTheFollowingNodeMigrationWithoutPublishingOnSuccess(string $sourceWorkspaceName, string $targetWorkspaceName, string $contentStreamId, PyStringNode $string): void { - $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $contentStreamId, $string,false); + $this->iRunTheFollowingNodeMigrationWithTargetWorkspace($sourceWorkspaceName, $targetWorkspaceName, $contentStreamId, $string, false); } /**