public void GetRecruits_ShouldRetrieveEquivilentPoolOfRecruits() { //arrange var expectedRecruits = new List <Recruit> { new Recruit { Id = Guid.NewGuid(), LastName = "Harrison", FirstName = "Steven" }, new Recruit { Id = Guid.NewGuid(), LastName = "Barker", FirstName = "Bob" } }; var mockRecruitPool = new Mock <IRecruitPool>(); mockRecruitPool.Setup(rp => rp.GetNewRecruits()) .Returns(expectedRecruits); IRecruitPool recruitPool = mockRecruitPool.Object; var recruiterManager = new RecruiterManager(recruitPool); //act List <Recruit> recruits = recruiterManager.GetNewRecruits(); //assert expectedRecruits.Should().BeEquivalentTo(recruits); }
public void GetRecruits_ShouldRetrievePoolOfRecruits() { //arrange var mockRecruitPool = new Mock <IRecruitPool>(); var recruiterManager = new RecruiterManager(mockRecruitPool.Object); //act List <Recruit> recruits = recruiterManager.GetNewRecruits(); //assert Assert.IsNotNull(recruits); }