Test an edge case for sample().

This commit is contained in:
Raymond Hettinger 2003-01-04 05:55:11 +00:00
parent 8b9aa8dbba
commit 8ec78814c1

View file

@ -63,6 +63,7 @@ class TestBasicOps(unittest.TestCase):
uniq = dict.fromkeys(s)
self.assertEqual(len(uniq), k)
self.failIf(None in uniq)
self.assertEqual(self.gen.sample([], 0), []) # test edge case N==k==0
def test_gauss(self):
# Ensure that the seed() method initializes all the hidden state. In