* Checks the CommitCheckServlet works correctly with a one-chunk file.
*/
public void testDelayedAck() throws Exception {
Configuration conf = new Configuration();
SeqFileWriter writer = new SeqFileWriter();
conf.set("writer.hdfs.filesystem", "file:///");
File tempDir = new File(System.getProperty("test.build.data", "/tmp"));
if (!tempDir.exists()) {
tempDir.mkdirs();
}
String outputDirectory = tempDir.getPath() + "/test_DA" + System.currentTimeMillis();
String seqWriterOutputDir = outputDirectory +"/seqWriter/seqOutputDir";
conf.set(SeqFileWriter.OUTPUT_DIR_OPT, seqWriterOutputDir );
writer.init(conf);
ArrayList<Chunk> oneChunk = new ArrayList<Chunk>();
oneChunk.add(new ChunkImpl("dt", "name", 1, new byte[] {'b'}, null));
ChukwaWriter.CommitStatus cs = writer.add(oneChunk);
writer.close();
File seqWriterFile = null;
File directory = new File(seqWriterOutputDir);
String[] files = directory.list();
for(String file: files) {