Skip to content

Commit

Permalink
test: Add len udf test.
Browse files Browse the repository at this point in the history
  • Loading branch information
DanCardin committed Jun 10, 2024
1 parent fa4fc02 commit f21f214
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
20 changes: 18 additions & 2 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ filelock = {version = "*", optional = true}
python-on-whales = {version = ">=0.22.0", optional = true}

[tool.poetry.dev-dependencies]
botocore = ">=1.31.63"
botocore = "1.33.13"
coverage = "*"
moto = ">=2.3.2"
mypy = {version = "0.982"}
Expand Down
6 changes: 6 additions & 0 deletions tests/fixture/redshift/test_udf.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,3 +210,9 @@ def test_right_integer(self, redshift):
result = conn.execute(text("SELECT RIGHT(1234, 2)"))
result = result.fetchone()
assert result[0] == 34

def test_len(self, redshift):
with redshift.connect() as conn:
result = conn.execute(text("SELECT len('1234')"))
result = result.fetchone()
assert result[0] == 4

0 comments on commit f21f214

Please sign in to comment.