1 write to State
Microsoft.Extensions.Diagnostics.Testing (1)
Logging\FakeLogRecord.cs (1)
34State = state;
7 references to State
Microsoft.Extensions.Diagnostics.Testing (2)
Logging\FakeLogRecord.cs (2)
65/// The object returned by this property is the same as what <see cref="State"/> returns, except it has been cast to a read-only list. 68public IReadOnlyList<KeyValuePair<string, string?>>? StructuredState => (IReadOnlyList<KeyValuePair<string, string?>>?)State;
Microsoft.Extensions.Diagnostics.Testing.Tests (3)
Logging\FakeLoggerTests.cs (3)
72Assert.Equal("42", (string)logger.LatestRecord.State!); 100Assert.Null(logger.LatestRecord.State); 130Assert.Equal(dt.ToString(CultureInfo.InvariantCulture), (string)logger.LatestRecord.State!);
Microsoft.Gen.Logging.Generated.Tests (2)
LogMethodTests.cs (2)
928var rol = (IReadOnlyList<KeyValuePair<string, string>>)collector.LatestRecord.State!; 939var rol = (collector.LatestRecord.State as IReadOnlyList<KeyValuePair<string, string?>>)!;