public void ErrorTelemetryEventsAreGeneratedOnAsyncExceptionAndIEDIF_False() { TestTelemetryChannel.Clear(); var host = new HostingContext <AsyncService, IAsyncService>() .ShouldWaitForCompletion(); using (host) { host.Open(); IAsyncService client = host.GetChannel(); try { client.FailWithExceptionAsync().Wait(); } catch { } } var errors = from item in TestTelemetryChannel.CollectedData() where item is ExceptionTelemetry select item; Assert.IsTrue(errors.Count() > 0); }