Skip to content

Commit

Permalink
Fix RepositoriesServiceIT.testUpdateRepository from opensearch-projec…
Browse files Browse the repository at this point in the history
  • Loading branch information
ashking94 authored and akolarkunnu committed Sep 10, 2024
1 parent 1f3b643 commit 072b238
Showing 1 changed file with 14 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,13 @@ public void testUpdateRepository() {
.next();

final Settings.Builder repoSettings = Settings.builder().put("location", randomRepoPath());
createRepository(repositoryName, FsRepository.TYPE, repoSettings);
OpenSearchIntegTestCase.putRepositoryWithNoSettingOverrides(
client().admin().cluster(),
repositoryName,
FsRepository.TYPE,
true,
repoSettings
);

final GetRepositoriesResponse originalGetRepositoriesResponse = client.admin()
.cluster()
Expand All @@ -87,7 +93,13 @@ public void testUpdateRepository() {
final boolean updated = randomBoolean();
final String updatedRepositoryType = updated ? "mock" : FsRepository.TYPE;

createRepository(repositoryName, updatedRepositoryType, repoSettings);
OpenSearchIntegTestCase.putRepositoryWithNoSettingOverrides(
client().admin().cluster(),
repositoryName,
updatedRepositoryType,
true,
repoSettings
);

final GetRepositoriesResponse updatedGetRepositoriesResponse = client.admin()
.cluster()
Expand Down

0 comments on commit 072b238

Please sign in to comment.