def test_moments(self): custm = stats.rv_discrete(name='Uniform', values=pb(self.params)) print custm.mean(), custm.var() self.assertEqual(custm.mean(), 550) self.assertEqual(custm.var(), 850)
def test_happy_pass(self): print pb(self.params) self.assertEqual(sum(pb(self.params)[1]), 1)