diff options
| author | Vojta Jina | 2011-08-10 15:59:55 +0200 |
|---|---|---|
| committer | Igor Minar | 2011-11-30 11:03:41 -0500 |
| commit | 45f47ff6cd264dcd347e6df92c9ef39b0ae8aaba (patch) | |
| tree | 3b18d13dca703ee7ce21f11729ff3db31a55cfb9 /test | |
| parent | 0c8b35681e2ea9ce3ee6a188476f89be1336f1cb (diff) | |
| download | angular.js-45f47ff6cd264dcd347e6df92c9ef39b0ae8aaba.tar.bz2 | |
fix($browser.xhr): change method "JSON" to "JSONP"
Breaks "JSON" xhr method is now called "JSONP"
Diffstat (limited to 'test')
| -rw-r--r-- | test/service/browserSpecs.js | 10 |
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(); |
