@@ -306,7 +306,7 @@ describe("captureException", () => {
306306 const result = captureException ( "string error" ) ;
307307
308308 expect ( result . message ) . toBe ( "string error" ) ;
309- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
309+ expect ( result . type ) . toBeUndefined ( ) ;
310310 expect ( result . stack ) . toBeUndefined ( ) ;
311311 expect ( result . frames ) . toBeUndefined ( ) ;
312312 } ) ;
@@ -315,35 +315,35 @@ describe("captureException", () => {
315315 const result = captureException ( 42 ) ;
316316
317317 expect ( result . message ) . toBe ( "42" ) ;
318- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
318+ expect ( result . type ) . toBeUndefined ( ) ;
319319 } ) ;
320320
321321 it ( "should handle boolean errors" , ( ) => {
322322 const result = captureException ( false ) ;
323323
324324 expect ( result . message ) . toBe ( "false" ) ;
325- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
325+ expect ( result . type ) . toBeUndefined ( ) ;
326326 } ) ;
327327
328328 it ( "should handle null" , ( ) => {
329329 const result = captureException ( null ) ;
330330
331331 expect ( result . message ) . toBe ( "null" ) ;
332- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
332+ expect ( result . type ) . toBeUndefined ( ) ;
333333 } ) ;
334334
335335 it ( "should handle undefined" , ( ) => {
336336 const result = captureException ( undefined ) ;
337337
338338 expect ( result . message ) . toBe ( "undefined" ) ;
339- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
339+ expect ( result . type ) . toBeUndefined ( ) ;
340340 } ) ;
341341
342342 it ( "should handle object errors" , ( ) => {
343343 const result = captureException ( { code : 404 , message : "Not found" } ) ;
344344
345345 expect ( result . message ) . toBe ( '{"code":404,"message":"Not found"}' ) ;
346- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
346+ expect ( result . type ) . toBeUndefined ( ) ;
347347 } ) ;
348348
349349 it ( "should handle objects with circular references" , ( ) => {
@@ -352,7 +352,7 @@ describe("captureException", () => {
352352
353353 const result = captureException ( obj ) ;
354354
355- expect ( result . type ) . toBe ( "UnknownErrorType" ) ;
355+ expect ( result . type ) . toBeUndefined ( ) ;
356356 // Should not throw, should return some string representation
357357 expect ( typeof result . message ) . toBe ( "string" ) ;
358358 } ) ;
0 commit comments