         
         override class func responseBodyParser() -> ResponseBodyParser {
             return .JSON(readingOptions: nil)
+        }
+
+        override class func responseErrorFromObject(object: AnyObject) -> NSError {
+            return NSError(domain: "MockAPIErrorDomain", code: 10000, userInfo: nil)
         }
         
         class Endpoint {

                
            case .Failure(let box):
                let error = box.unbox
                assertEqual(error.domain, APIKitErrorDomain)
                assertEqual(error.code, 400)
            }
            
            expectation.fulfill()

        OHHTTPStubs.stubRequestsPassingTest({ request in
            return true
        }, withStubResponse: { request in
            let data = NSJSONSerialization.dataWithJSONObject([:], options: nil, error: nil)!
            return OHHTTPStubsResponse(data: data, statusCode: 400, headers: nil)
        })
        
        let expectation = expectationWithDescription("wait for response")
