def test_std_range(self, x, y): o, p = x[0], x[1] y_0 = y[0] y_1 = y[1] z = rng(o, p) z_0 = z[0] z_1 = z[1] self.assertEqual(y_0, z_0) self.assertEqual((y_1.a, y_1.b), (z_1.a, z_1.b))
def choose(cls, l, h): return Gen.map( Gen.rand(), lambda stdgen: rng((l, h), stdgen)[0] )
def eval(cls, n, rnd, gn): size, rnd_1 = rng((0, n), rnd) return gn.gen(size, rnd_1)