datahub/metadata-ingestion/tests/unit/test_druid_source.py

14 lines
401 B
Python
Raw Permalink Normal View History

from datahub.ingestion.source.sql.druid import DruidConfig
def test_druid_uri():
config = DruidConfig.parse_obj({"host_port": "localhost:8082"})
assert config.get_sql_alchemy_url() == "druid://localhost:8082/druid/v2/sql/"
def test_druid_get_identifier():
config = DruidConfig.parse_obj({"host_port": "localhost:8082"})
assert config.get_identifier("schema", "table") == "table"