@@ -480,7 +480,7 @@ bool IsCrashReport(object payload)
480480 [ SkippableTheory ]
481481 [ InlineData ( true ) ]
482482 [ InlineData ( false ) ]
483- public async Task IgnoreNonDatadogCrashes ( bool mainThread )
483+ public async Task OptionallyDoNotReportNonDatadogCrashes ( bool mainThread )
484484 {
485485 SkipOn . Platform ( SkipOn . PlatformValue . MacOs ) ;
486486 SkipOn . PlatformAndArchitecture ( SkipOn . PlatformValue . Windows , SkipOn . ArchitectureValue . X86 ) ;
@@ -492,7 +492,7 @@ public async Task IgnoreNonDatadogCrashes(bool mainThread)
492492 using var helper = await StartConsoleWithArgs (
493493 arg ,
494494 enableProfiler : true ,
495- [ LdPreloadConfig , CrashReportConfig ( reportFile ) ] ) ;
495+ [ LdPreloadConfig , CrashReportConfig ( reportFile ) , ( "DD_CRASHTRACKING_FILTERING_ENABLED" , "1" ) ] ) ;
496496
497497 await helper . Task ;
498498
@@ -507,11 +507,8 @@ public async Task IgnoreNonDatadogCrashes(bool mainThread)
507507 }
508508
509509 [ SkippableFact ]
510- public async Task OptionallyReportNonDatadogCrashes ( )
510+ public async Task ReportNonDatadogCrashes ( )
511511 {
512- // This test only validates the case where DD_CRASHTRACKING_FILTERING_ENABLED is set to 0
513- // The default case is tested by IgnoreNonDatadogCrashes
514-
515512 SkipOn . Platform ( SkipOn . PlatformValue . MacOs ) ;
516513 SkipOn . PlatformAndArchitecture ( SkipOn . PlatformValue . Windows , SkipOn . ArchitectureValue . X86 ) ;
517514
@@ -532,6 +529,29 @@ public async Task OptionallyReportNonDatadogCrashes()
532529 File . Exists ( reportFile . Path ) . Should ( ) . BeTrue ( ) ;
533530 }
534531
532+ [ SkippableFact ]
533+ public async Task MakeSureNonDatadogCrashesAreReportedByDefault ( )
534+ {
535+ SkipOn . Platform ( SkipOn . PlatformValue . MacOs ) ;
536+ SkipOn . PlatformAndArchitecture ( SkipOn . PlatformValue . Windows , SkipOn . ArchitectureValue . X86 ) ;
537+
538+ using var reportFile = new TemporaryFile ( ) ;
539+
540+ using var helper = await StartConsoleWithArgs (
541+ "crash" ,
542+ enableProfiler : true ,
543+ [ LdPreloadConfig , CrashReportConfig ( reportFile ) ] ) ;
544+
545+ await helper . Task ;
546+
547+ if ( RuntimeInformation . IsOSPlatform ( OSPlatform . Linux ) )
548+ {
549+ helper . StandardOutput . Should ( ) . Contain ( CrashReportUnfilteredExpectedOutput ) ;
550+ }
551+
552+ File . Exists ( reportFile . Path ) . Should ( ) . BeTrue ( ) ;
553+ }
554+
535555 [ SkippableFact ]
536556 public async Task ReportedStacktrace ( )
537557 {
0 commit comments