Esempio n. 1
0
        private IEnumerable <Standard> GetExpected(Table table)
        {
            var testRoutes = DbUtilities.GetTestRoutes();
            var standards  = new List <Standard>();

            foreach (var row in table.Rows)
            {
                standards.Add(DbUtilities.GetAllTestStandards().Single(standard =>
                                                                       standard.Title == row["title"] &&
                                                                       standard.RouteCode == testRoutes.Single(sector => sector.Name == row["route"]).Id&&
                                                                       standard.Level == int.Parse(row["level"]) &&
                                                                       standard.Version == decimal.Parse(row["version"]) &&
                                                                       standard.Status == row["status"]));
            }

            return(standards);
        }