diff options
author | Zachary Ware <zachary.ware@gmail.com> | 2013-11-26 20:54:21 (GMT) |
---|---|---|
committer | Zachary Ware <zachary.ware@gmail.com> | 2013-11-26 20:54:21 (GMT) |
commit | 29f8cb64e64cbbb3e5da7b280b78d37b58719070 (patch) | |
tree | 046fb347769fbf383cca37f4c019cc5ced5ccf09 | |
parent | 518e6ee98b6d5a231ff9fcc603a92d15e962ba19 (diff) | |
parent | a6edea530bb9f3a9ff6234f443ea5d00428a7635 (diff) | |
download | cpython-29f8cb64e64cbbb3e5da7b280b78d37b58719070.zip cpython-29f8cb64e64cbbb3e5da7b280b78d37b58719070.tar.gz cpython-29f8cb64e64cbbb3e5da7b280b78d37b58719070.tar.bz2 |
Issue #19588: Merge with 3.3
-rw-r--r-- | Lib/test/test_random.py | 12 | ||||
-rw-r--r-- | Misc/ACKS | 1 | ||||
-rw-r--r-- | Misc/NEWS | 6 |
3 files changed, 13 insertions, 6 deletions
diff --git a/Lib/test/test_random.py b/Lib/test/test_random.py index 49a3f7b..7d1a53a 100644 --- a/Lib/test/test_random.py +++ b/Lib/test/test_random.py @@ -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): @@ -449,6 +449,7 @@ Dinu Gherman Jonathan Giddy Johannes Gijsbers Michael Gilfix +Julian Gindi Yannick Gingras Matt Giuca Wim Glenn @@ -21,6 +21,12 @@ Library - Issue #19545: Avoid chained exceptions while passing stray % to time.strptime(). Initial patch by Claudiu Popa. +Tests +----- + +- Issue #19588: Fixed tests in test_random that were silently skipped most + of the time. Patch by Julian Gindi. + What's New in Python 3.4.0 Beta 1? ================================== |