mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-07 06:24:27 +08:00
Make sure an assert no longer causes unnecessary trouble
Fixes #1426, fixes #1414
This commit is contained in:
@@ -414,3 +414,13 @@ def test_decorator(Script):
|
||||
|
||||
d, = Script(code).goto_definitions()
|
||||
assert d.docstring(raw=True) == 'Nice docstring'
|
||||
|
||||
|
||||
def test_basic_str_init_signature(Script, disable_typeshed):
|
||||
# See GH #1414 and GH #1426
|
||||
code = dedent('''
|
||||
class Foo(str):
|
||||
pass
|
||||
Foo(''')
|
||||
c, = Script(code).call_signatures()
|
||||
assert c.name == 'Foo'
|
||||
|
||||
Reference in New Issue
Block a user