             // Then
             XCTFail("Should not trigger the success")
         }).failure({ response in
+            XCTAssertEqual(response.statusCode, statusCode)
             failureExpectation.fulfill()
-            XCTAssertEqual(response.statusCode, statusCode)
         }).completion({
             completionExpectation.fulfill()
         }).send()

        let errorExpectation = self.expectation(description: "Error response triggered")
        let completionExpectation = self.expectation(description: "Completion triggered")
        
        dispatcher.make(request).deserialize(to: MockCodable2.self).success({ response in
            // Then
            XCTFail("Should not trigger the success")
        }).failure({ response in

        
        dispatcher.make(request).deserialize(to: MockCodable.self).success({ response in
            // Then
            XCTAssertEqual(response.statusCode, StatusCode.ok)
            XCTAssertEqual(response.data, responseObject)
            successExpectation.fulfill()
        }).failure({ response in
            XCTFail("Should not trigger the failure")
        }).completion({
