Example #1
0
        public void GetPostByIdTest()
        {
            var postServices = new PostServices(dbContext);
            var x            = postServices.GetPostById(1);

            Assert.NotNull(x);
        }
        public IHttpActionResult Get(int id)
        {
            PostServices postService = CreatePostServices();
            var          post        = postService.GetPostById(id);

            return(Ok(post));
        }
        public IHttpActionResult Get(int id)
        {
            PostServices noteService = CreatePostService();
            var          note        = noteService.GetPostById(id);

            return(Ok(note));
        }