@@ -182,6 +182,14 @@ describe('ngMock', function() {
182
182
it ( 'should provide error method' , function ( ) {
183
183
expect ( function ( ) { $log . error ( '' ) ; } ) . not . toThrow ( ) ;
184
184
} ) ;
185
+
186
+ it ( 'should provide debug method' , function ( ) {
187
+ expect ( function ( ) { $log . error ( '' ) ; } ) . not . toThrow ( ) ;
188
+ } ) ;
189
+
190
+ it ( 'should provide debugEnabled method' , function ( ) {
191
+ expect ( function ( ) { $log . debugEnabled ( true ) ; } ) . not . toThrow ( ) ;
192
+ } ) ;
185
193
186
194
it ( 'should store log messages' , function ( ) {
187
195
$log . log ( 'fake log' ) ;
@@ -202,13 +210,19 @@ describe('ngMock', function() {
202
210
$log . error ( 'fake log' ) ;
203
211
expect ( $log . error . logs ) . toContain ( [ 'fake log' ] ) ;
204
212
} ) ;
213
+
214
+ it ( 'should store error messages' , function ( ) {
215
+ $log . error ( 'fake log' ) ;
216
+ expect ( $log . debug . logs ) . toContain ( [ 'fake log' ] ) ;
217
+ } ) ;
205
218
206
219
it ( 'should assertEmpty' , function ( ) {
207
220
try {
208
221
$log . error ( Error ( 'MyError' ) ) ;
209
222
$log . warn ( Error ( 'MyWarn' ) ) ;
210
223
$log . info ( Error ( 'MyInfo' ) ) ;
211
224
$log . log ( Error ( 'MyLog' ) ) ;
225
+ $log . debug ( Error ( 'MyDebug' ) ) ;
212
226
$log . assertEmpty ( ) ;
213
227
} catch ( error ) {
214
228
error = error . message || error ;
@@ -226,6 +240,7 @@ describe('ngMock', function() {
226
240
$log . warn ( Error ( 'MyWarn' ) ) ;
227
241
$log . info ( Error ( 'MyInfo' ) ) ;
228
242
$log . log ( Error ( 'MyLog' ) ) ;
243
+ $log . debug ( Error ( 'MyDebug' ) ) ;
229
244
$log . reset ( ) ;
230
245
var passed = false ;
231
246
try {
0 commit comments