Skip to content

Commit 03ab919

Browse files
committed
Update to angular 1.0.7.
1 parent d14e616 commit 03ab919

File tree

4 files changed

+755
-502
lines changed

4 files changed

+755
-502
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Include the required libraries
2727
```html
2828
<script src="//maps.googleapis.com/maps/api/js?sensor=false"></script>
2929
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.0.2/jquery.min.js"></script>
30-
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.0.5/angular.min.js"></script>
30+
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.0.7/angular.min.js"></script>
3131
<script src="//dylanfprice.github.com/angular-gm/angular-gm-0.1.0.min.js"></script>
3232
```
3333

test/lib/angular/angular-mocks.js

Lines changed: 37 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* @license AngularJS v1.0.5
2+
* @license AngularJS v1.0.7
33
* (c) 2010-2012 Google, Inc. http://angularjs.org
44
* License: MIT
55
*
@@ -241,10 +241,10 @@ angular.mock.$ExceptionHandlerProvider = function() {
241241
*
242242
* @param {string} mode Mode of operation, defaults to `rethrow`.
243243
*
244-
* - `rethrow`: If any errors are are passed into the handler in tests, it typically
244+
* - `rethrow`: If any errors are passed into the handler in tests, it typically
245245
* means that there is a bug in the application or test, so this mock will
246246
* make these tests fail.
247-
* - `log`: Sometimes it is desirable to test that an error is throw, for this case the `log` mode stores an
247+
* - `log`: Sometimes it is desirable to test that an error is thrown, for this case the `log` mode stores an
248248
* array of errors in `$exceptionHandler.errors`, to allow later assertion of them.
249249
* See {@link ngMock.$log#assertEmpty assertEmpty()} and
250250
* {@link ngMock.$log#reset reset()}
@@ -322,7 +322,13 @@ angular.mock.$LogProvider = function() {
322322
* @propertyOf ngMock.$log
323323
*
324324
* @description
325-
* Array of logged messages.
325+
* Array of messages logged using {@link ngMock.$log#log}.
326+
*
327+
* @example
328+
* <pre>
329+
* $log.log('Some Log');
330+
* var first = $log.log.logs.unshift();
331+
* </pre>
326332
*/
327333
$log.log.logs = [];
328334
/**
@@ -331,7 +337,13 @@ angular.mock.$LogProvider = function() {
331337
* @propertyOf ngMock.$log
332338
*
333339
* @description
334-
* Array of logged messages.
340+
* Array of messages logged using {@link ngMock.$log#warn}.
341+
*
342+
* @example
343+
* <pre>
344+
* $log.warn('Some Warning');
345+
* var first = $log.warn.logs.unshift();
346+
* </pre>
335347
*/
336348
$log.warn.logs = [];
337349
/**
@@ -340,7 +352,13 @@ angular.mock.$LogProvider = function() {
340352
* @propertyOf ngMock.$log
341353
*
342354
* @description
343-
* Array of logged messages.
355+
* Array of messages logged using {@link ngMock.$log#info}.
356+
*
357+
* @example
358+
* <pre>
359+
* $log.info('Some Info');
360+
* var first = $log.info.logs.unshift();
361+
* </pre>
344362
*/
345363
$log.info.logs = [];
346364
/**
@@ -349,7 +367,13 @@ angular.mock.$LogProvider = function() {
349367
* @propertyOf ngMock.$log
350368
*
351369
* @description
352-
* Array of logged messages.
370+
* Array of messages logged using {@link ngMock.$log#error}.
371+
*
372+
* @example
373+
* <pre>
374+
* $log.log('Some Error');
375+
* var first = $log.error.logs.unshift();
376+
* </pre>
353377
*/
354378
$log.error.logs = [];
355379
};
@@ -430,7 +454,7 @@ angular.mock.$LogProvider = function() {
430454
*
431455
* *NOTE*: this is not an injectable instance, just a globally available mock class of `Date`.
432456
*
433-
* Mock of the Date type which has its timezone specified via constroctor arg.
457+
* Mock of the Date type which has its timezone specified via constructor arg.
434458
*
435459
* The main purpose is to create Date-like instances with timezone fixed to the specified timezone
436460
* offset, so that we can test code that depends on local timezone settings without dependency on
@@ -653,10 +677,10 @@ angular.mock.dump = function(object) {
653677
* @ngdoc object
654678
* @name ngMock.$httpBackend
655679
* @description
656-
* Fake HTTP backend implementation suitable for unit testing application that use the
680+
* Fake HTTP backend implementation suitable for unit testing applications that use the
657681
* {@link ng.$http $http service}.
658682
*
659-
* *Note*: For fake http backend implementation suitable for end-to-end testing or backend-less
683+
* *Note*: For fake HTTP backend implementation suitable for end-to-end testing or backend-less
660684
* development please see {@link ngMockE2E.$httpBackend e2e $httpBackend mock}.
661685
*
662686
* During unit testing, we want our unit tests to run quickly and have no external dependencies so
@@ -1653,7 +1677,7 @@ window.jasmine && (function(window) {
16531677
* @name angular.mock.module
16541678
* @description
16551679
*
1656-
* *NOTE*: This is function is also published on window for easy access.<br>
1680+
* *NOTE*: This function is also published on window for easy access.<br>
16571681
* *NOTE*: Only available with {@link http://pivotal.github.com/jasmine/ jasmine}.
16581682
*
16591683
* This function registers a module configuration code. It collects the configuration information
@@ -1687,7 +1711,7 @@ window.jasmine && (function(window) {
16871711
* @name angular.mock.inject
16881712
* @description
16891713
*
1690-
* *NOTE*: This is function is also published on window for easy access.<br>
1714+
* *NOTE*: This function is also published on window for easy access.<br>
16911715
* *NOTE*: Only available with {@link http://pivotal.github.com/jasmine/ jasmine}.
16921716
*
16931717
* The inject function wraps a function into an injectable function. The inject() creates new
@@ -1753,7 +1777,7 @@ window.jasmine && (function(window) {
17531777
try {
17541778
injector.invoke(blockFns[i] || angular.noop, this);
17551779
} catch (e) {
1756-
if(e.stack) e.stack += '\n' + errorForStack.stack;
1780+
if(e.stack && errorForStack) e.stack += '\n' + errorForStack.stack;
17571781
throw e;
17581782
} finally {
17591783
errorForStack = null;

0 commit comments

Comments
 (0)