summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorVictor Uriarte <victor.m.uriarte@intel.com>2016-06-04 15:08:40 -0700
committerVictor Uriarte <victor.m.uriarte@intel.com>2016-06-11 04:35:16 -0700
commit954f48431a0fe8ea1749ba0236da23a705bf3b75 (patch)
treea7b5f91fb81609dc04efae6f82d3aca032d1772e /tests
parent29e3df5c2c0a62f16668f89f4a5e738156c276a7 (diff)
downloadsqlparse-954f48431a0fe8ea1749ba0236da23a705bf3b75.tar.gz
Redo unicode-encoding on lexer.py
Diffstat (limited to 'tests')
-rw-r--r--tests/test_split.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test_split.py b/tests/test_split.py
index f6d5f50..7c2645d 100644
--- a/tests/test_split.py
+++ b/tests/test_split.py
@@ -133,6 +133,11 @@ class SQLSplitTest(TestCaseBase):
stmts = list(sqlparse.parsestream(stream))
self.assertEqual(type(stmts[0].tokens[0].value), text_type)
+ def test_unicode_parsestream(self):
+ stream = StringIO(u"SELECT ö")
+ stmts = list(sqlparse.parsestream(stream))
+ self.assertEqual(str(stmts[0]), "SELECT ö")
+
def test_split_simple():
stmts = sqlparse.split('select * from foo; select * from bar;')