Skip to content

Commit ee550f1

Browse files
committed
Add test case for andialbrecht#542.
1 parent 6b10952 commit ee550f1

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

tests/test_format.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -722,3 +722,10 @@ def test_format_right_margin_invalid_option(right_margin):
722722
def test_format_right_margin():
723723
# TODO: Needs better test, only raises exception right now
724724
sqlparse.format('foo', right_margin="79")
725+
726+
727+
def test_format_json_ops(): # issue542
728+
formatted = sqlparse.format(
729+
"select foo->'bar', foo->'bar';", reindent=True)
730+
expected = "select foo->'bar',\n foo->'bar';"
731+
assert formatted == expected

0 commit comments

Comments
 (0)