1
0
forked from VimPlug/jedi

Fix a few numpydocs tests

This commit is contained in:
Dave Halter
2018-02-28 23:44:50 +01:00
parent 3820111d1e
commit 2abcd0b6a6

View File

@@ -329,8 +329,10 @@ def test_numpydoc_yields():
reason='numpydoc or numpy module is unavailable')
def test_numpy_returns():
s = dedent('''
x = numpy.asarray([])
x.d''')
import numpy
x = numpy.asarray([])
x.d'''
)
names = [c.name for c in jedi.Script(s).completions()]
print(names)
assert 'diagonal' in names
@@ -340,8 +342,10 @@ def test_numpy_returns():
reason='numpydoc or numpy module is unavailable')
def test_numpy_comp_returns():
s = dedent('''
x = numpy.array([])
x.d''')
import numpy
x = numpy.array([])
x.d'''
)
names = [c.name for c in jedi.Script(s).completions()]
print(names)
assert 'diagonal' in names