Skip to content

Commit

Permalink
WIP: Fix SetSerializedNodeProperties event
Browse files Browse the repository at this point in the history
  • Loading branch information
mhsdesign committed Feb 14, 2024
1 parent f9fad15 commit d641f94
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ Feature: ForkContentStream Without Dimensions
| originDimensionSpacePoint | {} |
| affectedDimensionSpacePoints | [{}] |
| propertyValues | {"text": {"value": "original value", "type": "string"}} |
| propertiesToUnset | {} |

Scenario: Ensure that the node is available in the forked content stream
When the command "ForkContentStream" is executed with payload:
Expand All @@ -69,6 +70,7 @@ Feature: ForkContentStream Without Dimensions
| originDimensionSpacePoint | {} |
| affectedDimensionSpacePoints | [{}] |
| propertyValues | {"text": {"value": "modified value", "type": "string"}} |
| propertiesToUnset | {} |
And the graph projection is fully up to date

# live
Expand Down Expand Up @@ -98,6 +100,7 @@ Feature: ForkContentStream Without Dimensions
| originDimensionSpacePoint | {} |
| affectedDimensionSpacePoints | [{}] |
| propertyValues | {"text": {"value": "modified value", "type": "string"}} |
| propertiesToUnset | {} |
And the graph projection is fully up to date

# live
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ Feature: Properties
| originDimensionSpacePoint | {} |
| affectedDimensionSpacePoints | [{}] |
| propertyValues | {"myProp": {"value": "original value", "type": "My\\Non\\Existing\\Class"}} |
| propertiesToUnset | {} |
And the graph projection is fully up to date
Then I expect the following structure adjustments for type "Neos.ContentRepository.Testing:Document":
| Type | nodeAggregateId |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ Feature: Rebasing auto-created nodes works
| nodeAggregateId | $this->currentNodeAggregateId |
| originDimensionSpacePoint | {} |
| propertyValues | {"text": {"value":"Modified","type":"string"}} |
| propertiesToUnset | {} |
And the graph projection is fully up to date

When the command RebaseWorkspace is executed with payload:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
* Todo move to shared and use {@see PropertyName} ???
* @api used as part of commands/events
*/
final readonly class PropertyNames
final readonly class PropertyNames implements \JsonSerializable
{
/**
* @var array<string>
Expand Down Expand Up @@ -56,6 +56,11 @@ public function splitByScope(NodeType $nodeType): array

public function merge(self $other): self
{
return new self(...array_merge($this->values, $other->values));
return new self(...$this->values, ...$other->values);
}

public function jsonSerialize(): mixed
{
return $this->values;
}
}

0 comments on commit d641f94

Please sign in to comment.