stable

Clone or download

Read-only

Handle reverse at artifact creation

part of story #24970 [modal] select type for links How to test: Enable the feature_flag with $ tuleap config-set feature_flag_allow_reverse_links 1 Example of payload: ``` { "tracker": { "id": 15 }, "values": [ { "field_id": 416, "all_links": [{"id": 29, "direction": "forward", "type" :""}, {"id": 30, "direction": "reverse", "type": "_is_child"}] } ] } ``` Note: Not tested code (ArtifactCreator) is tested in best effort with only happy path covered. Change-Id: I73f3007557a7be048d5e6986518118acab566f8d

Modified Files

Name
M plugins/agiledashboard/include/AgileDashboard/REST/v1/Kanban/KanbanItemsResource.php +86 −5 Go to diff View file
M plugins/testmanagement/include/TestManagement/REST/v1/CampaignCreator.class.php +8 −36 Go to diff View file
M plugins/testmanagement/include/TestManagement/REST/v1/CampaignsResource.class.php +51 −40 Go to diff View file
M plugins/testmanagement/include/TestManagement/REST/v1/ExecutionCreator.class.php +7 −31 Go to diff View file
M plugins/testmanagement/include/TestManagement/REST/v1/ExecutionsResource.class.php +60 −5 Go to diff View file
M plugins/testmanagement/tests/unit/TestManagement/CampaignCreatorTest.php +15 −31 Go to diff View file
M plugins/tracker/include/REST/Artifact/ArtifactCreator.class.php +71 −42 Go to diff View file
M plugins/tracker/include/REST/Artifact/ChangesetValue/ArtifactLink/NewArtifactLinkInitialChangesetValueBuilder.php +15 −0 Go to diff View file
A plugins/tracker/include/REST/Artifact/ChangesetValue/BuildFieldDataFromValuesByField.php +30 −0 Go to diff View file
A plugins/tracker/include/REST/Artifact/ChangesetValue/BuildFieldsData.php +45 −0 Go to diff View file
M plugins/tracker/include/REST/Artifact/ChangesetValue/FieldsDataBuilder.php +1 −4 Go to diff View file
M plugins/tracker/include/REST/Artifact/ChangesetValue/FieldsDataFromValuesByFieldBuilder.php +13 −5 Go to diff View file
M plugins/tracker/include/REST/v1/ArtifactsResource.class.php +59 −16 Go to diff View file
M plugins/tracker/include/Tracker/Artifact/ChangesetValue/ArtifactLink/NewArtifactLinkInitialChangesetValue.php +8 −1 Go to diff View file
M plugins/tracker/tests/rest/Artifacts/LinkedArtifactsTest.php +7 −0 Go to diff View file
A plugins/tracker/tests/unit/REST/Artifact/ArtifactCreatorTest.php +109 −0 Go to diff View file
M plugins/tracker/tests/unit/REST/Artifact/ChangesetValue/ArtifactLink/NewArtifactLinkInitialChangesetValueBuilderTest.php +12 −1 Go to diff View file
M plugins/tracker/tests/unit/REST/Artifact/ChangesetValue/FieldsDataFromValuesByFieldBuilderTest.php +9 −7 Go to diff View file
A plugins/tracker/tests/unit/Stub/BuildFieldDataFromValuesByFieldStub.php +64 −0 Go to diff View file
A plugins/tracker/tests/unit/Stub/BuildFieldsDataStub.php +71 −0 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Artifact/ChangesetValue/ArtifactLink/CollectionOfReverseLinksTest.php +1 −2 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Artifact/ChangesetValue/ArtifactLink/NewArtifactLinkInitialChangesetValueFormatterTest.php +6 −3 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Artifact/ChangesetValue/ArtifactLink/NewArtifactLinkInitialChangesetValueTest.php +8 −3 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Artifact/ChangesetValue/InitialChangesetValuesContainerTest.php +8 −2 Go to diff View file