aboutsummaryrefslogtreecommitdiffstats
path: root/test/service/xhr.bulkSpec.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/service/xhr.bulkSpec.js')
-rw-r--r--test/service/xhr.bulkSpec.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/test/service/xhr.bulkSpec.js b/test/service/xhr.bulkSpec.js
index adcb61fa..c278fa50 100644
--- a/test/service/xhr.bulkSpec.js
+++ b/test/service/xhr.bulkSpec.js
@@ -18,8 +18,9 @@ describe('$xhr.bulk', function() {
});
- function callback(code, response) {
+ function callback(code, response, responseHeaders) {
expect(code).toEqual(200);
+ expect(responseHeaders()).toEqual({});
log = log + toJson(response) + ';';
}
@@ -81,6 +82,8 @@ describe('$xhr.bulk', function() {
$browserXhr.flush();
expect($xhrError).not.toHaveBeenCalled();
- expect(callback).toHaveBeenCalledWith(404, 'NotFound');
+ expect(callback.mostRecentCall.args[0]).toEqual(404);
+ expect(callback.mostRecentCall.args[1]).toEqual('NotFound');
+ expect(callback.mostRecentCall.args[2]()).toEqual({});
});
});