예제 #1
0
def test_int_contains_no_upper_bound():
    space = Scalar(min=0, max=None, dtype=int)
    assert space.contains(0)
    assert not space.contains(-1)
    assert space.contains(1000)
예제 #2
0
def test_int_contains():
    space = Scalar(min=-10, max=10, dtype=int)
    assert space.contains(-10)
    assert not space.contains(-11)
    assert not space.contains(0.5)