aboutsummaryrefslogtreecommitdiffstats
path: root/test/service/browserSpecs.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/service/browserSpecs.js')
-rw-r--r--test/service/browserSpecs.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/service/browserSpecs.js b/test/service/browserSpecs.js
index 7e50a280..41f17f2a 100644
--- a/test/service/browserSpecs.js
+++ b/test/service/browserSpecs.js
@@ -111,7 +111,7 @@ describe('browser', function() {
});
describe('xhr', function() {
- describe('JSON', function() {
+ describe('JSONP', function() {
var log;
function callback(code, data) {
@@ -129,7 +129,7 @@ describe('browser', function() {
it('should add script tag for JSONP request', function() {
var notify = jasmine.createSpy('notify');
- browser.xhr('JSON', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
+ browser.xhr('JSONP', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
browser.notifyWhenNoOutstandingRequests(notify);
expect(notify).not.toHaveBeenCalled();
expect(scripts.length).toEqual(1);
@@ -148,7 +148,7 @@ describe('browser', function() {
it('should call callback when script fails to load', function() {
- browser.xhr('JSON', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
+ browser.xhr('JSONP', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
var script = scripts[0];
expect(typeof script.onload).toBe('function');
expect(typeof script.onerror).toBe('function');
@@ -160,7 +160,7 @@ describe('browser', function() {
it('should update the outstandingRequests counter for successful requests', function() {
var notify = jasmine.createSpy('notify');
- browser.xhr('JSON', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
+ browser.xhr('JSONP', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
browser.notifyWhenNoOutstandingRequests(notify);
expect(notify).not.toHaveBeenCalled();
@@ -175,7 +175,7 @@ describe('browser', function() {
it('should update the outstandingRequests counter for failed requests', function() {
var notify = jasmine.createSpy('notify');
- browser.xhr('JSON', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
+ browser.xhr('JSONP', 'http://example.org/path?cb=JSON_CALLBACK', null, callback);
browser.notifyWhenNoOutstandingRequests(notify);
expect(notify).not.toHaveBeenCalled();