validateSchema function
Validates a schema
Implementation
List<ValidationError> validateSchema(
ast.Node schema,
) {
final validator = _Validator(
rules: {
ValidationRule.uniqueDirectiveNames,
ValidationRule.uniqueFieldDefinitionNames,
ValidationRule.uniqueEnumValueNames,
ValidationRule.loneSchemaDefinition,
ValidationRule.uniqueOperationTypes,
ValidationRule.uniqueTypeNames,
ValidationRule.uniqueArgumentNames
},
);
return validator.validate(
node: schema,
);
}