def METHOD_NAME(db):
    attribute = Attribute.objects.get(uri='http://example.com/terms/domain/individual/single/text')
    validator = AttributeLockedValidator()
    validator.set_context(AttributeSerializer(instance=attribute))
    validator({
        'uri_prefix': attribute.uri_prefix,
        'key': attribute.key,
        'parent':  attribute.parent
    })