Skip to content

Commit

Permalink
test tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
teej committed Oct 29, 2024
1 parent aaa8a8c commit 05f5b6a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 17 deletions.
15 changes: 0 additions & 15 deletions examples/single-schema-example.yml

This file was deleted.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ venv = ''
line-length = 120

[tool.pytest.ini_options]
addopts = "-n 24"
addopts = "-n 48"
markers = [
"requires_snowflake: Mark a test as requiring a Snowflake connection.",
"enterprise: Mark a test that only works on Enterprise Edition Snowflake.",
Expand Down
6 changes: 5 additions & 1 deletion tests/integration/test_update.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,15 @@


def test_update_schema(cursor, test_db, marked_for_cleanup):
sch = res.Schema(name="TEST_SCHEMA", database=test_db, max_data_extension_time_in_days=10)
sch = res.Schema(name="TEST_UPDATE_SCHEMA", database=test_db, max_data_extension_time_in_days=10)
cursor.execute(sch.create_sql())
marked_for_cleanup.append(sch)
result = safe_fetch(cursor, sch.urn)
assert result is not None
assert result["max_data_extension_time_in_days"] == 10
cursor.execute(lifecycle.update_resource(sch.urn, {"max_data_extension_time_in_days": 9}, res.Schema.props))
result = safe_fetch(cursor, sch.urn)
assert result is not None
assert result["max_data_extension_time_in_days"] == 9


Expand All @@ -38,6 +40,7 @@ def test_update_array_props(cursor, test_db, suffix, marked_for_cleanup):
marked_for_cleanup.append(network_rule)
cursor.execute(network_rule.create_sql())
result = safe_fetch(cursor, network_rule.urn)
assert result is not None
assert result["value_list"] == ["192.168.1.1"]

network_rule_data["value_list"] = ["192.168.1.1", "192.168.1.2"]
Expand All @@ -48,4 +51,5 @@ def test_update_array_props(cursor, test_db, suffix, marked_for_cleanup):
assert len(plan) == 1
bp.apply(cursor.connection, plan)
result = safe_fetch(cursor, network_rule.urn)
assert result is not None
assert result["value_list"] == ["192.168.1.1", "192.168.1.2"]

0 comments on commit 05f5b6a

Please sign in to comment.