public void OpenSessions() { if (!IsRavenDbStepOrFeature) { return; } RavenDb.OpenSession(); RavenDb.OpenStorageSession(); _log.Debug(m => m("Raven db session opened, id={0}", GetCurrentSessionId())); }
public void CloseSessions() { if (!RavenDb.HasCurrentSession) { return; } if (ScenarioContext.Current.TestError == null) { RavenDb.CurrentStorageSession.SubmitChanges(); _log.Debug(m => m("All changes saved to raven db, id={0}", GetCurrentSessionId())); } var id = GetCurrentSessionId(); RavenDb.DisposeSessions(); _log.Debug(m => m("Raven Db session closed, id={0}", id)); }
public void DisposeRavenDb() { RavenDb.DisposeSessions(); RavenDb.DisposeStorage(); _log.Debug(m => m("Document store disposed")); }
public void CreateRavenDb() { RavenDb.InitializeStorage(); }