def test_get_one_exceptions():
    """
    Test RessourceValue.one.
    """
    def values_source():
        return ["1st_obj", "2nd_obj"], ["1st_uriref", "2nd_uriref"]

    instance = LazyResourceLoader(values_source, MockResource(), "some_name")
    with pytest.raises(surf.exceptions.CardinalityException):
        instance.get_one()
def test_get_one_exceptions():
    """
    Test RessourceValue.one.
    """

    def values_source():
        return ["1st_obj", "2nd_obj"], ["1st_uriref", "2nd_uriref"]

    instance = LazyResourceLoader(values_source, MockResource(), "some_name")
    with pytest.raises(surf.exceptions.CardinalityException):
        instance.get_one()