fix: Presto column_type_mappings time and timestamp (#12861)

* Fix presto column_type_mappings time and timestamp

* Added unit tests
This commit is contained in:
Ricardo Gândara Pinto
2021-02-01 15:41:57 +00:00
committed by GitHub
parent 783aae19c9
commit 51195af4fa
2 changed files with 7 additions and 1 deletions

View File

@@ -554,6 +554,12 @@ class TestPrestoDbEngineSpec(TestDbEngineSpec):
sqla_type = PrestoEngineSpec.get_sqla_column_type("integer")
assert isinstance(sqla_type, types.Integer)
sqla_type = PrestoEngineSpec.get_sqla_column_type("time")
assert isinstance(sqla_type, types.Time)
sqla_type = PrestoEngineSpec.get_sqla_column_type("timestamp")
assert isinstance(sqla_type, types.TIMESTAMP)
sqla_type = PrestoEngineSpec.get_sqla_column_type(None)
assert sqla_type is None