diff options
| author | Igor Minar | 2011-09-02 15:53:26 -0700 | 
|---|---|---|
| committer | Igor Minar | 2011-09-02 17:10:25 -0700 | 
| commit | 5703984d4df214a492322ec83e805ebc2c4ea8c9 (patch) | |
| tree | 60e03c27bdab2f0ff9a0e6498f0d8948e753721a /src/service | |
| parent | ea8952177e31e0cebc77e0a9dd6b58104f3928c3 (diff) | |
| download | angular.js-5703984d4df214a492322ec83e805ebc2c4ea8c9.tar.bz2 | |
test(jsonp): fixing jsonp e2e tests
- buzz api keeps on throttling our requests which makes our build fail
  so I'm disabling the buzz demo e2e test
- the $xhr service jsonp test was modified to use jsonp on angularjs.org
  instead of buzz api for the same reason as mentioned above
Diffstat (limited to 'src/service')
| -rw-r--r-- | src/service/xhr.js | 10 | 
1 files changed, 5 insertions, 5 deletions
| diff --git a/src/service/xhr.js b/src/service/xhr.js index 6bff6f04..f7f12b6b 100644 --- a/src/service/xhr.js +++ b/src/service/xhr.js @@ -145,8 +145,8 @@           <input type="text" name="url" value="index.html" size="80"/>           <button ng:click="fetch()">fetch</button><br>           <button ng:click="updateModel('GET', 'index.html')">Sample GET</button> -         <button ng:click="updateModel('JSON', 'https://www.googleapis.com/buzz/v1/activities/googlebuzz/@self?alt=json&callback=JSON_CALLBACK')">Sample JSONP (Buzz API)</button> -         <button ng:click="updateModel('JSON', 'https://www.invalid_JSONP_request.com&callback=JSON_CALLBACK')">Invalid JSONP</button> +         <button ng:click="updateModel('JSON', 'http://angularjs.org/greet.php?callback=JSON_CALLBACK&name=Super%20Hero')">Sample JSONP</button> +         <button ng:click="updateModel('JSON', 'http://angularjs.org/doesntexist&callback=JSON_CALLBACK')">Invalid JSONP</button>           <pre>code={{code}}</pre>           <pre>response={{response}}</pre>         </div> @@ -159,11 +159,11 @@           expect(binding('response')).toMatch(/angularjs.org/);         }); -       it('should make JSONP request to the Buzz API', function() { -         element(':button:contains("Buzz API")').click(); +       it('should make JSONP request to the angularjs.org', function() { +         element(':button:contains("Sample JSONP")').click();           element(':button:contains("fetch")').click();           expect(binding('code')).toBe('code=200'); -         expect(binding('response')).toMatch(/buzz-feed/); +         expect(binding('response')).toMatch(/Super Hero!/);         });         it('should make JSONP request to invalid URL and invoke the error handler', | 
