def test_required_with_value(x):
    """
    When required() is called with a none-None value, then it returns that
    value.
    """
    ret = mod.required(x)
    assert ret == x
def test_required_with_value(x):
    """
    When required() is called with a none-None value, then it returns that
    value.
    """
    ret = mod.required(x)
    assert ret == x
def test_required():
    """
    When required() is called with None, then it raises ValueError.
    """
    with pytest.raises(ValueError):
        mod.required(None)
def test_required():
    """
    When required() is called with None, then it raises ValueError.
    """
    with pytest.raises(ValueError):
        mod.required(None)