public void ReadModelRepositoryShouldUpdateAnItem() { var guid = Guid.NewGuid(); var item = new Test(guid) { Name = "Testitem" }; var itemUpdate = new Test(guid) { Name = "Testitem Update" }; var repository = new TestModelRepository(); repository.Add(item); repository.Update(itemUpdate); repository.GetById(guid).Name.Should().Be("Testitem Update"); }
public void ReadModelRepositoryShouldReturnNullIfNotItemFound() { var repository = new TestModelRepository(); repository.GetById(Guid.NewGuid()).Should().Be(null); }