fix test bug

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1622068 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Muir 2014-09-02 17:27:34 +00:00
parent b04148f2c4
commit 5460fa9008

View File

@ -809,6 +809,11 @@ public class TestCompoundFile extends LuceneTestCase
public void testListAll() throws Exception {
Directory dir = newDirectory();
if (dir instanceof MockDirectoryWrapper) {
// test lists files manually and tries to verify every .cfs it finds,
// but a virus scanner could leave some trash.
((MockDirectoryWrapper)dir).setEnableVirusScanner(false);
}
// riw should sometimes create docvalues fields, etc
RandomIndexWriter riw = new RandomIndexWriter(random(), dir);
Document doc = new Document();