forked from VimPlug/jedi
Change some tests slightly
This commit is contained in:
@@ -134,7 +134,7 @@ def test_infer_on_non_name(Script):
|
|||||||
def test_infer_on_generator(Script, environment):
|
def test_infer_on_generator(Script, environment):
|
||||||
script = Script('def x(): yield 1\ny=x()\ny')
|
script = Script('def x(): yield 1\ny=x()\ny')
|
||||||
def_, = script.infer()
|
def_, = script.infer()
|
||||||
assert def_.name == 'Generator'
|
assert def_.name == 'GeneratorType'
|
||||||
def_, = script.infer(only_stubs=True)
|
def_, = script.infer(only_stubs=True)
|
||||||
assert def_.name == 'Generator'
|
assert def_.name == 'Generator'
|
||||||
|
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ def test_sys_exc_info(Script):
|
|||||||
# It's an optional.
|
# It's an optional.
|
||||||
assert def_.name == 'BaseException'
|
assert def_.name == 'BaseException'
|
||||||
assert def_.module_path == typeshed.TYPESHED_PATH.joinpath(
|
assert def_.module_path == typeshed.TYPESHED_PATH.joinpath(
|
||||||
'stdlib', '3', 'builtins.pyi'
|
'stdlib', 'builtins.pyi'
|
||||||
)
|
)
|
||||||
assert def_.type == 'instance'
|
assert def_.type == 'instance'
|
||||||
assert none.name == 'NoneType'
|
assert none.name == 'NoneType'
|
||||||
|
|||||||
Reference in New Issue
Block a user