Package org.apache.lucene.tests.mockfile
package org.apache.lucene.tests.mockfile
Support for testing/debugging with virtual filesystems
The primary classes are:
LeakFS
: Fails tests if they leave open file handles.VerboseFS
: Prints destructive filesystem operations to infostream.WindowsFS
: Acts like windows.DisableFsyncFS
: Makes actual fsync calls a no-op.ExtrasFS
: Adds 'bonus' files to directories.ShuffleFS
: Directory listings in an unpredictable but deterministic order.
-
ClassDescriptionDisables actual calls to fsync.Adds extra files/subdirectories when directories are created.A
FilterAsynchronousFileChannel
contains anotherAsynchronousFileChannel
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterDirectoryStream
contains anotherDirectoryStream
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterFileChannel
contains anotherFileChannel
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterFileStore
contains anotherFileStore
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterFileSystem
contains anotherFileSystem
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterFileSystemProvider
contains anotherFileSystemProvider
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterInputStream2
contains anotherInputStream
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterOutputStream2
contains anotherOutputStream
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterPath
contains anotherPath
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.AFilterSeekableByteChannel
contains anotherSeekableByteChannel
, which it uses as its basic source of data, possibly transforming the data along the way or providing additional functionality.FileSystem that throws exception if file handles in use exceeds a specified limit.An annotationBase class for tracking file handles.FileSystem that tracks open handles.Base class for testing mockfilesystems.Gives an unpredictable, but deterministic order to directory listings.FileSystem that records all major destructive filesystem activities.Acts like a virus checker on Windows, where random programs may open the files you just wrote in an unfriendly way preventing deletion (e.g.FileSystem that (imperfectly) acts like windows.