def validate_resource(resource) -> None:
if resource is not None and not isinstance(resource, dict):<EOL><INDENT>raise ValidationError('<STR_LIT>')<EOL><DEDENT>if isinstance(resource, dict) and set(resource.keys()) <= {'<STR_LIT>', '<STR_LIT>'}:<EOL><INDENT>raise ValidationError(<EOL>'<STR_LIT>'.format(set(resource.keys())))<EOL><DEDENT>
Validates a resource