Skip to content

Commit 6752e87

Browse files
committed
[test] Cleanup Directory and Searcher mock code
Related to #10853 Closes #83.
1 parent a34a443 commit 6752e87

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/test/java/org/elasticsearch/repositories/azure/AbstractAzureRepositoryServiceTest.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
import org.elasticsearch.common.settings.Settings;
2929
import org.elasticsearch.plugins.PluginsService;
3030
import org.elasticsearch.repositories.RepositoryMissingException;
31-
import org.elasticsearch.test.store.MockDirectoryHelper;
31+
import org.elasticsearch.test.store.MockFSDirectoryService;
3232
import org.junit.After;
3333
import org.junit.Before;
3434

@@ -82,8 +82,8 @@ public Settings indexSettings() {
8282
// During restore we frequently restore index to exactly the same state it was before, that might cause the same
8383
// checksum file to be written twice during restore operation
8484
return ImmutableSettings.builder().put(super.indexSettings())
85-
.put(MockDirectoryHelper.RANDOM_PREVENT_DOUBLE_WRITE, false)
86-
.put(MockDirectoryHelper.RANDOM_NO_DELETE_OPEN_FILE, false)
85+
.put(MockFSDirectoryService.RANDOM_PREVENT_DOUBLE_WRITE, false)
86+
.put(MockFSDirectoryService.RANDOM_NO_DELETE_OPEN_FILE, false)
8787
.put(IndexMetaData.SETTING_NUMBER_OF_REPLICAS, 0)
8888
.build();
8989
}

src/test/java/org/elasticsearch/repositories/azure/AzureSnapshotRestoreITest.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
import org.elasticsearch.snapshots.SnapshotMissingException;
4242
import org.elasticsearch.snapshots.SnapshotState;
4343
import org.elasticsearch.test.ElasticsearchIntegrationTest;
44-
import org.elasticsearch.test.store.MockDirectoryHelper;
44+
import org.elasticsearch.test.store.MockFSDirectoryService;
4545
import org.junit.*;
4646

4747
import java.net.URISyntaxException;
@@ -85,8 +85,8 @@ public Settings indexSettings() {
8585
// During restore we frequently restore index to exactly the same state it was before, that might cause the same
8686
// checksum file to be written twice during restore operation
8787
return ImmutableSettings.builder().put(super.indexSettings())
88-
.put(MockDirectoryHelper.RANDOM_PREVENT_DOUBLE_WRITE, false)
89-
.put(MockDirectoryHelper.RANDOM_NO_DELETE_OPEN_FILE, false)
88+
.put(MockFSDirectoryService.RANDOM_PREVENT_DOUBLE_WRITE, false)
89+
.put(MockFSDirectoryService.RANDOM_NO_DELETE_OPEN_FILE, false)
9090
.build();
9191
}
9292

0 commit comments

Comments
 (0)