Revise implementation of delta tasks (MAGNOLIA-5571)

[MAGNOLIA-5579] Add missing delta tasks Created: 30/Dec/13  Updated: 24/Jan/14  Resolved: 08/Jan/14

Status: Closed
Project: Magnolia
Component/s: core
Affects Version/s: 5.0
Fix Version/s: 5.2.2

Type: Sub-task Priority: Neutral
Reporter: Roman Kovařík Assignee: Roman Kovařík
Resolution: Fixed Votes: 0
Labels: usability
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Date of First Response:

 Description   

We have some useful task for operating with nodes but not with properties (or also opposite way), e.g.:

  • CopyPropertyTask
  • MovePropertyTask
  • RenamePropertyTask
  • RemovePropertiesTask
  • RenameNodeTask

are missing.



 Comments   
Comment by Roman Kovařík [ 08/Jan/14 ]
  • Check Copyright --> 2014
  • In CopyPropertyTask first constructor: Use the workspace passed in argument instead of the 'hard coded' one
  • In MovePropertyTask, CopyPropertyTask
    • I would also change the logic in the doExecute (check if the source props exist, check if the dest do not exist or can be override, and then do the operation)
      In MovePropertyTaskTest, CopyPropertyTaskTest (Add test)
    • Would be cool if you could add a test with override = false and a already existing props...
      In RenameNodeTaskTest, RenamePropertyTaskTest
    • Add tests (one with override = true, one with false, one with non existing source)

In MovePropertyTask, CopyPropertyTask

  • I would also change the logic in the doExecute (check if the source props exist, check if the dest do not exist or can be override, and then do the operation)

Shouldn't the task rather fail in case that property doesn't exist (And we should use PropertyExistsDelegateTask / NodeExistsDelegateTask) instead?

Generated at Mon Feb 12 04:06:28 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.