Skip to content

Commit

Permalink
Fix final test
Browse files Browse the repository at this point in the history
  • Loading branch information
wjones127 committed Sep 24, 2022
1 parent 1c9396b commit 55a57a2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions python/tests/pyspark_integration/test_write_to_pyspark.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,10 @@ def test_checks_min_writer_version(tmp_path: pathlib.Path):
)

# Add a constraint upgrades the minWriterProtocol
spark.sql(f"ALTER TABLE delta.{str(tmp_path)} ADD CONSTRAINT x CHECK c1 > 2")
spark.sql(f"ALTER TABLE delta.`{str(tmp_path)}` ADD CONSTRAINT x CHECK (c1 > 2)")

with pytest.raises(
PyDeltaTableError, match="The table's min_writer_version is 3 but"
PyDeltaTableError, match="This table's min_writer_version is 3, but"
):
valid_data = pa.table({"c1": pa.array([5, 6], type=pa.int32())})
valid_data = pa.table({"c1": pa.array([5, 6])})
write_deltalake(str(tmp_path), valid_data, mode="append")

0 comments on commit 55a57a2

Please sign in to comment.