public void ApiTagsController_Suggestions() { //Arrange var tagsRepo = new FakeRepository <Tag>(e => e.TagID); tagsRepo.Create(new Tag() { TagID = 1, TagLabel = "testing" }); //Act var controller = new TagsController(tagsRepo); var result = controller.Suggestions("test") as IEnumerable <TagApi>; //Assert Assert.IsNotNull(result); Assert.IsNotNull(result.ToList()); Assert.IsTrue(result.ToList().Count() > 0); }