summaryrefslogtreecommitdiff
path: root/numpy/random/tests/test_randomstate.py
diff options
context:
space:
mode:
authorKevin Sheppard <kevin.k.sheppard@gmail.com>2019-04-11 07:59:21 +0100
committermattip <matti.picus@gmail.com>2019-05-20 18:45:27 +0300
commit0f3dd0650adc82bae0050cbc5a13cb82659c8faf (patch)
tree9015035429ccccd50548a172131ea78e1d968c65 /numpy/random/tests/test_randomstate.py
parent9578dcfbe744854312690ea79063e50d67fc88a2 (diff)
downloadnumpy-0f3dd0650adc82bae0050cbc5a13cb82659c8faf.tar.gz
ENH: Extend multinomial and fix zipf
Extend multinomial to allow broadcasting Fix zipf changes missed in NumPy Enable 0 as valid input for hypergeometric
Diffstat (limited to 'numpy/random/tests/test_randomstate.py')
-rw-r--r--numpy/random/tests/test_randomstate.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/numpy/random/tests/test_randomstate.py b/numpy/random/tests/test_randomstate.py
index d0ad5e794..8d10823d6 100644
--- a/numpy/random/tests/test_randomstate.py
+++ b/numpy/random/tests/test_randomstate.py
@@ -112,6 +112,10 @@ class TestMultinomial(object):
def test_invalid_prob(self):
assert_raises(ValueError, random.multinomial, 100, [1.1, 0.2])
+ assert_raises(ValueError, random.multinomial, 100, [-.1, 0.9])
+
+ def test_invalid_n(self):
+ assert_raises(ValueError, random.multinomial, -1, [0.8, 0.2])
class TestSetState(object):