public void TestGetTaskById() { int id = 1; var result = taskTest.GetTaskById(id); Assert.AreEqual("TestTask", result.Title); }
public IHttpActionResult GetTaskById(int TaskID) { var task = _bll.GetTaskById(TaskID); if (task == null) { return(BadRequest()); } return(Ok(task)); }