static IDocumentStore CreateDocumentStore() { var path = AppDomain.CurrentDomain.SetupInformation.ApplicationBase; path = Path.Combine(path, Conventions.RavenDataDirectory); var populate = !Directory.Exists(path); var documentStore = new EmbeddableDocumentStore() { DataDirectory = path }.Initialize(); if (populate) { documentStore.PopulateAll(); } //documentStore.DatabaseCommands.EnsureDatabaseExists (Conventions.RavenDatabase); return(documentStore); }