mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-06 22:14:27 +08:00
Make sure that the builtin docstring works again for infer calls
This commit is contained in:
@@ -89,3 +89,11 @@ def test_version_info(Script):
|
||||
|
||||
c, = s.completions()
|
||||
assert c.docstring() == 'sys.version_info\n\nVersion information as a named tuple.'
|
||||
|
||||
|
||||
def test_builtin_docstring(Script, goto_or_help_or_infer):
|
||||
d, = goto_or_help_or_infer('open')
|
||||
|
||||
doc = d.docstring()
|
||||
assert doc.startswith('open(file: Union[')
|
||||
assert 'Open file' in doc or 'Open a file' in doc
|
||||
|
||||
Reference in New Issue
Block a user