test: move TrackedEntitiesExportControllerTest to postgres DHIS2-18541 #19672
+520
−518
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
/tracker/trackedEntities/{uid}
and not/tracker/trackedEntities
(due to JSONB features not present in H2).orgUnitMode
inOperationParams
toACCESSIBLE
as this is the safest/least surprising/mostly what we want value.null
is not a valid value and makes theOperationParams
harder to use.Found Bug
The bug was actually fixed in PR #19647 but is now tested via the changes in this PR.
We only tested the
/tracker/trackedEntities/{uid}
using controller tests so far. Only now do these tests show this bug as we are now using the same code path for serving collections. That code path is extremely complicated 😢 (aggregate).Reason was
We used the wrong
param
to detect whether relationships should be set on the event.TrackedEntityParams
are another source of unnecessary complexity.Some day
TrackedEntitiesExportControllerTest
to use the json fixture instead of creating the setup using the managerTestBase
😬src/main
in the tracker module. Should we merge thetest-integration
andtest-web-api
modules? We need to investigate the pros/cons.