diff options
author | koljonen <koljonen@outlook.com> | 2016-05-25 13:01:57 +0200 |
---|---|---|
committer | koljonen <koljonen@outlook.com> | 2016-06-02 01:44:31 +0200 |
commit | 5d9dfcdcc3e6049942e35f9e3bfb831aace5f824 (patch) | |
tree | 47e9f7566048dd25d7d5bdae82d6d3a803c8c7b4 /tests/test_smart_completion_public_schema_only.py | |
parent | f912633d6ded6ed563f8b8ba88525839afa20031 (diff) |
Use pg_proc.proargmodes &c. instead of parsing arg_list
Getting the parameters from proargnames, proallargtypes and proargmodes instead of from parsing the arg_list string simplifies FunctionMetadata quite a bit.
I also made the ColumnMetadata for table/view columns use the same format for the type (i.e. regtype instead of typname). This means we now get join-condition suggestions for joining tables/views to functions, which didn't work before.
Diffstat (limited to 'tests/test_smart_completion_public_schema_only.py')
-rw-r--r-- | tests/test_smart_completion_public_schema_only.py | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tests/test_smart_completion_public_schema_only.py b/tests/test_smart_completion_public_schema_only.py index 9f78c49f..4e2048c7 100644 --- a/tests/test_smart_completion_public_schema_only.py +++ b/tests/test_smart_completion_public_schema_only.py @@ -13,10 +13,12 @@ metadata = { 'views': { 'user_emails': ['id', 'email']}, 'functions': [ - ['custom_func1', '', '', False, False, False], - ['custom_func2', '', '', False, False, False], - ['set_returning_func', '', 'TABLE (x INT, y INT)', - False, False, True]], + ['custom_func1', [''], [''], [''], '', False, False, + False], + ['custom_func2', [''], [''], [''], '', False, False, + False], + ['set_returning_func', ['x', 'y'], ['integer', 'integer'], + ['o', 'o'], '', False, False, True]], 'datatypes': ['custom_type1', 'custom_type2'], } |