fix null warnings

This commit is contained in:
Oliver Kieselbach
2026-07-25 00:17:31 +02:00
parent 7f7b590db4
commit e0b6ce83cf
@@ -75,8 +75,10 @@ public class IngestOnDemandDiagnosticsTests
public void NullEventOrData_IsNotAConfirmation()
{
Assert.False(EventIngestProcessor.IsOnDemandDiagnosticsUploadConfirmation(null));
// Data is non-nullable on the model but the JSON deserializer can still hand us null
// for a payload without "data" — null! pins the guard the predicate actually has.
Assert.False(EventIngestProcessor.IsOnDemandDiagnosticsUploadConfirmation(
new EnrollmentEvent { EventType = "server_action_executed", Data = null }));
new EnrollmentEvent { EventType = "server_action_executed", Data = null! }));
}
// -------- InferDiagnosticsDestination --------