mirror of
https://github.com/python/cpython.git
synced 2025-08-31 05:58:33 +00:00
Issue #19588: Merge with 3.3
This commit is contained in:
commit
29f8cb64e6
3 changed files with 13 additions and 6 deletions
|
@ -240,10 +240,10 @@ class SystemRandom_TestBasicOps(TestBasicOps, unittest.TestCase):
|
|||
|
||||
def test_bigrand_ranges(self):
|
||||
for i in [40,80, 160, 200, 211, 250, 375, 512, 550]:
|
||||
start = self.gen.randrange(2 ** i)
|
||||
stop = self.gen.randrange(2 ** (i-2))
|
||||
start = self.gen.randrange(2 ** (i-2))
|
||||
stop = self.gen.randrange(2 ** i)
|
||||
if stop <= start:
|
||||
return
|
||||
continue
|
||||
self.assertTrue(start <= self.gen.randrange(start, stop) < stop)
|
||||
|
||||
def test_rangelimits(self):
|
||||
|
@ -432,10 +432,10 @@ class MersenneTwister_TestBasicOps(TestBasicOps, unittest.TestCase):
|
|||
|
||||
def test_bigrand_ranges(self):
|
||||
for i in [40,80, 160, 200, 211, 250, 375, 512, 550]:
|
||||
start = self.gen.randrange(2 ** i)
|
||||
stop = self.gen.randrange(2 ** (i-2))
|
||||
start = self.gen.randrange(2 ** (i-2))
|
||||
stop = self.gen.randrange(2 ** i)
|
||||
if stop <= start:
|
||||
return
|
||||
continue
|
||||
self.assertTrue(start <= self.gen.randrange(start, stop) < stop)
|
||||
|
||||
def test_rangelimits(self):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue