public EsStatesRepositoryFixture() { var dbDeploymentConfig = DbDeploymentConfig.Load(); _esFiddleConnectionString = dbDeploymentConfig.ConnectionStrings.esFiddleDb; mongoDbServerDirectory = dbDeploymentConfig.mongoDbServerDirectory; string dbDeploymentPath = Path.Combine(dbDeploymentConfig.esFiddleDbPath, "IntegrationTests"); SetupDbPathAndLogFile(dbDeploymentPath); var arguments = string.Format(@"-dbpath ""{0}\\DB"" -logpath ""{1}\\Log.log""", dbDeploymentPath, dbDeploymentPath); var startInfo = new ProcessStartInfo(mongoDbServerDirectory + "mongod.exe", arguments); Process.Start(startInfo); }
public void Dispose() { string stopDbServerPath = DbDeploymentConfig.GetDeploymentScriptPath("StopDbServer.js"); Process.Start(mongoDbServerDirectory + "mongo.exe", stopDbServerPath); }