(self)
| 323 | "message:\n\n%s" % str(e)) |
| 324 | |
| 325 | def test_in_bounds_fuzz(self): |
| 326 | # Don't use fixed seed |
| 327 | random.seed() |
| 328 | |
| 329 | for dt in self.itype[1:]: |
| 330 | for ubnd in [4, 8, 16]: |
| 331 | vals = self.rfunc(2, ubnd, size=2**16, dtype=dt) |
| 332 | assert_(vals.max() < ubnd) |
| 333 | assert_(vals.min() >= 2) |
| 334 | |
| 335 | vals = self.rfunc(0, 2, size=2**16, dtype=np.bool_) |
| 336 | |
| 337 | assert_(vals.max() < 2) |
| 338 | assert_(vals.min() >= 0) |
| 339 | |
| 340 | def test_repeatability(self): |
| 341 | # We use a sha256 hash of generated sequences of 1000 samples |