summaryrefslogtreecommitdiff
path: root/tests/test_grouping.py
diff options
context:
space:
mode:
authorAndi Albrecht <albrecht.andi@googlemail.com>2010-02-18 09:58:12 +0100
committerAndi Albrecht <albrecht.andi@googlemail.com>2010-02-18 09:58:12 +0100
commitfac431b15799fd9561346efcc128e0b5e8aec3d0 (patch)
tree62826ad30314673bdba618f690d726c380db121b /tests/test_grouping.py
parented2d2549f846a04d13be33a4971a4e4a0089914f (diff)
downloadsqlparse-fac431b15799fd9561346efcc128e0b5e8aec3d0.tar.gz
Fix an issue with trailing whitespaces (reported by Kris).
Diffstat (limited to 'tests/test_grouping.py')
-rw-r--r--tests/test_grouping.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/test_grouping.py b/tests/test_grouping.py
index 119f574..dcc1309 100644
--- a/tests/test_grouping.py
+++ b/tests/test_grouping.py
@@ -176,3 +176,7 @@ class TestStatement(TestCaseBase):
self.assertEqual(f(' update foo').get_type(), 'UPDATE')
self.assertEqual(f('\nupdate foo').get_type(), 'UPDATE')
self.assertEqual(f('foo').get_type(), 'UNKNOWN')
+ # Statements that have a whitespace after the closing semicolon
+ # are parsed as two statements where later only consists of the
+ # trailing whitespace.
+ self.assertEqual(f('\n').get_type(), 'UNKNOWN')