public void Can_Create_Song() { var expectedId = 2; var expectedModel = new Song(); repo.GetByID(expectedId).Returns(expectedModel); var result = underTest.Details(expectedId); var model = (Song)result.Model; Assert.Equal(expectedModel, model); }
public ViewResult Details(int id) { var model = songRepo.GetByID(id); return(View(model)); }