1 write to Collector
Microsoft.Extensions.Diagnostics.Testing (1)
160 references to Collector
Aspire.Hosting.Tests (13)
Microsoft.AspNetCore.HeaderParsing.Tests (3)
Microsoft.Extensions.Diagnostics.HealthChecks.Common.Tests (1)
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (6)
Microsoft.Extensions.Diagnostics.Testing (3)
Microsoft.Extensions.Diagnostics.Testing.Tests (18)
Microsoft.Extensions.Hosting.Testing.Tests (1)
Microsoft.Extensions.Http.Diagnostics.Tests (12)
Microsoft.Extensions.Telemetry.Tests (7)
Microsoft.Gen.Logging.Generated.Tests (96)
LogPropertiesTests.cs (34)
43Assert.Equal(1, _logger.Collector.Count);
228Assert.Equal(1, _logger.Collector.Count);
229Assert.Equal(LogLevel.Debug, _logger.Collector.LatestRecord.Level);
293_logger.Collector.LatestRecord.StructuredState.Should().NotBeNull().And.Equal(expectedState);
301Assert.Equal(1, _logger.Collector.Count);
302Assert.Equal(LogLevel.Information, _logger.Collector.LatestRecord.Level);
303Assert.Equal($"Both {StringProperty} and {classToLog} as params", _logger.Collector.LatestRecord.Message);
313_logger.Collector.LatestRecord.StructuredState.Should().NotBeNull().And.Equal(expectedState);
322Assert.Equal(1, _logger.Collector.Count);
323Assert.Equal(LogLevel.Information, _logger.Collector.LatestRecord.Level);
324Assert.Equal($"Testing nullable property within class here...", _logger.Collector.LatestRecord.Message);
333_logger.Collector.LatestRecord.StructuredState.Should().NotBeNull().And.Equal(expectedState);
342Assert.Equal(1, _logger.Collector.Count);
343Assert.Equal(LogLevel.Information, _logger.Collector.LatestRecord.Level);
344Assert.Equal($"Testing nullable property within class here...", _logger.Collector.LatestRecord.Message);
352_logger.Collector.LatestRecord.StructuredState.Should().NotBeNull().And.Equal(expectedState);
363Assert.Equal(1, _logger.Collector.Count);
364var latestRecord = _logger.Collector.LatestRecord;
387Assert.Equal(1, _logger.Collector.Count);
388var latestRecord = _logger.Collector.LatestRecord;
417Assert.Equal(1, _logger.Collector.Count);
418var latestRecord = _logger.Collector.LatestRecord;
445Assert.Equal(1, _logger.Collector.Count);
447var latestRecord = _logger.Collector.LatestRecord;
470Assert.Equal(1, _logger.Collector.Count);
471var latestRecord = _logger.Collector.LatestRecord;
497Assert.Equal(1, _logger.Collector.Count);
498var latestRecord = _logger.Collector.LatestRecord;
521Assert.Equal(1, _logger.Collector.Count);
522var latestRecord = _logger.Collector.LatestRecord;
546Assert.Equal(1, _logger.Collector.Count);
547var latestRecord = _logger.Collector.LatestRecord;
572Assert.Equal(1, _logger.Collector.Count);
573var latestRecord = _logger.Collector.LatestRecord;
TagProviderTests.cs (39)
31Assert.Equal(1, _logger.Collector.Count);
33var latestRecord = _logger.Collector.LatestRecord;
55Assert.Equal(1, _logger.Collector.Count);
56var latestRecord = _logger.Collector.LatestRecord;
80Assert.Equal(1, _logger.Collector.Count);
81var latestRecord = _logger.Collector.LatestRecord;
103Assert.Equal(1, _logger.Collector.Count);
104var latestRecord = _logger.Collector.LatestRecord;
124Assert.Equal(1, _logger.Collector.Count);
125var latestRecord = _logger.Collector.LatestRecord;
132_logger.Collector.Clear();
135Assert.Equal(1, _logger.Collector.Count);
136latestRecord = _logger.Collector.LatestRecord;
161Assert.Equal(1, _logger.Collector.Count);
162var latestRecord = _logger.Collector.LatestRecord;
185Assert.Equal(1, _logger.Collector.Count);
186var latestRecord = _logger.Collector.LatestRecord;
205Assert.Equal(1, _logger.Collector.Count);
207var latestRecord = _logger.Collector.LatestRecord;
225Assert.Equal(1, _logger.Collector.Count);
226var latestRecord = _logger.Collector.LatestRecord;
245Assert.Equal(1, _logger.Collector.Count);
246var latestRecord = _logger.Collector.LatestRecord;
267Assert.Equal(1, _logger.Collector.Count);
268var latestRecord = _logger.Collector.LatestRecord;
288Assert.Equal(1, _logger.Collector.Count);
289var latestRecord = _logger.Collector.LatestRecord;
309Assert.Equal(1, _logger.Collector.Count);
310var latestRecord = _logger.Collector.LatestRecord;
329Assert.Equal(1, _logger.Collector.Count);
330var latestRecord = _logger.Collector.LatestRecord;
356Assert.Equal(1, _logger.Collector.Count);
357var latestRecord = _logger.Collector.LatestRecord;
378Assert.Equal(2, _logger.Collector.Count);
381_logger.Collector.LatestRecord.StructuredState.Should().NotBeNull().And.Equal(expectedState);
393Assert.Equal(1, _logger.Collector.Count);
395var latestRecord = _logger.Collector.LatestRecord;
418Assert.Equal(1, _logger.Collector.Count);
420var latestRecord = _logger.Collector.LatestRecord;