-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Refactor testTimestampCoercion in Delta Lake connector #25676
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
('url5', 'domain2', 500), | ||
('url6', 'domain4', 2) | ||
"""); | ||
""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please revert unrelated changes. Same for other places.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've reverted the formatting changes and ensured the diff is now clean. Let me know if you see anything else I should update. Thanks!
82f009a
to
4b4fef1
Compare
4b4fef1
to
a7568e4
Compare
{ | ||
return typeCoercionTimestamp().stream() | ||
.filter(setup -> !isNestedType(setup.newColumnType())) | ||
.collect(toList()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use toImmutableList()
for (TypeCoercionTestSetup setup : typeCoercionTimestampProvider()) { | ||
try (TestTable testTable = newTrinoTable( | ||
"test_timestamp_coercion_on_create_table", | ||
"(ts %s)".formatted(setup.newColumnType))) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We are testing coercion here, so the create type shouldn't same as the insert type
Description
Refactors the
testTimestampCoercion*
methods inTestDeltaLakeConnectorTest
to use the sharedTypeCoercionTestSetup
record, improving consistency with Iceberg connector tests. It also includes a test case for coercion involving nested types such asarray(array(...))
, as requested.Additional context and related issues
Follows the approach used in Iceberg’s
BaseIcebergConnectorTest
.Improves clarity and maintainability of timestamp coercion tests for the Delta Lake connector.
Release notes
(x) This is not user-visible or is docs only, and no release notes are required.