65 references to GetSnapshot
Aspire.Hosting.Containers.Tests (1)
WithDockerfileTests.cs (1)
79var logs = collector.GetSnapshot();
Aspire.Hosting.Testing.Tests (1)
ResourceLoggerForwarderServiceTests.cs (1)
113var hostLogs = fakeLoggerProvider.Collector.GetSnapshot();
Aspire.Hosting.Tests (9)
Codespaces\CodespacesUrlRewriterTests.cs (1)
43var logs = collector.GetSnapshot();
HealthCheckTests.cs (1)
125var logs = collector.GetSnapshot();
ResourceNotificationTests.cs (7)
304var logs = logger.Collector.GetSnapshot(); 315logs = logger.Collector.GetSnapshot(); 325logs = logger.Collector.GetSnapshot(); 335logs = logger.Collector.GetSnapshot(); 345logs = logger.Collector.GetSnapshot(); 355logs = logger.Collector.GetSnapshot(); 375var logs = logger.Collector.GetSnapshot();
Aspire.Playground.Tests (1)
Infrastructure\DistributedApplicationExtensions.cs (1)
115var logs = logCollector.GetSnapshot();
Microsoft.AspNetCore.Diagnostics.Middleware.Tests (6)
Logging\AcceptanceTests.cs (6)
303var logRecords = logCollector.GetSnapshot(); 484var logRecords = logCollector.GetSnapshot(); 522var logRecords = logCollector.GetSnapshot(); 712Assert.Equal(7, logCollector.GetSnapshot()[0].StructuredState!.Count); 751Assert.IsType<InvalidOperationException>(logCollector.GetSnapshot()[0].Exception); 752Assert.Equal(7, logCollector.GetSnapshot()[1].StructuredState!.Count);
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (3)
Linux\LinuxUtilizationProviderTests.cs (1)
191var logRecords = logger.Collector.GetSnapshot();
Windows\WindowsContainerSnapshotProviderTests.cs (1)
323var logRecords = _logger.Collector.GetSnapshot();
Windows\WindowsSnapshotProviderTests.cs (1)
67var logRecords = _fakeLogger.Collector.GetSnapshot();
Microsoft.Extensions.Diagnostics.Testing (1)
Logging\FakeLogCollectorDebugView.cs (1)
22public IReadOnlyList<FakeLogRecord> Records => _collector.GetSnapshot();
Microsoft.Extensions.Diagnostics.Testing.Tests (4)
Logging\FakeLoggerProviderTests.cs (1)
47var records = provider.Collector.GetSnapshot();
Logging\FakeLoggerTests.cs (3)
32var records = logger.Collector.GetSnapshot(); 63Assert.Empty(logger.Collector.GetSnapshot()); 265var records = collector.GetSnapshot();
Microsoft.Extensions.Hosting.Testing.Tests (1)
HostTerminatorServiceTests.cs (1)
27Assert.Empty(logger.Collector.GetSnapshot());
Microsoft.Extensions.Http.Diagnostics.Tests (26)
Logging\AcceptanceTests.cs (14)
42var logRecord = Assert.Single(collector.GetSnapshot()); 74collector.GetSnapshot(), 115var logRecord = collector.GetSnapshot().Single(logRecord => logRecord.Category == LoggingCategory); 172var logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory); 188logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory); 258var logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory); 280logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory); 323var logRecord = collector.GetSnapshot().Single(logRecord => logRecord.Category == LoggingCategory); 366var logRecord = collector.GetSnapshot().Single(logRecord => logRecord.Category == LoggingCategory); 435var logRecord = collector.GetSnapshot().Single(logRecord => logRecord.Category == LoggingCategory); 595var logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory); 621var logRecords = collector.GetSnapshot().Where(l => l.Category == "System.Net.Http.HttpClient.normal.LogicalHandler").ToList(); 644var logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory); 696var logRecord = collector.GetSnapshot().Single(l => l.Category == LoggingCategory);
Logging\HttpClientLoggerTest.cs (12)
240var logRecords = fakeLogger.Collector.GetSnapshot(); 336var logRecords = fakeLogger.Collector.GetSnapshot(); 439var logRecords = fakeLogger.Collector.GetSnapshot(); 556var logRecords = fakeLogger.Collector.GetSnapshot(); 646var logRecords = fakeLogger.Collector.GetSnapshot(); 696var logRecords = fakeLogger.Collector.GetSnapshot(); 739var logRecords = fakeLogger.Collector.GetSnapshot(); 777var logRecords = fakeLogger.Collector.GetSnapshot(); 822var logRecords = fakeLogger.Collector.GetSnapshot(); 920var logRecords = fakeLogger.Collector.GetSnapshot(); 966var logRecord = fakeLogger.Collector.GetSnapshot().Single(); 986var logRecords = fakeLogger.Collector.GetSnapshot();
Microsoft.Extensions.Telemetry.Tests (6)
Logging\ExtendedLoggerTests.cs (6)
75var snap = collector.GetSnapshot(); 160var snap = collector.GetSnapshot(); 225var snap = collector.GetSnapshot(); 285var snap = collector.GetSnapshot(); 354var snap = collector.GetSnapshot(); 463var snap = collector.GetSnapshot();
Microsoft.Gen.Logging.Generated.Tests (6)
LogMethodTests.cs (1)
738var record = Assert.Single(collector.GetSnapshot());
SensitiveRecordTests.cs (5)
19var logRecord = Assert.Single(logger.FakeLogCollector.GetSnapshot()); 31var logRecord = Assert.Single(logger.FakeLogCollector.GetSnapshot()); 48var logRecord = Assert.Single(logger.FakeLogCollector.GetSnapshot()); 65var logRecord = Assert.Single(logger.FakeLogCollector.GetSnapshot()); 82var logRecord = Assert.Single(logger.FakeLogCollector.GetSnapshot());