         expect(result).toEventuallyNot(beNil())
         expect(result?.error).toEventually(beNil())
     }
-//
-//    func testParsesTheTaskCreatedProperlyAddingANewTask() {
-//        _ = stubRequest("POST", "http://jsonplaceholder.typicode.com/todos")
-//            .andReturn(201)?
-//            .withBody(fromJsonFile("addTaskToUserResponse"))
-//
-//        var result: Result<TaskDTO, TODOAPIClientError>?
-//        apiClient.addTaskToUser("1", title: "delectus aut autem", completed: false) { response in
-//            result = response
-//        }
-//
-//        expect(result).toEventuallyNot(beNil())
-//        assertTaskContainsExpectedValues((result?.value)!)
-//    }
-//
-//    func testReturnsNetworkErrorIfThereIsNoConnectionAddingATask() {
-//        stubRequest("POST", "http://jsonplaceholder.typicode.com/todos")
-//            .andFailWithError(NSError.networkError())
-//
-//        var result: Result<TaskDTO, TODOAPIClientError>?
-//        apiClient.addTaskToUser("1", title: "delectus aut autem", completed: false) { response in
-//            result = response
-//        }
-//
-//        expect(result?.error).toEventually(equal(TODOAPIClientError.networkError))
-//    }
-//
-//    func testReturnsUnknowErrorIfThereIsAnyErrorAddingATask() {
-//        _ = stubRequest("POST", "http://jsonplaceholder.typicode.com/todos")
-//            .andReturn(418)
-//
-//        var result: Result<TaskDTO, TODOAPIClientError>?
-//        apiClient.addTaskToUser("1", title: "delectus aut autem", completed: false) { response in
-//            result = response
-//        }
-//
-//        expect(result?.error).toEventually(equal(TODOAPIClientError.unknownError(code: 418)))
-//    }
-//
-//    func testSendsTheRequestToTheCorrectPathDeletingATask() {
-//        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
-//            .andReturn(200)
-//
-//        var result: Result<Void, TODOAPIClientError>?
-//        apiClient.deleteTaskById("1") { response in
-//            result = response
-//        }
-//
-//        expect(result).toEventuallyNot(beNil())
-//        expect(result?.error).to(beNil())
-//    }
-//
-//    func testReturnsItemNotFoundIfThereIsNoTaskWithIdTheAssociateId() {
-//        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
-//            .andReturn(404)
-//
-//        var result: Result<Void, TODOAPIClientError>?
-//        apiClient.deleteTaskById("1") { response in
-//            result = response
-//        }
-//
-//        expect(result?.error).toEventually(equal(TODOAPIClientError.itemNotFound))
-//    }
-//
-//    func testReturnsNetworkErrorIfThereIsNoConnectionDeletingTask() {
-//        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
-//            .andFailWithError(NSError.networkError())
-//
-//        var result: Result<Void, TODOAPIClientError>?
-//        apiClient.deleteTaskById("1") { response in
-//            result = response
-//        }
-//
-//        expect(result?.error).toEventually(equal(TODOAPIClientError.networkError))
-//    }
-//
-//    func testReturnsUnknownErrorIfThereIsAnyErrorDeletingTask() {
-//        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
-//            .andReturn(418)
-//
-//        var result: Result<Void, TODOAPIClientError>?
-//        apiClient.deleteTaskById("1") { response in
-//            result = response
-//        }
-//
-//        expect(result?.error).toEventually(equal(TODOAPIClientError.unknownError(code: 418)))
-//    }
-//
+    //
+    //    func testParsesTheTaskCreatedProperlyAddingANewTask() {
+    //        _ = stubRequest("POST", "http://jsonplaceholder.typicode.com/todos")
+    //            .andReturn(201)?
+    //            .withBody(fromJsonFile("addTaskToUserResponse"))
+    //
+    //        var result: Result<TaskDTO, TODOAPIClientError>?
+    //        apiClient.addTaskToUser("1", title: "delectus aut autem", completed: false) { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result).toEventuallyNot(beNil())
+    //        assertTaskContainsExpectedValues((result?.value)!)
+    //    }
+    //
+    //    func testReturnsNetworkErrorIfThereIsNoConnectionAddingATask() {
+    //        stubRequest("POST", "http://jsonplaceholder.typicode.com/todos")
+    //            .andFailWithError(NSError.networkError())
+    //
+    //        var result: Result<TaskDTO, TODOAPIClientError>?
+    //        apiClient.addTaskToUser("1", title: "delectus aut autem", completed: false) { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result?.error).toEventually(equal(TODOAPIClientError.networkError))
+    //    }
+    //
+    //    func testReturnsUnknowErrorIfThereIsAnyErrorAddingATask() {
+    //        _ = stubRequest("POST", "http://jsonplaceholder.typicode.com/todos")
+    //            .andReturn(418)
+    //
+    //        var result: Result<TaskDTO, TODOAPIClientError>?
+    //        apiClient.addTaskToUser("1", title: "delectus aut autem", completed: false) { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result?.error).toEventually(equal(TODOAPIClientError.unknownError(code: 418)))
+    //    }
+    //
+    //    func testSendsTheRequestToTheCorrectPathDeletingATask() {
+    //        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
+    //            .andReturn(200)
+    //
+    //        var result: Result<Void, TODOAPIClientError>?
+    //        apiClient.deleteTaskById("1") { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result).toEventuallyNot(beNil())
+    //        expect(result?.error).to(beNil())
+    //    }
+    //
+    //    func testReturnsItemNotFoundIfThereIsNoTaskWithIdTheAssociateId() {
+    //        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
+    //            .andReturn(404)
+    //
+    //        var result: Result<Void, TODOAPIClientError>?
+    //        apiClient.deleteTaskById("1") { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result?.error).toEventually(equal(TODOAPIClientError.itemNotFound))
+    //    }
+    //
+    //    func testReturnsNetworkErrorIfThereIsNoConnectionDeletingTask() {
+    //        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
+    //            .andFailWithError(NSError.networkError())
+    //
+    //        var result: Result<Void, TODOAPIClientError>?
+    //        apiClient.deleteTaskById("1") { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result?.error).toEventually(equal(TODOAPIClientError.networkError))
+    //    }
+    //
+    //    func testReturnsUnknownErrorIfThereIsAnyErrorDeletingTask() {
+    //        _ = stubRequest("DELETE", "http://jsonplaceholder.typicode.com/todos/1")
+    //            .andReturn(418)
+    //
+    //        var result: Result<Void, TODOAPIClientError>?
+    //        apiClient.deleteTaskById("1") { response in
+    //            result = response
+    //        }
+    //
+    //        expect(result?.error).toEventually(equal(TODOAPIClientError.unknownError(code: 418)))
+    //    }
+    //
     func testSendsTheExpectedBodyUpdatingATask() {
         stub(condition: isMethodPUT() &&
             isHost("jsonplaceholder.typicode.com") &&


        expect(result?.error).toEventually(equal(TODOAPIClientError.unknownError(code: 418)))
    }
//
//    func testParsesTaskProperlyGettingTaskById() {
//        _ = stubRequest("GET", "http://jsonplaceholder.typicode.com/todos/1")
//            .andReturn(200)?
//            .withBody(fromJsonFile("getTaskByIdResponse"))
//
//        var result: Result<TaskDTO, TODOAPIClientError>?
//        apiClient.getTaskById("1") { response in
//            result = response
//        }
//
//        expect(result).toEventuallyNot(beNil())
//        assertTaskContainsExpectedValues((result?.value)!)
//    }
//
//    func testReturnsItemNotFoundErrorIfTheTaskIdDoesNotExist() {
//        _ = stubRequest("GET", "http://jsonplaceholder.typicode.com/todos/1")
//            .andReturn(404)
//
//        var result: Result<TaskDTO, TODOAPIClientError>?
//        apiClient.getTaskById("1") { response in
//            result = response
//        }
//
//        expect(result?.error).toEventually(equal(TODOAPIClientError.itemNotFound))
//    }
//
//    func testReturnsNetworkErrorIfThereIsNoConnectionGettingTaskById() {
//        _ = stubRequest("GET", "http://jsonplaceholder.typicode.com/todos/1")
//            .andFailWithError(NSError.networkError())
//
//        var result: Result<TaskDTO, TODOAPIClientError>?
//        apiClient.getTaskById("1") { response in
//            result = response
//        }
//
//        expect(result?.error).toEventually(equal(TODOAPIClientError.networkError))
//    }
//
//    func testReturnsUnknowErrorIfTheErrorIsNotHandledGettingTasksById() {
//        _ = stubRequest("GET", "http://jsonplaceholder.typicode.com/todos/1")
//            .andReturn(418)
//
//        var result: Result<TaskDTO, TODOAPIClientError>?
//        apiClient.getTaskById("1") { response in
//            result = response
//        }
//
//        expect(result?.error).toEventually(equal(TODOAPIClientError.unknownError(code: 418)))
//    }
//
    func testSendsTheCorrectBodyAddingANewTask() {
        stub(condition: isMethodPOST() &&
            isHost("jsonplaceholder.typicode.com") &&

                return fixture(filePath: "", status: 418, headers: ["Content-Type":"application/json"])
        }

        var result: Result<[TaskDTO], TODOAPIClientError>?
        apiClient.getAllTasks { response in
            result = response
