summaryrefslogtreecommitdiffstats
path: root/tests/test_smart_completion_multiple_schemata.py
diff options
context:
space:
mode:
authorIrina Truong <i.chernyavska@gmail.com>2017-06-09 14:41:33 -0700
committerIrina Truong <i.chernyavska@gmail.com>2017-06-09 14:41:33 -0700
commitea0556b8c6e663bdb2c6d78fe63cd50ce007974e (patch)
tree3e06fc5881d52aab8dbbddea278f2efbbe1b37bd /tests/test_smart_completion_multiple_schemata.py
parent6c814acd5f891fceacb38ca9012676d16195a3bc (diff)
Schema name should be escaped in SET SCHEMA.
Diffstat (limited to 'tests/test_smart_completion_multiple_schemata.py')
-rw-r--r--tests/test_smart_completion_multiple_schemata.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/test_smart_completion_multiple_schemata.py b/tests/test_smart_completion_multiple_schemata.py
index d2276d1f..df6ecc37 100644
--- a/tests/test_smart_completion_multiple_schemata.py
+++ b/tests/test_smart_completion_multiple_schemata.py
@@ -575,3 +575,14 @@ def test_all_schema_objects_with_aliases(completer):
[table(x) for x in ('orders o', '"select" s', 'custom.shipments s')]
+ [function(x) for x in ('func2() f', 'custom.func3() f')]
)
+
+
+@parametrize('completer', completers(casing=False, filtr=False, aliasing=True))
+def test_set_schema(completer):
+ text = ('SET SCHEMA ')
+ result = result_set(completer, text)
+ assert result == set([
+ schema(u"'blog'"),
+ schema(u"'Custom'"),
+ schema(u"'custom'"),
+ schema(u"'public'")])