loadSQLiteConfig loads the config for the sqlite persistence store. We use sqlite because it doesn't require any external dependencies, so it's easy to run this test in isolation.
(t *testing.T)
| 166 | // loadSQLiteConfig loads the config for the sqlite persistence store. We use sqlite because it doesn't require any |
| 167 | // external dependencies, so it's easy to run this test in isolation. |
| 168 | func loadSQLiteConfig(t *testing.T) *config.Config { |
| 169 | configDir := path.Join(testutils.GetRepoRootDirectory(), "config") |
| 170 | cfg, err := config.Load( |
| 171 | config.WithEnv("development-sqlite"), |
| 172 | config.WithConfigDir(configDir), |
| 173 | ) |
| 174 | require.NoError(t, err) |
| 175 | |
| 176 | cfg.DynamicConfigClient.Filepath = path.Join(configDir, "dynamicconfig", "development-sql.yaml") |
| 177 | |
| 178 | return cfg |
| 179 | } |
| 180 | |
| 181 | func setSQLiteDatabaseName(cfg *config.Config, databaseName string) { |
| 182 | for _, storeName := range []string{cfg.Persistence.DefaultStore, cfg.Persistence.VisibilityStore} { |
no test coverage detected