diff --git a/tests/core.py b/tests/core.py index 330926f..2a3da6d 100644 --- a/tests/core.py +++ b/tests/core.py @@ -38,9 +38,9 @@ def validate(self) -> None: assert result.rowcount == 4 row = result.first() if self.target.config.get("add_record_metadata", True): - assert len(row) == 8 + assert len(row) == 8, f"Row has unexpected length {len(row)}" else: - assert len(row) == 2 + assert len(row) == 2, f"Row has unexpected length {len(row)}" assert row[1] == '[\n "apple",\n "orange",\n "pear"\n]' table_schema = connector.get_table(table) @@ -85,6 +85,7 @@ def validate(self) -> None: "_sdc_batched_at": sct.TIMESTAMP_NTZ, "_sdc_received_at": sct.TIMESTAMP_NTZ, "_sdc_deleted_at": sct.TIMESTAMP_NTZ, + "_sdc_sync_started_at": sct.NUMBER, "_sdc_table_version": sct.NUMBER, "_sdc_sequence": sct.NUMBER, } @@ -237,9 +238,9 @@ def validate(self) -> None: assert result.rowcount == 2 row = result.first() if self.target.config.get("add_record_metadata", True): - assert len(row) == 7 + assert len(row) == 7, f"Row has unexpected length {len(row)}" else: - assert len(row) == 1 + assert len(row) == 1, f"Row has unexpected length {len(row)}" table_schema = connector.get_table(table) expected_types = { @@ -271,9 +272,9 @@ def validate(self) -> None: row = result.first() if self.target.config.get("add_record_metadata", True): - assert len(row) == 13 + assert len(row) == 13, f"Row has unexpected length {len(row)}" else: - assert len(row) == 7 + assert len(row) == 7, f"Row has unexpected length {len(row)}" table_schema = connector.get_table(table) expected_types = { @@ -317,7 +318,7 @@ def validate(self) -> None: ) assert result.rowcount == 2 row = result.first() - assert len(row) == 11 + assert len(row) == 11, f"Row has unexpected length {len(row)}" class SnowflakeTargetReservedWordsNoKeyProps(TargetFileTestTemplate): @@ -339,7 +340,7 @@ def validate(self) -> None: ) assert result.rowcount == 1 row = result.first() - assert len(row) == 10 + assert len(row) == 10, f"Row has unexpected length {len(row)}" class SnowflakeTargetColonsInColName(TargetFileTestTemplate): @@ -358,7 +359,7 @@ def validate(self) -> None: ) assert result.rowcount == 1 row = result.first() - assert len(row) == 11 + assert len(row) == 12, f"Row has unexpected length {len(row)}" table_schema = connector.get_table(table) assert {column.name for column in table_schema.columns} == { "FOO::BAR", @@ -370,6 +371,7 @@ def validate(self) -> None: "_sdc_batched_at", "_sdc_received_at", "_sdc_deleted_at", + "_sdc_sync_started_at", "_sdc_table_version", "_sdc_sequence", } @@ -414,7 +416,7 @@ def validate(self) -> None: ) assert result.rowcount == 1 row = result.first() - assert len(row) == 12 + assert len(row) == 12, f"Row has unexpected length {len(row)}" class SnowflakeTargetExistingTableAlter(SnowflakeTargetExistingTable): @@ -466,6 +468,7 @@ def validate(self) -> None: "_sdc_batched_at": sct.TIMESTAMP_NTZ, "_sdc_received_at": sct.TIMESTAMP_NTZ, "_sdc_deleted_at": sct.TIMESTAMP_NTZ, + "_sdc_sync_started_at": sct.NUMBER, "_sdc_table_version": sct.NUMBER, "_sdc_sequence": sct.NUMBER, }