Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TASK: Remove explicit deprecated command blocking #5059

Merged
merged 4 commits into from
May 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@
"../../flow doctrine:migrate --quiet; ../../flow cr:setup",
"@test:behat-cli -c Neos.Neos/Tests/Behavior/behat.yml"
],
"test:behavioral:sync": [
"@putenv CATCHUPTRIGGER_ENABLE_SYNCHRONOUS_OPTION=1",
"@test:behavioral"
],
"test:behavioral:stop-on-failure": [
"@test:behat-cli -vvv --stop-on-failure -c Neos.ContentRepository.BehavioralTests/Tests/Behavior/behat.yml.dist",
"@test:behat-cli -vvv --stop-on-failure -c Neos.ContentGraph.DoctrineDbalAdapter/Tests/Behavior/behat.yml.dist",
Expand All @@ -58,10 +54,6 @@
"../../flow doctrine:migrate --quiet; ../../flow cr:setup",
"@test:behat-cli -vvv --stop-on-failure -c Neos.Neos/Tests/Behavior/behat.yml"
],
"test:behavioral:stop-on-failure:sync": [
"@putenv CATCHUPTRIGGER_ENABLE_SYNCHRONOUS_OPTION=1",
"@test:behavioral:stop-on-failure"
],
"test": [
"@test:unit",
"@test:functional",
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ jobs:
# DEBUG MODE: ALTERNATIVELY, comment in the following lines to dump the DB.
# do not exit the script if the tests break; as we want to upload the database dumps afterwards.
set +e
composer test:behavioral:stop-on-failure:sync
composer test:behavioral:stop-on-failure
retVal=$?
# automatically search for race conditions
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ public function __construct()
self::bootstrapFlow();
$this->contentRepositoryRegistry = $this->getObject(ContentRepositoryRegistry::class);

$this->setupCRTestSuiteTrait();
$this->setupDbalGraphAdapterIntegrityViolationTrait();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ Feature: Run integrity violation detection regarding hierarchy relations and nod
| 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 dimension space point {}
And the command CreateRootNodeAggregateWithNode is executed with payload:
| Key | Value |
Expand All @@ -35,7 +34,6 @@ Feature: Run integrity violation detection regarding hierarchy relations and nod
| parentNodeAggregateId | "lady-eleonode-rootford" |
| nodeName | "child-document" |
| nodeAggregateClassification | "regular" |
And the graph projection is fully up to date

Scenario: Detach a hierarchy relation from its parent
When I add the following hierarchy relation:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ Feature: Run integrity violation detection regarding parent relations
| 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 dimension space point {"language":"de"}
And the command CreateRootNodeAggregateWithNode is executed with payload:
| Key | Value |
Expand Down Expand Up @@ -55,7 +54,6 @@ Feature: Run integrity violation detection regarding parent relations
| parentNodeAggregateId | "sir-david-nodenborough" |
| nodeName | "child-document" |
| nodeAggregateClassification | "regular" |
And the graph projection is fully up to date

Scenario: Set a second parent for Nody McNodeface
And I add the following hierarchy relation:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ Feature: Run integrity violation detection regarding reference relations
| 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 dimension space point {"language":"de"}
And the command CreateRootNodeAggregateWithNode is executed with payload:
| Key | Value |
Expand All @@ -46,7 +45,6 @@ Feature: Run integrity violation detection regarding reference relations
| coveredDimensionSpacePoints | [{"language":"de"},{"language":"gsw"},{"language":"fr"}] |
| parentNodeAggregateId | "lady-eleonode-rootford" |
| nodeAggregateClassification | "regular" |
And the graph projection is fully up to date

Scenario: Detach a reference relation from its source
When the command SetNodeReferences is executed with payload:
Expand All @@ -55,7 +53,6 @@ Feature: Run integrity violation detection regarding reference relations
| sourceNodeAggregateId | "source-nodandaise" |
| referenceName | "referenceProperty" |
| references | [{"target": "anthony-destinode"}] |
And the graph projection is fully up to date
And I detach the following reference relation from its source:
| Key | Value |
| contentStreamId | "cs-identifier" |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,11 @@ Feature: Run integrity violation detection regarding sibling sorting
| 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 dimension space point {"language":"de"}
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

Scenario: Create two siblings and set the sorting to the same value
When the event NodeAggregateWithNodeWasCreated was published with payload:
Expand All @@ -46,7 +44,6 @@ Feature: Run integrity violation detection regarding sibling sorting
| coveredDimensionSpacePoints | [{"language":"de"},{"language":"gsw"},{"language":"fr"}] |
| parentNodeAggregateId | "lady-eleonode-rootford" |
| nodeAggregateClassification | "regular" |
And the graph projection is fully up to date
And I set the following position:
| Key | Value |
| contentStreamId | "cs-identifier" |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,11 @@ Feature: Run integrity violation detection regarding subtree tag inheritance
| 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 dimension space point {"language":"de"}
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

Scenario: Create nodes, disable the topmost and remove some restriction edges manually
When the event NodeAggregateWithNodeWasCreated was published with payload:
Expand Down Expand Up @@ -64,7 +62,6 @@ Feature: Run integrity violation detection regarding subtree tag inheritance
| nodeAggregateId | "sir-david-nodenborough" |
| affectedDimensionSpacePoints | [{"language":"de"},{"language":"gsw"},{"language":"fr"}] |
| tag | "disabled" |
And the graph projection is fully up to date
And I remove the following subtree tag:
| Key | Value |
| contentStreamId | "cs-identifier" |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ Feature: Run projection integrity violation detection regarding naming of tether
| 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 dimension space point {"language":"de"}
And the command CreateRootNodeAggregateWithNode is executed with payload:
| Key | Value |
Expand All @@ -35,7 +34,6 @@ Feature: Run projection integrity violation detection regarding naming of tether
| parentNodeAggregateId | "lady-eleonode-rootford" |
| nodeName | "document" |
| nodeAggregateClassification | "regular" |
And the graph projection is fully up to date

Scenario: Remove tethered node's name
When the event NodeAggregateWithNodeWasCreated was published with payload:
Expand All @@ -48,7 +46,6 @@ Feature: Run projection integrity violation detection regarding naming of tether
| parentNodeAggregateId | "sir-david-nodenborough" |
| nodeName | "to-be-hacked-to-null" |
| nodeAggregateClassification | "tethered" |
And the graph projection is fully up to date
And I change the following node's name:
| Key | Value |
| contentStreamId | "cs-identifier" |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ Feature: Sibling positions are properly resolved
| 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 dimension space point {"example": "general"}
And the command CreateRootNodeAggregateWithNode is executed with payload:
| Key | Value |
Expand Down Expand Up @@ -50,49 +49,41 @@ Feature: Sibling positions are properly resolved
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-ii" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance iii to x: 32
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-iii" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance iv to x: 16
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-iv" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance v to x: 8
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-v" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance vi to x: 4
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-vi" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance vii to x: 2
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-vii" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance viii to x: 1 -> reorder -> 128
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-viii" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date
# distance ix to x: 64 after reorder
And the command MoveNodeAggregate is executed with payload:
| Key | Value |
| nodeAggregateId | "lady-nodette-nodington-ix" |
| newSucceedingSiblingNodeAggregateId | "lady-nodette-nodington-x" |
And the graph projection is fully up to date

Then I expect node aggregate identifier "lady-eleonode-rootford" to lead to node cs-identifier;lady-eleonode-rootford;{}
And I expect this node to have the following child nodes:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

use Neos\ContentRepository\Core\SharedModel\ContentRepository\ContentRepositoryId;
use Neos\ContentRepositoryRegistry\ContentRepositoryRegistry;
use Neos\ContentRepositoryRegistry\Factory\ProjectionCatchUpTrigger\CatchUpTriggerWithSynchronousOption;
use Neos\Flow\Cli\CommandController;
use Neos\Neos\Fusion\Cache\GraphProjectorCatchUpHookForCacheFlushing;

Expand Down Expand Up @@ -47,10 +46,8 @@ public function preparePerformanceTestCommand(int $nodesPerLevel, int $levels):
{
$this->performanceMeasurementService->removeEverything();
$this->outputLine("All removed. Starting to fill.");
CatchUpTriggerWithSynchronousOption::synchronously(
fn() => GraphProjectorCatchUpHookForCacheFlushing::disabled(
fn() => $this->performanceMeasurementService->createNodesForPerformanceTest($nodesPerLevel, $levels)
)
GraphProjectorCatchUpHookForCacheFlushing::disabled(
fn() => $this->performanceMeasurementService->createNodesForPerformanceTest($nodesPerLevel, $levels)
);
}

Expand All @@ -62,9 +59,7 @@ public function preparePerformanceTestCommand(int $nodesPerLevel, int $levels):
public function testPerformanceCommand(): void
{
$time = microtime(true);
CatchUpTriggerWithSynchronousOption::synchronously(
fn() => $this->performanceMeasurementService->forkContentStream()
);
$this->performanceMeasurementService->forkContentStream();

$timeElapsed = microtime(true) - $time;
$this->outputLine('Time: ' . $timeElapsed);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

use Behat\Behat\Context\Context as BehatContext;
use Behat\Behat\Hook\Scope\BeforeScenarioScope;
use Doctrine\DBAL\Connection;
use GuzzleHttp\Psr7\Uri;
use Neos\Behat\FlowBootstrapTrait;
use Neos\ContentGraph\DoctrineDbalAdapter\Tests\Behavior\Features\Bootstrap\ProjectionIntegrityViolationDetectionTrait;
Expand Down Expand Up @@ -60,7 +61,6 @@ public function __construct()
self::bootstrapFlow();

$this->dbalClient = $this->getObject(DbalClientInterface::class);
$this->setupCRTestSuiteTrait();
$this->setUpInterleavingLogger();
$this->contentRepositoryRegistry = $this->getObject(ContentRepositoryRegistry::class);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,11 @@ Feature: Create a root node aggregate
| 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

Scenario: Try to create a root node aggregate in a workspace that currently does not exist:
When the command CreateRootNodeAggregateWithNode is executed with payload and exceptions are caught:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ Feature: Create a root node aggregate
| workspaceTitle | "Live" |
| workspaceDescription | "The live workspace" |
| newContentStreamId | "cs-identifier" |
And the graph projection is fully up to date
And I am in workspace "live"

Scenario: Create the initial root node aggregate using valid payload without dimensions
Expand All @@ -42,7 +41,6 @@ Feature: Create a root node aggregate
| coveredDimensionSpacePoints | [[]] |
| nodeAggregateClassification | "root" |

When the graph projection is fully up to date
Then I expect the node aggregate "lady-eleonode-rootford" to exist
And I expect this node aggregate to be classified as "root"
And I expect this node aggregate to be of type "Neos.ContentRepository:Root"
Expand Down Expand Up @@ -75,7 +73,6 @@ Feature: Create a root node aggregate
| Key | Value |
| nodeAggregateId | "lady-eleonode-rootford" |
| nodeTypeName | "Neos.ContentRepository:Root" |
And the graph projection is fully up to date

When the command CreateRootNodeAggregateWithNode is executed with payload:
| Key | Value |
Expand All @@ -91,7 +88,6 @@ Feature: Create a root node aggregate
| coveredDimensionSpacePoints | [[]] |
| nodeAggregateClassification | "root" |

When the graph projection is fully up to date
Then I expect the node aggregate "lady-eleonode-rootford" to exist
And I expect this node aggregate to have no parent node aggregates
And I expect this node aggregate to have no child node aggregates
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ Feature: Create a root node aggregate with tethered children
| 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 dimension space point {}
And I am user identified by "initiating-user-identifier"

Expand All @@ -47,7 +46,6 @@ Feature: Create a root node aggregate with tethered children
| nodeAggregateId | "lady-eleonode-rootford" |
| nodeTypeName | "Neos.ContentRepository.Testing:RootWithTetheredChildNodes" |
| tetheredDescendantNodeAggregateIds | {"child-node": "nody-mc-nodeface", "child-node/grandchild-node": "nodimus-prime"} |
And the graph projection is fully up to date

Then I expect exactly 4 events to be published on stream "ContentStream:cs-identifier"
And event at index 1 is of type "RootNodeAggregateWithNodeWasCreated" with payload:
Expand Down
Loading
Loading