public RavenTest() { DatabaseMemoryTarget databaseMemoryTarget = null; if (LogManager.Configuration != null && LogManager.Configuration.AllTargets != null) { databaseMemoryTarget = LogManager.Configuration.AllTargets.OfType <DatabaseMemoryTarget>().FirstOrDefault(); } if (databaseMemoryTarget != null) { databaseMemoryTarget.ClearAll(); } try { new Uri("http://fail/first/time?only=%2bplus"); } catch (Exception) { } SystemTime.UtcDateTime = () => DateTime.UtcNow; ClearDatabaseDirectory(); Directory.CreateDirectory(DbDirectory); }
public RavenTest() { DatabaseMemoryTarget databaseMemoryTarget = null; if (LogManager.Configuration != null && LogManager.Configuration.AllTargets != null) { databaseMemoryTarget = LogManager.Configuration.AllTargets.OfType <DatabaseMemoryTarget>().FirstOrDefault(); } if (databaseMemoryTarget != null) { databaseMemoryTarget.ClearAll(); } SystemTime.UtcDateTime = () => DateTime.UtcNow; }
public DatabaseMemoryTargetTests() { LogContext.DatabaseName.Value = DatabaseName; sut = new DatabaseMemoryTarget(); }
public DatabaseMemoryTargetTests() { LogContext.ResourceName = DatabaseName; sut = new DatabaseMemoryTarget(); }