File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed
Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -1444,17 +1444,14 @@ describe('cancelling requests', function() {
14441444
14451445 var creditCard = CreditCard . get ( ) ;
14461446 expect ( creditCard . $cancelRequest ) . toBeDefined ( ) ;
1447+ expect ( httpSpy . calls [ 0 ] . args [ 0 ] . timeout ) . toEqual ( jasmine . any ( $q ) ) ;
14471448 expect ( httpSpy . calls [ 0 ] . args [ 0 ] . timeout . then ) . toBeDefined ( ) ;
14481449
1449- // $httpBackend.flush();
1450-
1451- // expect(httpSpy).toHaveBeenCalledOnce();
1452- // expect(httpSpy.calls[0].args[0].timeout).toBe(jasmine.any());
1453- // expect($log.debug).toHaveBeenCalledOnceWith('ngResource:\n' +
1454- // ' Only numeric values are allowed as `timeout`.\n' +
1455- // ' Promises are not supported in $resource, because the same value has to ' +
1456- // 'be re-used for multiple requests. If you are looking for a way to cancel ' +
1457- // 'requests, you should use the `cancellable` option.');
1450+ expect ( $log . debug ) . toHaveBeenCalledOnceWith ( 'ngResource:\n' +
1451+ ' Only numeric values are allowed as `timeout`.\n' +
1452+ ' Promises are not supported in $resource, because the same value would ' +
1453+ 'be used for multiple requests. If you are looking for a way to cancel ' +
1454+ 'requests, you should use the `cancellable` option.' ) ;
14581455 } )
14591456 ) ;
14601457
You can’t perform that action at this time.
0 commit comments