Exemplo n.º 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));
			}
		}
Exemplo n.º 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));
            }
        }