mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-16 02:27:06 +08:00
NotFoundError doesn't really exist anymore. We're deprecating it, so change the corresponding tests.
This commit is contained in:
@@ -456,7 +456,7 @@ class Completion(BaseDefinition):
|
||||
return ''
|
||||
t = self.type
|
||||
if t == 'statement' or t == 'import':
|
||||
desc = self._definition.get_code(False)
|
||||
desc = self._definition.get_code()
|
||||
else:
|
||||
desc = '.'.join(unicode(p) for p in self._path())
|
||||
|
||||
|
||||
@@ -99,11 +99,9 @@ def test_completion_on_complex_literals():
|
||||
|
||||
|
||||
def test_goto_assignments_on_non_statement():
|
||||
with raises(api.NotFoundError):
|
||||
api.Script('for').goto_assignments()
|
||||
assert api.Script('for').goto_assignments() == []
|
||||
|
||||
with raises(api.NotFoundError):
|
||||
api.Script('assert').goto_assignments()
|
||||
assert api.Script('assert').goto_assignments() == []
|
||||
|
||||
|
||||
def test_goto_definition_not_multiple():
|
||||
|
||||
Reference in New Issue
Block a user