forked from VimPlug/jedi
It seems like join completion was wrong before when used within the interpreter.
This commit is contained in:
@@ -561,7 +561,7 @@ class Interpreter(Script):
|
|||||||
|
|
||||||
>>> from os.path import join
|
>>> from os.path import join
|
||||||
>>> namespace = locals()
|
>>> namespace = locals()
|
||||||
>>> script = Interpreter('join().up', [namespace])
|
>>> script = Interpreter('join("").up', [namespace])
|
||||||
>>> print(script.completions()[0].name)
|
>>> print(script.completions()[0].name)
|
||||||
upper
|
upper
|
||||||
"""
|
"""
|
||||||
|
|||||||
@@ -17,13 +17,13 @@ class TestInterpreterAPI(TestCase):
|
|||||||
|
|
||||||
def test_complete_raw_function(self):
|
def test_complete_raw_function(self):
|
||||||
from os.path import join
|
from os.path import join
|
||||||
self.check_interpreter_complete('join().up',
|
self.check_interpreter_complete('join("").up',
|
||||||
locals(),
|
locals(),
|
||||||
['upper'])
|
['upper'])
|
||||||
|
|
||||||
def test_complete_raw_function_different_name(self):
|
def test_complete_raw_function_different_name(self):
|
||||||
from os.path import join as pjoin
|
from os.path import join as pjoin
|
||||||
self.check_interpreter_complete('pjoin().up',
|
self.check_interpreter_complete('pjoin("").up',
|
||||||
locals(),
|
locals(),
|
||||||
['upper'])
|
['upper'])
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user