public void Delete_ShouldReturnSuccess()
        {
            var testDbPost = TestData.CreateDbSocialMediaPost("http://facebook.com/post/123", Guid.NewGuid());

            context.SocialMediaPost.Add(testDbPost);
            context.SaveChanges();

            var result = controller.DeleteSocialMediaPost(testDbPost.Id) as StatusCodeResult;

            result.Should().BeOfType <NoContentResult>();
            result.StatusCode.Should().Be(204);
        }
        public void Delete_ShouldReturnBadRequest()
        {
            var mockContext = new Mock <HubDbContext>(options);

            mockContext.Setup(m => m.SocialMediaPost).Throws(new Exception());
            var controller = new SocialMediaPostsController(mockContext.Object, logger.Object, mapper);

            var result = controller.DeleteSocialMediaPost(Guid.NewGuid()) as ObjectResult;

            result.Should().BeOfType <BadRequestObjectResult>();
            result.StatusCode.Should().Be(400);
        }