private static ISet <ITestMethod> GetSelectedTestCases(IAffectedClassDiagram acd) { var selected = new HashSet <ITestMethod>(acd.Coverage.Where(entry => entry.Value.Any(acd.IsAffectedInvocation)).Select(e => e.Key)); selected.UnionWith(acd.Coverage.Where(entry => !entry.Key.WasSuccessful).Select(entry => entry.Key)); var prioritization = new PrioritizationTechnique(acd); selected.ToList().ForEach(test => test.Weight = prioritization.GetWeight(test)); return(selected); }
public PrioritizationTechnique(IAffectedClassDiagram acd) { _acd = acd; }