diff --git a/Blog.DAL.Tests/RepositoryTests.cs b/Blog.DAL.Tests/RepositoryTests.cs index 1977165..aa9a5f9 100644 --- a/Blog.DAL.Tests/RepositoryTests.cs +++ b/Blog.DAL.Tests/RepositoryTests.cs @@ -45,51 +45,5 @@ namespace Blog.DAL.Tests // act Assert.Throws(() => { repository.add(new Post { Author = null, Content = "lorem ipsum" }); }); } - - [Test] - public void AddPost_TwoPostsInDb_ReturnThreePosts() - { - // arrange - var context = new BlogContext(); - context.Database.CreateIfNotExists(); - var repository = new BlogRepository(); - - // act - var post = repository.add(new Post { Id = 3, Author = "me", Content = "lorem ipsum" }); - var result = repository.GetAllPosts(); - - // assert - Assert.AreEqual(3, result.Count()); - } - - - [Test] - public void GetComments_TwoPostsInDbWithOneComment_ReturnValidCount() - { - // arrange - var context = new BlogContext(); - context.Database.CreateIfNotExists(); - var repository = new CommentRepository(); - - // assert - Assert.AreEqual(1, repository.GetAllCommentsOf(1).Count()); - Assert.AreEqual(0, repository.GetAllCommentsOf(2).Count()); - } - - - [Test] - public void AddComments_TwoPostsInDbWithOneComment_ReturnValidCount() - { - // arrange - var context = new BlogContext(); - context.Database.CreateIfNotExists(); - var repository = new CommentRepository(); - - repository.add(new Comment { PostId = 2, Author = "Test", Content = "Lorem ipsum" }); - - // assert - Assert.AreEqual(1, repository.GetAllCommentsOf(1).Count()); - Assert.AreEqual(1, repository.GetAllCommentsOf(2).Count()); - } } }