Skip to content

Commit 5f836ea

Browse files
committed
Add a test for #491
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
1 parent 45fb40d commit 5f836ea

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

bpython/test/test_autocomplete.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,9 @@ def test_locate_fails_when_not_in_string(self):
129129
def test_locate_succeeds_when_in_string(self):
130130
self.assertEqual(self.completer.locate(4, "a'bc'd"), (2, 4, 'bc'))
131131

132+
def test_issue_491(self):
133+
self.assertNotEqual(self.completer.matches(9, '"a[a.l-1]'), None)
134+
132135
@mock.patch(glob_function, new=lambda text: [])
133136
def test_match_returns_none_if_not_in_string(self):
134137
self.assertEqual(self.completer.matches(2, 'abcd'), None)

0 commit comments

Comments
 (0)