Skip to content

Commit

Permalink
fix test_commit_table
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinjqliu committed Jan 22, 2024
1 parent 76f9999 commit 9944896
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/catalog/test_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,7 @@ def test_commit_table(catalog: InMemoryCatalog) -> None:
NestedField(2, "y", LongType(), doc="comment"),
NestedField(3, "z", LongType()),
NestedField(4, "add", LongType()),
schema_id=1,
)

# When
Expand All @@ -392,8 +393,10 @@ def test_commit_table(catalog: InMemoryCatalog) -> None:

# Then
assert response.metadata.table_uuid == given_table.metadata.table_uuid
assert len(response.metadata.schemas) == 1
assert response.metadata.schemas[0] == new_schema
assert given_table.metadata.current_schema_id == 1
assert len(response.metadata.schemas) == 2
assert response.metadata.schemas[1] == new_schema.model_copy(update={"schema_id": 1})
assert given_table.metadata.last_column_id == new_schema.highest_field_id


def test_add_column(catalog: InMemoryCatalog) -> None:
Expand Down

0 comments on commit 9944896

Please sign in to comment.