public void EditingExistingPostWithValidDataShouldChangePostAttributes()
        {
            // Arrange
            int postId = 1;
            string title = "testMoq";
            string content = "testMoq";
            string loggedUserId = "aaa";

            var editPostViewMock = new Mock<IEditPostView>();
            editPostViewMock.Setup(v => v.AuthorId).Returns(loggedUserId);

            var fakeEditPostPresenter = new EditPostPresenter(editPostViewMock.Object, this.mocksContainer.DataMock.Object);

            // Act
            fakeEditPostPresenter.EditPost(postId,loggedUserId, title, content);

            // Assert
            Assert.AreEqual(title, this.mocksContainer.PostsRepoMock.Object.Find(postId).Title);
        }
 protected EditPost()
 {
     this.presenter = new EditPostPresenter(this);
 }
        public void EditingExistingPostWithInvalidDataShouldThrowException()
        {
            // Arrange
            int postId = 1;
            string title = "";
            string content = "";
            string loggedUserId = "aaa";

            var editPostViewMock = new Mock<IEditPostView>();
            editPostViewMock.Setup(v => v.AuthorId).Returns(loggedUserId);

            var fakeEditPostPresenter = new EditPostPresenter(editPostViewMock.Object, this.mocksContainer.DataMock.Object);

            // Act
            fakeEditPostPresenter.EditPost(postId,loggedUserId, title, content);
        }