Beispiel #1
0
        public void OnPostVote(string id)
        {
            var interactor = new IncreaseVoteInteractor(_imageRepository);

            interactor.Handle(new IncreaseVoteRequestMessage {
                Id = id
            });
        }
Beispiel #2
0
        public void TestVotingServiceIncreaseVoteCount()
        {
            var increaseVoteInteractor = new IncreaseVoteInteractor(_imageRepository);

            increaseVoteInteractor.Handle(new IncreaseVoteRequestMessage {
                Id = _images[0].Id
            });
            Assert.Equal(1, _images[0].Votes);
        }