Yicong-Huang opened a new pull request, #54084: URL: https://github.com/apache/spark/pull/54084
## What changes were proposed in this pull request? Extract common golden file testing utilities into `GoldenFileTestMixin` in `python/pyspark/testing/goldenutils.py`, and simplify the four type coercion test files to use this mixin. ### Golden file format changes: - **Return type tests**: Index column name changed from `Python Value \ SQL Type` to `Source Value \ Target Type` - **Input type tests**: Changed from 5-column row format to 2-column matrix format with `Spark Type` and `Python Type` columns - **Value representation**: Unified `repr_value()` format as `value@type` (e.g., `True@bool`, `[1, 2]@List[int]`) ## Why are the changes needed? Reduce ~300 lines of duplicated code across four test files and provide a reusable framework for future golden file tests. ## Does this PR introduce any user-facing change? No. ## How was this patch tested? Regenerated all golden files and verified tests pass. ## Was this patch authored or co-authored using generative AI tooling? No. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
