mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
#10159: sort completion matches before comparing to dir() result.
This commit is contained in:
parent
f933e1ab6f
commit
50de5f56a9
1 changed files with 2 additions and 2 deletions
|
@ -31,9 +31,9 @@ class TestRlcompleter(unittest.TestCase):
|
|||
|
||||
def test_global_matches(self):
|
||||
# test with builtins namespace
|
||||
self.assertEqual(self.stdcompleter.global_matches('di'),
|
||||
self.assertEqual(sorted(self.stdcompleter.global_matches('di')),
|
||||
[x+'(' for x in dir(builtins) if x.startswith('di')])
|
||||
self.assertEqual(self.stdcompleter.global_matches('st'),
|
||||
self.assertEqual(sorted(self.stdcompleter.global_matches('st')),
|
||||
[x+'(' for x in dir(builtins) if x.startswith('st')])
|
||||
self.assertEqual(self.stdcompleter.global_matches('akaksajadhak'), [])
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue