From d25cc86e06e5182f033a8a8f25a2df1fcae00deb Mon Sep 17 00:00:00 2001 From: David Mackessy Date: Tue, 31 Oct 2023 18:21:24 +0000 Subject: [PATCH] fix: Update test to use new program to keep existing tests passing [DHIS2-12345] --- .../resources/setup/tracker_metadata.json | 139 ++++++++++++++---- .../events/event-with-de-optionset.csv | 2 +- 2 files changed, 111 insertions(+), 30 deletions(-) diff --git a/dhis-2/dhis-test-e2e/src/test/resources/setup/tracker_metadata.json b/dhis-2/dhis-test-e2e/src/test/resources/setup/tracker_metadata.json index 15abff42774e..610506d7199e 100644 --- a/dhis-2/dhis-test-e2e/src/test/resources/setup/tracker_metadata.json +++ b/dhis-2/dhis-test-e2e/src/test/resources/setup/tracker_metadata.json @@ -608,7 +608,7 @@ "sharing": { "public": "rw------", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" @@ -622,6 +622,54 @@ } ] }, + { + "lastUpdated": "2019-02-28T12:42:58.281", + "id": "Td2rkv8FsW9", + "created": "2019-02-28T11:41:32.093", + "name": "TA Event_program2", + "code": "TA EVENT_PROGRAM2", + "shortName": "TAEP2", + "completeEventsExpiryDays": 0, + "ignoreOverdueEvents": false, + "skipOffline": false, + "minAttributesRequiredToSearch": 1, + "displayFrontPageList": false, + "onlyEnrollOnce": false, + "programType": "WITHOUT_REGISTRATION", + "accessLevel": "OPEN", + "version": 4, + "maxTeiCountToReturn": 0, + "selectIncidentDatesInFuture": false, + "displayIncidentDate": true, + "selectEnrollmentDatesInFuture": false, + "expiryDays": 0, + "useFirstStageDuringRegistration": false, + "programTrackedEntityAttributes": [], + "notificationTemplates": [], + "translations": [], + "organisationUnits": [ + { + "id": "DiszpKrYNg8", + "code": "OU_559" + } + ], + "sharing": { + "public": "rw------", + "external": false, + "userGroups": { + "OPVIvvXzNTw": { + "id": "OPVIvvXzNTw", + "access": "rwrw----" + } + } + }, + "programStages": [ + { + "id": "PKLB23QZS49", + "code": "TA_EVENT_PROGRAM_STAGE2" + } + ] + }, { "lastUpdated": "2019-02-28T12:42:58.283", "id": "f1AyMswryyX", @@ -675,7 +723,7 @@ "sharing": { "public": "rwrw----", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" @@ -1256,7 +1304,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:50:38.506", @@ -1292,7 +1340,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] } ], "translations": [], @@ -1406,7 +1454,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:50:38.505", @@ -1442,7 +1490,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:50:38.505", @@ -1478,7 +1526,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:50:38.505", @@ -1514,7 +1562,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:50:38.505", @@ -1550,7 +1598,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:50:38.506", @@ -1586,7 +1634,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] } ], "translations": [], @@ -1662,13 +1710,46 @@ "id": "inc5BJvr4W5", "code": "TA_COMMENT_DE" } - }, - { - "dataElement": { - "id": "vbZ5LGNfGET", - "code": "TA_DATE_AND_TIME_DE AGGREGATE" + } + ], + "translations": [], + "sharing": { + "public": "rw------", + "external": false, + "userGroups": { + "OPVIvvXzNTw": { + "id": "OPVIvvXzNTw", + "access": "rwrw----" } - }, + } + }, + "attributeValues": [], + "programStageSections": [] + }, + { + "lastUpdated": "2019-02-28T11:41:32.082", + "id": "PKLB23QZS49", + "created": "2019-02-28T11:41:32.082", + "name": "TA Event_program2", + "code": "TA_EVENT_PROGRAM_STAGE2", + "allowGenerateNextVisit": false, + "preGenerateUID": false, + "openAfterEnrollment": false, + "repeatable": false, + "remindCompleted": false, + "displayGenerateEventBox": true, + "generatedByEnrollmentDate": false, + "validationStrategy": "ON_COMPLETE", + "autoGenerateEvent": true, + "hideDueDate": false, + "blockEntryForm": false, + "minDaysFromStart": 0, + "program": { + "id": "Td2rkv8FsW9", + "code": "TA EVENT_PROGRAM2" + }, + "notificationTemplates": [], + "programStageDataElements": [ { "dataElement": { "id": "vbZ5LGNfGyy", @@ -1680,7 +1761,7 @@ "sharing": { "public": "rw------", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" @@ -1721,7 +1802,7 @@ "sharing": { "public": "rwrw----", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" @@ -2013,7 +2094,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-04-25T08:34:44.295", @@ -2047,7 +2128,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-04-25T08:34:44.295", @@ -2081,7 +2162,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-04-25T08:34:44.295", @@ -2115,7 +2196,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-04-25T08:34:44.296", @@ -2149,7 +2230,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-04-25T08:34:44.296", @@ -2183,7 +2264,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] } ], "translations": [] @@ -2238,7 +2319,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] }, { "lastUpdated": "2022-01-07T12:45:47.414", @@ -2262,7 +2343,7 @@ }, "favorites": [], "translations": [], - "attributeValues": [] + "attributeValues": [] } ], "attributeValues": [], @@ -3018,7 +3099,7 @@ "sharing": { "public": "rw------", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" @@ -3055,7 +3136,7 @@ "sharing": { "public": "rw------", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" @@ -3090,7 +3171,7 @@ "sharing": { "public": "rw------", "external": false, - "userGroups":{ + "userGroups": { "OPVIvvXzNTw": { "id": "OPVIvvXzNTw", "access": "rwrw----" diff --git a/dhis-2/dhis-test-e2e/src/test/resources/tracker/importer/events/event-with-de-optionset.csv b/dhis-2/dhis-test-e2e/src/test/resources/tracker/importer/events/event-with-de-optionset.csv index 5ddb50060319..e1e67b468a0d 100644 --- a/dhis-2/dhis-test-e2e/src/test/resources/tracker/importer/events/event-with-de-optionset.csv +++ b/dhis-2/dhis-test-e2e/src/test/resources/tracker/importer/events/event-with-de-optionset.csv @@ -1,2 +1,2 @@ event,status,program,programStage,enrollment,orgUnit,eventDate,dueDate,latitude,longitude,dataElement,value,storedBy,providedElsewhere,completedDate,completedBy,geometry -Dfger123k4e,,Zd2rkv8FsWq,jKLB23QZS4I,,g8upMTyEZGZ,2018-11-01T00:00:00.000,2058-11-01T00:00:00.000,,,vbZ5LGNfGyy,TA_YES,,true,,, +Dfger123k4e,,Td2rkv8FsW9,PKLB23QZS49,,DiszpKrYNg8,2018-11-01T00:00:00.000,2058-11-01T00:00:00.000,,,vbZ5LGNfGyy,TA_YES,,true,,,