dongjoon-hyun opened a new pull request, #401: URL: https://github.com/apache/spark-connect-swift/pull/401
### What changes were proposed in this pull request? This PR re-enables the constraint test coverage (SPARK-51207, SPIP: Constraints in DSv2) that was disabled in SPARK-54998, by moving the four tests out of the disabled `ConstraintTests` suite into `IcebergTests` and switching them from `USING ORC` (DSv1) to `USING ICEBERG` (DSv2): - `primary_key`, `foreign_key`, `unique`, and `check` now create `local.db.*` Iceberg tables and run under the existing `SPARK_ICEBERG_TEST_ENABLED` guard, like the other `IcebergTests`. - The `spark.version.starts(with: "4.1")` guard is kept so the constraint syntax (a Spark 4.1+ feature) runs only on the Spark `4.1.2` Iceberg CI job and is skipped on the Spark `4.0.2` one. - `Tests/SparkConnectTests/ConstraintTests.swift` is removed. - Fix the `foreign_key` test to reference the parent table (`tableName1`, which has `id`) instead of the table being created. ### Why are the changes needed? `ConstraintTests` was disabled in SPARK-54998 because Spark 4.1.1+ started throwing on constraint syntax for DSv1 (ORC) tables after SPARK-54761, and the original plan was to revisit this with DSv2 tables once Apache Iceberg supported Spark 4.1. Iceberg now ships a Spark 4.1 runtime (`iceberg-spark-runtime-4.1_2.13:1.11.0`, already used by CI), so the constraint syntax can be validated against DSv2/Iceberg tables as originally intended. ### Does this PR introduce _any_ user-facing change? No. This is a test-only change. ### How was this patch tested? Pass the CIs. The constraint tests run in the `SPARK_ICEBERG_TEST_ENABLED` jobs; the constraint bodies execute only on the Spark `4.1.2` Iceberg job (gated by `spark.version.starts(with: "4.1")`). Verified locally with `swift build -c release` and `swift test --filter NOTHING -c release`. ### Was this patch authored or co-authored using generative AI tooling? Generated-by: Claude Code (Claude Opus 4.8) -- 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]
