protected override void SetContextData() { repo = new ApplicationsRepo(testCtx); var b = new Faker <Applications>() .RuleFor(r => r.ApplicationId, f => f.Random.Uuid()) .RuleFor(r => r.Description, f => f.Lorem.Sentence(5)) .RuleFor(r => r.LastUpdatedbyUser, f => f.Random.Uuid()) .RuleFor(r => r.ApplicationName, f => f.Lorem.Word()) .RuleFor(r => r.BannerEnable, f => f.Random.Bool()) .RuleFor(r => r.SupportEmail, f => f.Internet.ExampleEmail()); var bs = b.Generate(3).OrderBy(o => o.ApplicationId).ThenBy(o => o.SupportEmail).ToList(); FakeCollection.AddRange(bs); testCtx.Applications.AddRange(bs); int added = testCtx.SaveChanges(); }