We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b2db73d commit 2391c7eCopy full SHA for 2391c7e
Lib/test/test_bisect.py
@@ -130,7 +130,11 @@ def test_negative_hi(self):
130
# Issue 125889
131
def assertNoRiases(f, *arg, **kwargs):
132
try:
133
- f(*arg, **kwargs)
+ res = f(*arg, **kwargs)
134
+ if f.__name__ in ('bisect_left', 'bisect_right'):
135
+ self.assertEqual(res, 3)
136
+ else:
137
+ self.assertIn(res, (3, None))
138
except Exception:
139
self.fail('Unable to work negative hi argument')
140
mod = self.module
0 commit comments