Repository navigation
♻️ better testing of v2 products - #368
Merged
Merged
Conversation
ianardee
force-pushed
the
rework-product-tests
branch
from
November 25, 2026 17:17
3c1db50 to
c4d046f
Compare
There was a problem hiding this comment.
🟡 Changes recommended
The response summary renders Java object identifiers instead of recognized text because OcrPage lacks a toString() implementation, requiring page rendering and single-/multi-page output assertions.
1 open issue
What changed in this PR
This PR reorganizes the Java SDK’s v2 product tests, expands request-parameter coverage, and updates response text rendering.
Changes:
- Separate parameter tests from response tests and align test packages with each product.
- Verify required and optional request parameters, including a non-null extraction data schema.
- Delegate response rendering to inference objects and improve split and classification formatting.
| File | Description |
|---|---|
src/test/java/com/mindee/v2/product/split/SplitResponseTest.java |
Reorganizes response tests and adds display assertions. |
src/test/java/com/mindee/v2/product/split/SplitParametersTest.java |
Adds required and optional parameter tests. |
src/test/java/com/mindee/v2/product/split/SplitIT.java |
Aligns the integration-test package. |
src/test/java/com/mindee/v2/product/ocr/OcrResponseTest.java |
Aligns package, class name, and fixture loading. |
src/test/java/com/mindee/v2/product/ocr/OcrParametersTest.java |
Adds request-parameter tests. |
src/test/java/com/mindee/v2/product/extraction/RagDocumentsTest.java |
Clarifies document-ID usage and reorders setup. |
src/test/java/com/mindee/v2/product/extraction/ExtractionResponseTest.java |
Regroups tests and checks response-level rendering. |
src/test/java/com/mindee/v2/product/extraction/ExtractionParametersTest.java |
Expands parameter assertions and fixes schema test input. |
src/test/java/com/mindee/v2/product/crop/CropResponseTest.java |
Separates parameter coverage and checks response rendering. |
src/test/java/com/mindee/v2/product/crop/CropParametersTest.java |
Adds dedicated request-parameter tests. |
src/test/java/com/mindee/v2/product/crop/CropIT.java |
Aligns the integration-test package. |
src/test/java/com/mindee/v2/product/classification/ClassificationResponseTest.java |
Reorganizes response tests and adds display coverage. |
src/test/java/com/mindee/v2/product/classification/ClassificationParametersTest.java |
Adds dedicated request-parameter tests. |
src/main/java/com/mindee/v2/product/split/SplitResult.java |
Adds spacing between rendered splits. |
src/main/java/com/mindee/v2/product/split/SplitResponse.java |
Delegates rendering to the inference. |
src/main/java/com/mindee/v2/product/split/SplitRange.java |
Formats page ranges and document types. |
src/main/java/com/mindee/v2/product/ocr/OcrResponse.java |
Delegates rendering to the inference. |
src/main/java/com/mindee/v2/product/extraction/ExtractionResponse.java |
Delegates rendering to the inference. |
src/main/java/com/mindee/v2/product/crop/CropResponse.java |
Delegates rendering to the inference. |
src/main/java/com/mindee/v2/product/classification/ClassificationResponse.java |
Delegates rendering to the inference. |
src/main/java/com/mindee/v2/product/classification/ClassificationClassifier.java |
Uses reStructuredText field syntax. |
src/main/java/com/mindee/v2/clientoptions/BaseClassificationProductParameters.java |
Simplifies the class documentation wording. |
AGENTS.md |
Clarifies naming guidance for Java conversions. |
Review effort: Balanced
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.

Description
Types of changes