summaryrefslogtreecommitdiff
path: root/numpy/random/tests
diff options
context:
space:
mode:
authorEric Wieser <wieser.eric@gmail.com>2020-03-26 17:50:20 +0000
committerGitHub <noreply@github.com>2020-03-26 12:50:20 -0500
commit1c58504eec43f9ba18ac835131fed496fb59772d (patch)
tree4ffc786c9cdac81887680aa999ae6dcbd4bd407d /numpy/random/tests
parent5ff70eb0fd61a39207d5166479507e1b099cb707 (diff)
downloadnumpy-1c58504eec43f9ba18ac835131fed496fb59772d.tar.gz
MAINT: simplify code that assumes str/unicode and int/long are different types (#15816)
Cleanup from the dropping of python 2
Diffstat (limited to 'numpy/random/tests')
-rw-r--r--numpy/random/tests/test_generator_mt19937_regressions.py8
-rw-r--r--numpy/random/tests/test_randomstate_regression.py8
-rw-r--r--numpy/random/tests/test_regression.py8
3 files changed, 0 insertions, 24 deletions
diff --git a/numpy/random/tests/test_generator_mt19937_regressions.py b/numpy/random/tests/test_generator_mt19937_regressions.py
index f0b502d06..456c932d4 100644
--- a/numpy/random/tests/test_generator_mt19937_regressions.py
+++ b/numpy/random/tests/test_generator_mt19937_regressions.py
@@ -1,5 +1,4 @@
from numpy.testing import (assert_, assert_array_equal)
-from numpy.compat import long
import numpy as np
import pytest
from numpy.random import Generator, MT19937
@@ -41,13 +40,6 @@ class TestRegression:
msg = "Frequency was %f, should be < 0.23" % freq
assert_(freq < 0.23, msg)
- def test_permutation_longs(self):
- mt19937 = Generator(MT19937(1234))
- a = mt19937.permutation(12)
- mt19937 = Generator(MT19937(1234))
- b = mt19937.permutation(long(12))
- assert_array_equal(a, b)
-
def test_shuffle_mixed_dimension(self):
# Test for trac ticket #2074
for t in [[1, 2, 3, None],
diff --git a/numpy/random/tests/test_randomstate_regression.py b/numpy/random/tests/test_randomstate_regression.py
index 1d8a0ed5a..4eb82fc4c 100644
--- a/numpy/random/tests/test_randomstate_regression.py
+++ b/numpy/random/tests/test_randomstate_regression.py
@@ -5,7 +5,6 @@ import pytest
from numpy.testing import (
assert_, assert_array_equal, assert_raises,
)
-from numpy.compat import long
import numpy as np
from numpy import random
@@ -52,13 +51,6 @@ class TestRegression:
msg = "Frequency was %f, should be < 0.23" % freq
assert_(freq < 0.23, msg)
- def test_permutation_longs(self):
- random.seed(1234)
- a = random.permutation(12)
- random.seed(1234)
- b = random.permutation(long(12))
- assert_array_equal(a, b)
-
def test_shuffle_mixed_dimension(self):
# Test for trac ticket #2074
for t in [[1, 2, 3, None],
diff --git a/numpy/random/tests/test_regression.py b/numpy/random/tests/test_regression.py
index cd8f3891c..278622287 100644
--- a/numpy/random/tests/test_regression.py
+++ b/numpy/random/tests/test_regression.py
@@ -3,7 +3,6 @@ from numpy.testing import (
assert_, assert_array_equal, assert_raises,
)
from numpy import random
-from numpy.compat import long
import numpy as np
@@ -48,13 +47,6 @@ class TestRegression:
msg = "Frequency was %f, should be < 0.23" % freq
assert_(freq < 0.23, msg)
- def test_permutation_longs(self):
- np.random.seed(1234)
- a = np.random.permutation(12)
- np.random.seed(1234)
- b = np.random.permutation(long(12))
- assert_array_equal(a, b)
-
def test_shuffle_mixed_dimension(self):
# Test for trac ticket #2074
for t in [[1, 2, 3, None],