https://github.com/python/cpython/commit/91b07ca87a3e7af29fc5f84419a1aec08cf10aac commit: 91b07ca87a3e7af29fc5f84419a1aec08cf10aac branch: 3.15 author: Miss Islington (bot) <[email protected]> committer: picnixz <[email protected]> date: 2026-10-28T08:52:30Z summary:
[3.15] gh-140036: Test modulo and divmod of pure Python Decimal in unbounded contexts (GH-160482) (#160808) gh-140036: Test modulo and divmod of pure Python Decimal in unbounded contexts (GH-160482) (cherry picked from commit e7ab898188c6f41ee035bf264e06444d143a008c) Co-authored-by: Bénédikt Tran <[email protected]> files: M Lib/test/test_decimal.py diff --git a/Lib/test/test_decimal.py b/Lib/test/test_decimal.py index ad5d87e1418ebf..24980a34c7490e 100644 --- a/Lib/test/test_decimal.py +++ b/Lib/test/test_decimal.py @@ -4721,6 +4721,16 @@ def test_divide_unbound_context(self): x = self.decimal.Decimal('1') y = x // 1 # should be fast + def test_modulo_unbound_context(self): + with self.unbound_context() as c: + x = self.decimal.Decimal('1') + y = x % 1 # should be fast + + def test_divmod_unbound_context(self): + with self.unbound_context() as c: + x = self.decimal.Decimal('1') + y = divmod(x, 1) # should be fast + def test_remainder_near(self): L = 1000 limit = sys.get_int_max_str_digits() _______________________________________________ Python-checkins mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3//lists/python-checkins.python.org Member address: [email protected]
