Issue #19588: Merge with 3.3
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 @@
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 @@
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):
diff --git a/Misc/ACKS b/Misc/ACKS
index 8c2aa4d..36cbdd7 100644
--- a/Misc/ACKS
+++ b/Misc/ACKS
@@ -449,6 +449,7 @@
Jonathan Giddy
Johannes Gijsbers
Michael Gilfix
+Julian Gindi
Yannick Gingras
Matt Giuca
Wim Glenn
diff --git a/Misc/NEWS b/Misc/NEWS
index a3f3309..28382f1 100644
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -21,6 +21,12 @@
- 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?
==================================