public void should_throw_exception_if_userId_not_provided() { var cmd = new SetArtistBioVisibility { IsVisible = true }; Assert.That(() => Repository.Execute(cmd), Throws.TypeOf <DomainException>().With.Message.EqualTo("userId is required")); }
public void should_throw_exception_if_bio_not_found() { var cmd = new SetArtistBioVisibility { UserId = "fake", IsVisible = true }; Assert.That(() => Repository.Execute(cmd), Throws.TypeOf <DomainException>().With.Message.EqualTo("Artist bio for user 'fake' could not be found")); }