public DependencyValidationResult Validate() { var result = new DependencyValidationResult(); _dependencies.Each(x => { if (x.IsFixed() && x.Version.IsEmpty()) { result.AddProblem(x.Name, "The dependency's update mode is set to 'Fixed' but no version is specified (xml attributes are case sensitive)."); } }); _dependencies .GroupBy(x => x.Name.ToLower()) .Where(x => x.Count() > 1) .Each(x => result.AddProblem(x.Key, "Dependencies must be unique")); return(result); }
public void Import(DependencyValidationResult result) { result.Problems.Each(AddProblem); }