CMR-11364: fix shapefile test cleanup timing - #2476
Open
zimzoom wants to merge 1 commit into
Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2476 +/- ##
==========================================
- Coverage 57.93% 57.93% -0.01%
==========================================
Files 1073 1073
Lines 74658 74658
Branches 2177 2172 -5
==========================================
- Hits 43251 43250 -1
Misses 29379 29379
- Partials 2028 2029 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
jmaeng72
approved these changes
Aug 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Overview
What is the objective?
To fix intermittent system integration test failures while validating force-Cartesian shapefile search behavior. Specifically, the test
collection-shapefile-force-cartesian-validation-testintermittently received HTTP 400 when force-cartesian=true should have allowed the uploaded GeoJSON.What are the changes?
The test in question uses a Scotland file that is approximately 292 KB and contains approximately 3,000 coordinate points. Another test in the same system integration group, granule-shapefile-failure-cases, temporarily changes search-app’s process-wide shapefile limits to 50 KB maximum upload size, 50 maximum points, and 2 maximum features. The Scotland fixture exceeds both temporary size and point limits. This creates a shared-state hazard: if the temporary values leak from the granule failure test—or are observed by another test while active—the force-Cartesian request returns 400 before its intended geometry behavior can be tested.
Previously, those global settings were restored only at the end of the test body. An exception or unexpected exit before reaching the cleanup statements could leave the search application using the test-specific limits. The change wraps the temporary overrides in
try/finally, ensuring that all three settings are restored even when the test exits abnormally.Also, enhanced debugging was added.
What areas of the application does this impact?
system-int-test
Required Checklist
Additional Checklist