private Project CreateProject() { var project = new Project { Active = true, Name = "TestProject" }; ctx.Projects.Add(project); ctx.SaveChanges(); return project; }
private static IEnumerable<Defect> MockDefectsData() { var mockProject = new Project { Name = "Tech Throwdown Test Project" }; var mockUser = new User { Username = "******" }; var mockSeverity = new Severity { SeverityDescription = "No Worries" }; var mockDefects = new List<Defect> { new Defect { Project = mockProject, Summary = "Test defect summary 1", StepsToReproduce = "Test steps to reproduce 1", CreatorUser = mockUser, AssignedToUser = mockUser, Severity = mockSeverity }, new Defect { Project = mockProject, Summary = "This is a test defect summary 3", StepsToReproduce = "Test steps to reproduce 3", CreatorUser = mockUser, AssignedToUser = mockUser, Severity = mockSeverity } }; return mockDefects; }