org.apache.maven.plugin.assembly.testutils
Class TestFileManager
java.lang.Object
org.apache.maven.plugin.assembly.testutils.TestFileManager
public class TestFileManager
- extends Object
TEMP_DIR_PATH
public static final String TEMP_DIR_PATH
TestFileManager
public TestFileManager(String baseFilename,
String fileSuffix)
markForDeletion
public void markForDeletion(File toDelete)
createTempDir
public File createTempDir()
createTempFile
public File createTempFile()
throws IOException
- Throws:
IOException
cleanUp
public void cleanUp()
assertFileExistence
public void assertFileExistence(File dir,
String filename,
boolean shouldExist)
assertFileContents
public void assertFileContents(File dir,
String filename,
String contentsTest)
throws IOException
- Throws:
IOException
createFile
public File createFile(File dir,
String filename,
String contents)
throws IOException
- NOTE: the file content is written using platform encoding.
- Throws:
IOException
getFileContents
public String getFileContents(File file)
throws IOException
- NOTE: the file content is read using platform encoding.
- Throws:
IOException
finalize
protected void finalize()
throws Throwable
- Overrides:
finalize
in class Object
- Throws:
Throwable
createFile
public File createFile(String filename,
String content)
throws IOException
- Throws:
IOException
Copyright © 2002-2010 The Apache Software Foundation. All Rights Reserved.