Skip to content

Commit bbf976d

Browse files
committed
+ fix test
1 parent fedfd28 commit bbf976d

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

Lib/test/test_capi/test_number.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -287,11 +287,7 @@ def test_float(self):
287287
self.assertEqual(float_(IndexLike.with_val(-1)), -1.0)
288288

289289
self.assertRaises(TypeError, float_, FloatLike.with_val(687))
290-
with warnings.catch_warnings():
291-
warnings.simplefilter("error", DeprecationWarning)
292-
self.assertRaises(DeprecationWarning, float_, FloatLike.with_val(subclassof(float)(4.25)))
293-
with self.assertWarns(DeprecationWarning):
294-
self.assertEqual(float_(FloatLike.with_val(subclassof(float)(4.25))), 4.25)
290+
self.assertRaises(TypeError, float_, FloatLike.with_val(subclassof(float)(4.25)))
295291
self.assertRaises(RuntimeError, float_, FloatLike.with_exc(RuntimeError))
296292

297293
self.assertRaises(TypeError, float_, IndexLike.with_val(1.25))

0 commit comments

Comments
 (0)