示例#1
0
		public void WriteAddLogEntryToDatabase()
		{
			var target = new DbContextTargetDouble();
			target.Write(new LogEventInfo(LogLevel.Debug, LoggerName, "some debug message"));
			using(var context = new LoggingContext(ConnectionStringName))
			{
				Assert.That(context.Log.Any(e => e.Logger == LoggerName));
			}
		}
示例#2
0
        public void WriteAddLogEntryToDatabase()
        {
            var target = new DbContextTargetDouble();

            target.Write(new LogEventInfo(LogLevel.Debug, LoggerName, "some debug message"));
            using (var context = new LoggingContext(ConnectionStringName))
            {
                Assert.That(context.Log.Any(e => e.Logger == LoggerName));
            }
        }