Show More
@@ -26,15 +26,6 b' from IPython.core.completer import (' | |||||
26 | _deduplicate_completions, |
|
26 | _deduplicate_completions, | |
27 | ) |
|
27 | ) | |
28 |
|
28 | |||
29 | if sys.version_info >= (3, 10): |
|
|||
30 | import jedi |
|
|||
31 | from pkg_resources import parse_version |
|
|||
32 |
|
||||
33 | # Requires https://github.com/davidhalter/jedi/pull/1795 |
|
|||
34 | jedi_issue = parse_version(jedi.__version__) <= parse_version("0.18.0") |
|
|||
35 | else: |
|
|||
36 | jedi_issue = False |
|
|||
37 |
|
||||
38 | # ----------------------------------------------------------------------------- |
|
29 | # ----------------------------------------------------------------------------- | |
39 | # Test functions |
|
30 | # Test functions | |
40 | # ----------------------------------------------------------------------------- |
|
31 | # ----------------------------------------------------------------------------- | |
@@ -430,8 +421,6 b' class TestCompleter(unittest.TestCase):' | |||||
430 | matches = c.all_completions("TestCl") |
|
421 | matches = c.all_completions("TestCl") | |
431 | assert matches == ['TestClass'], jedi_status |
|
422 | assert matches == ['TestClass'], jedi_status | |
432 | matches = c.all_completions("TestClass.") |
|
423 | matches = c.all_completions("TestClass.") | |
433 | if jedi_status and jedi_issue: |
|
|||
434 | continue |
|
|||
435 | assert len(matches) > 2, jedi_status |
|
424 | assert len(matches) > 2, jedi_status | |
436 | matches = c.all_completions("TestClass.a") |
|
425 | matches = c.all_completions("TestClass.a") | |
437 | assert matches == ['TestClass.a', 'TestClass.a1'], jedi_status |
|
426 | assert matches == ['TestClass.a', 'TestClass.a1'], jedi_status | |
@@ -486,7 +475,6 b' class TestCompleter(unittest.TestCase):' | |||||
486 | "encoding" in c.signature |
|
475 | "encoding" in c.signature | |
487 | ), "Signature of function was not found by completer" |
|
476 | ), "Signature of function was not found by completer" | |
488 |
|
477 | |||
489 | @pytest.mark.xfail(jedi_issue, reason="Known failure on jedi<=0.18.0") |
|
|||
490 | def test_deduplicate_completions(self): |
|
478 | def test_deduplicate_completions(self): | |
491 | """ |
|
479 | """ | |
492 | Test that completions are correctly deduplicated (even if ranges are not the same) |
|
480 | Test that completions are correctly deduplicated (even if ranges are not the same) |
General Comments 0
You need to be logged in to leave comments.
Login now