1
0
forked from VimPlug/jedi

Add a py__name__ call to modules. This makes listing the qualified names of modules possible (in combination with the module_name_cache). Fixes #519.

This commit is contained in:
Dave Halter
2015-04-14 17:36:20 +02:00
parent 2f64a83e3c
commit 8fca3f78a1
8 changed files with 86 additions and 26 deletions

View File

@@ -15,7 +15,7 @@ def test_user_statement_on_import():
" time)")
for pos in [(2, 1), (2, 4)]:
p = UserContextParser(load_grammar(), s, None, pos, None).user_stmt()
p = UserContextParser(load_grammar(), s, None, pos, None, lambda x: 1).user_stmt()
assert isinstance(p, pt.Import)
assert [str(n) for n in p.get_defined_names()] == ['time']