From 49bfe6ab74229ba4da5342382b87dcd6fca239fa Mon Sep 17 00:00:00 2001 From: Azul Date: Mon, 19 Nov 2012 15:58:46 +0100 Subject: works - but not quite what i want. Exposing jqXHR to error function --- spec/helper.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'spec/helper.js') diff --git a/spec/helper.js b/spec/helper.js index 11327af..8bae2c6 100644 --- a/spec/helper.js +++ b/spec/helper.js @@ -30,11 +30,11 @@ var specHelper = (function() { request.respond(200, header, body); } - function respondJSON(object) { + function respondJSON(object, responseCode) { var request = this.requests.pop(); header = { "Content-Type": "application/json;charset=utf-8" }; body = JSON.stringify(object); - request.respond(200, header, body); + request.respond(responseCode || 200, header, body); } return { -- cgit v1.2.3