Skip to content

Commit bcc7089

Browse files
fredsapkozlowski-opensource
authored andcommitted
docs(mocks): update src/ngMock/angular-mocks.js documentation
Clarify how to use `$exceptionHandlerProvider.mode('log')` in tests
1 parent d43cc3f commit bcc7089

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/ngMock/angular-mocks.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
/**
32
* @license AngularJS v"NG_VERSION_FULL"
43
* (c) 2010-2012 Google, Inc. http://angularjs.org
@@ -221,8 +220,8 @@ angular.mock.$ExceptionHandlerProvider = function() {
221220
* - `rethrow`: If any errors are are passed into the handler in tests, it typically
222221
* means that there is a bug in the application or test, so this mock will
223222
* make these tests fail.
224-
* - `log`: Sometimes it is desirable to test that an error is throw, for this case the `log` mode stores the
225-
* error and allows later assertion of it.
223+
* - `log`: Sometimes it is desirable to test that an error is throw, for this case the `log` mode stores an
224+
* array of errors in `$exceptionHandler.errors`, to allow later assertion of them.
226225
* See {@link ngMock.$log#assertEmpty assertEmpty()} and
227226
* {@link ngMock.$log#reset reset()}
228227
*/

0 commit comments

Comments
 (0)