Skip to content

Commit

Permalink
exclude duckdb from tests
Browse files Browse the repository at this point in the history
  • Loading branch information
edgao committed Feb 8, 2023
1 parent ec110f4 commit 18e6f01
Showing 6 changed files with 11 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -46,7 +46,7 @@
# os.chdir(request.config.invocation_dir)


# @pytest.mark.parametrize("destination_type", list(DestinationType))
# @pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
# def test_reset_scd_on_overwrite(destination_type: DestinationType, setup_test_path):
# if destination_type.value not in dbt_test_utils.get_test_targets():
# pytest.skip(f"Destinations {destination_type} is not in NORMALIZATION_TEST_TARGET env variable")
Original file line number Diff line number Diff line change
@@ -51,7 +51,7 @@


# @pytest.mark.parametrize("column_count", [1000])
# @pytest.mark.parametrize("destination_type", list(DestinationType))
# @pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
# def test_destination_supported_limits(destination_type: DestinationType, column_count: int):
# if destination_type.value == DestinationType.MYSQL.value:
# # In MySQL, the max number of columns is limited by row size (8KB),
@@ -84,12 +84,12 @@
# run_test(destination_type, column_count, expected_exception_message)


# @pytest.mark.parametrize("destination_type", list(DestinationType))
# @pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
# def test_empty_streams(destination_type: DestinationType, setup_test_path):
# run_test(destination_type, 0)


# @pytest.mark.parametrize("destination_type", list(DestinationType))
# @pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
# def test_stream_with_1_airbyte_column(destination_type: DestinationType, setup_test_path):
# run_test(destination_type, 1)

Original file line number Diff line number Diff line change
@@ -73,7 +73,7 @@ def setup_test_path(request):
# ]
# ),
# )
# @pytest.mark.parametrize("destination_type", list(DestinationType))
# @pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
# def test_normalization(destination_type: DestinationType, test_resource_name: str, setup_test_path):
# if destination_type.value not in dbt_test_utils.get_test_targets():
# pytest.skip(f"Destinations {destination_type} is not in NORMALIZATION_TEST_TARGET env variable")
Original file line number Diff line number Diff line change
@@ -64,7 +64,7 @@ def setup_test_path(request):
os.chdir(request.config.invocation_dir)


@pytest.mark.parametrize("destination_type", list(DestinationType))
@pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
def test_sparse_nested_fields(destination_type: DestinationType):
print("!!!! DEBUG THING " + os.getcwd())
# TODO extract these conditions?
Original file line number Diff line number Diff line change
@@ -21,3 +21,7 @@ class DestinationType(Enum):
@classmethod
def from_string(cls, string_value: str) -> "DestinationType":
return DestinationType[string_value.upper()]

@staticmethod
def testable_destinations():
return [dest for dest in list(DestinationType) if dest != DestinationType.DUCKDB]
Original file line number Diff line number Diff line change
@@ -35,7 +35,7 @@ def before_tests(request):
"nested_catalog", # sample catalog from facebook
],
)
@pytest.mark.parametrize("destination_type", list(DestinationType))
@pytest.mark.parametrize("destination_type", DestinationType.testable_destinations())
def test_resolve_names(destination_type: DestinationType, catalog_file: str):
"""
For a given catalog.json and destination, multiple cases can occur where naming becomes tricky.

0 comments on commit 18e6f01

Please sign in to comment.