public abstract class FileBasedTestCase extends junit.framework.TestCase
| Constructor and Description |
|---|
FileBasedTestCase(String name) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
assertEqualContent(byte[] b0,
File file)
Assert that the content of a file is equal to that in a byte[].
|
protected void |
assertEqualContent(char[] c0,
File file)
Assert that the content of a file is equal to that in a char[].
|
protected void |
checkFile(File file,
File referenceFile) |
protected void |
checkWrite(OutputStream output) |
protected void |
checkWrite(Writer output) |
protected void |
createFile(File file,
long size) |
protected void |
createLineBasedFile(File file,
String[] data) |
protected void |
deleteFile(File file) |
protected byte[] |
generateTestData(long size) |
protected void |
generateTestData(OutputStream out,
long size) |
static File |
getTestDirectory() |
protected File |
newFile(String filename) |
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, countTestCases, createResult, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runBare, runTest, setName, setUp, tearDown, toStringpublic FileBasedTestCase(String name)
public static File getTestDirectory()
protected void createFile(File file, long size) throws IOException
IOExceptionprotected byte[] generateTestData(long size)
protected void generateTestData(OutputStream out, long size) throws IOException
IOExceptionprotected void createLineBasedFile(File file, String[] data) throws IOException
IOExceptionprotected File newFile(String filename) throws IOException
IOExceptionprotected void checkFile(File file, File referenceFile) throws Exception
Exceptionprotected void assertEqualContent(byte[] b0, File file) throws IOException
IOExceptionprotected void assertEqualContent(char[] c0, File file) throws IOException
IOExceptionprotected void checkWrite(OutputStream output) throws Exception
Exceptionprotected void checkWrite(Writer output) throws Exception
Exceptionprotected void deleteFile(File file) throws Exception
ExceptionCopyright © 2002-2013 The Apache Software Foundation. All Rights Reserved.