[OPIK-8023] Add page-boundary coverage for dataset-item JSON-key sorting - #7939
Open
thiagohora wants to merge 2 commits into
Open
[OPIK-8023] Add page-boundary coverage for dataset-item JSON-key sorting#7939thiagohora wants to merge 2 commits into
thiagohora wants to merge 2 commits into
Conversation
Follow-up to #7935. Extend the parameterized version-DAO sort test with a page=2,size=2 request per namespace/direction, asserting the single trailing item on the boundary page and that total stays at the full matching count. This exercises the push-top-limit OFFSET :top_offset + outer LIMIT path, previously covered only at page=1,size=10. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Contributor
⏱️ pre-commit per-hook timing
⏭️ 42 skipped (no matching files changed)
|
Collaborator
|
No test needed here. This PR is test-only: the whole diff is 9 added lines in DatasetVersionResourceTest.java asserting page 2 of a size-2 page over JSON-key sorting. No production code changes, so there is no new behaviour for an e2e test to cover — the assertion you added is itself the coverage for the top_offset/LIMIT path. Advisory, from the QA test radar. Nothing here blocks this PR, and anything it proposes is a draft for review. Re-checked after a push on 21 Aug 09:12 UTC — nothing the verdict depends on changed. |
Contributor
Backend Tests - Integration Group 12227 tests 226 ✅ 4m 3s ⏱️ Results for commit bc173cd. ♻️ This comment has been updated with latest results. |
…push-top-limit Per review: applyPushTopLimit requires hasAggregated && !hasRaw. Without materialized aggregates the query fell back to the raw path with an ordinary OFFSET, so the push-top-limit CTE (and its bound JSON key + top_offset) went untested. Populate experiment_item_aggregates via ExperimentAggregatesService before the sort/page-boundary assertions so the test deterministically exercises the push-top-limit branch. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
Details
Follow-up to #7935. Extends
DatasetVersionResourceTest#sortByJsonKeyThroughPushTopLimitwith apage=2, size=2request per namespace/direction, asserting the single trailing item on the boundary page and thattotalstays at the full matching count. This exercises the push-top-limitOFFSET :top_offset+ outerLIMITpath, which was previously covered only atpage=1, size=10.Change checklist
Issues
AI-WATERMARK
AI-WATERMARK: yes
Testing
mvn -o test -Dtest='DatasetVersionResourceTest$ExperimentDatasetVersionLinking#sortByJsonKeyThroughPushTopLimit'— 6/6 pass (output/input/metadata x ASC/DESC), each now also asserting page 2 (size 2) returns the single boundary item withtotal=3mvn -o spotless:check— cleanDocumentation
N/A — test-only change.
🤖 Generated with Claude Code