public void T01_ShouldReadTestsConfig() { var cfg = TestsConfig.Load(); Assert.NotNull(cfg); Assert.False(string.IsNullOrEmpty(cfg.ConnectionStringTemplate)); }
static string GetSqlConnectionString(string memberName) { var cfg = TestsConfig.Load(); var csb = new SqlConnectionStringBuilder(cfg.ConnectionStringTemplate); csb.InitialCatalog += memberName; var result = csb.ConnectionString; var dbName = csb.InitialCatalog; { if (SqlUtils.DbExists(result)) { SqlUtils.DropDb(result); } SqlUtils.CreateDb(result); } return(result); }