dbt-labs / dbt-adapter-tests

a pytest plugin for dbt adapter test suites
19 stars 11 forks source link

prefer adapter.get_result_from_cursor() over adapter.execute() for step_relations_equal and step_relation_rows #26

Closed dataders closed 3 years ago

dataders commented 3 years ago

the following methods make use of adapter.execute(), but would be more flexible for non-core adapters if they instead used adapter.get_result_from_cursor() instead, to allow for non-standard loading of results.

in https://github.com/firebolt-analytics/dbt-firebolt/pull/23, adapter.table_from_data_flat() is needed to be overridden to do explicit type casting. To make this test suite work, the same thing needs to be re-implemented in the methods listed above.

https://github.com/dbt-labs/dbt-adapter-tests/blob/202c3b4550734dd910db03bbff81fa19395af57d/pytest_dbt_adapter/spec_file.py#L439-L451

totally can make this fix happen later this week

dataders commented 3 years ago

nevermind!