mirror of https://github.com/apache/lucene.git
LUCENE-6847: sidestep virus checkers until we can do LUCENE-6835
git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1709609 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
9534904c25
commit
11745211d3
|
@ -377,7 +377,7 @@ public class TestBKDTree extends LuceneTestCase {
|
||||||
iwc.setCodec(codec);
|
iwc.setCodec(codec);
|
||||||
Directory dir;
|
Directory dir;
|
||||||
if (lats.length > 100000) {
|
if (lats.length > 100000) {
|
||||||
dir = newFSDirectory(createTempDir("TestBKDTree"));
|
dir = noVirusChecker(newFSDirectory(createTempDir("TestBKDTree")));
|
||||||
} else {
|
} else {
|
||||||
dir = getDirectory();
|
dir = getDirectory();
|
||||||
}
|
}
|
||||||
|
@ -634,11 +634,14 @@ public class TestBKDTree extends LuceneTestCase {
|
||||||
return new BKDTreeDocValuesFormat(maxPointsInLeaf, maxPointsSortInHeap);
|
return new BKDTreeDocValuesFormat(maxPointsInLeaf, maxPointsSortInHeap);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Directory getDirectory() {
|
private static Directory noVirusChecker(Directory dir) {
|
||||||
Directory dir = newDirectory();
|
|
||||||
if (dir instanceof MockDirectoryWrapper) {
|
if (dir instanceof MockDirectoryWrapper) {
|
||||||
((MockDirectoryWrapper) dir).setEnableVirusScanner(false);
|
((MockDirectoryWrapper) dir).setEnableVirusScanner(false);
|
||||||
}
|
}
|
||||||
return dir;
|
return dir;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static Directory getDirectory() {
|
||||||
|
return noVirusChecker(newDirectory());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -369,7 +369,7 @@ public class TestRangeTree extends LuceneTestCase {
|
||||||
iwc.setCodec(codec);
|
iwc.setCodec(codec);
|
||||||
Directory dir;
|
Directory dir;
|
||||||
if (values.length > 100000) {
|
if (values.length > 100000) {
|
||||||
dir = newFSDirectory(createTempDir("TestRangeTree"));
|
dir = noVirusChecker(newFSDirectory(createTempDir("TestRangeTree")));
|
||||||
} else {
|
} else {
|
||||||
dir = getDirectory();
|
dir = getDirectory();
|
||||||
}
|
}
|
||||||
|
@ -768,11 +768,14 @@ public class TestRangeTree extends LuceneTestCase {
|
||||||
return new RangeTreeDocValuesFormat(maxPointsInLeaf, maxPointsSortInHeap);
|
return new RangeTreeDocValuesFormat(maxPointsInLeaf, maxPointsSortInHeap);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Directory getDirectory() {
|
private static Directory noVirusChecker(Directory dir) {
|
||||||
Directory dir = newDirectory();
|
|
||||||
if (dir instanceof MockDirectoryWrapper) {
|
if (dir instanceof MockDirectoryWrapper) {
|
||||||
((MockDirectoryWrapper) dir).setEnableVirusScanner(false);
|
((MockDirectoryWrapper) dir).setEnableVirusScanner(false);
|
||||||
}
|
}
|
||||||
return dir;
|
return dir;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static Directory getDirectory() {
|
||||||
|
return noVirusChecker(newDirectory());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -923,7 +923,7 @@ public class TestGeo3DPointField extends LuceneTestCase {
|
||||||
iwc.setCodec(codec);
|
iwc.setCodec(codec);
|
||||||
Directory dir;
|
Directory dir;
|
||||||
if (lats.length > 100000) {
|
if (lats.length > 100000) {
|
||||||
dir = newFSDirectory(createTempDir("TestBKDTree"));
|
dir = noVirusChecker(newFSDirectory(createTempDir("TestBKDTree")));
|
||||||
} else {
|
} else {
|
||||||
dir = getDirectory();
|
dir = getDirectory();
|
||||||
}
|
}
|
||||||
|
@ -1061,11 +1061,14 @@ public class TestGeo3DPointField extends LuceneTestCase {
|
||||||
IOUtils.close(r, dir);
|
IOUtils.close(r, dir);
|
||||||
}
|
}
|
||||||
|
|
||||||
private static Directory getDirectory() {
|
private static Directory noVirusChecker(Directory dir) {
|
||||||
Directory dir = newDirectory();
|
|
||||||
if (dir instanceof MockDirectoryWrapper) {
|
if (dir instanceof MockDirectoryWrapper) {
|
||||||
((MockDirectoryWrapper) dir).setEnableVirusScanner(false);
|
((MockDirectoryWrapper) dir).setEnableVirusScanner(false);
|
||||||
}
|
}
|
||||||
return dir;
|
return dir;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static Directory getDirectory() {
|
||||||
|
return noVirusChecker(newDirectory());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue