Program: 28809
Project: 28809
Buggy source:
@Test public void simplePermanentTransferDirTest() throws Exception {
  final String DIR="String_Node_Str";
  final String FILE_PREFIX="String_Node_Str";
  final String FILE_NAME="String_Node_Str";
  final Set<File> desiredResults=new HashSet<File>();
  final File origDir=File.createTempFile("String_Node_Str","String_Node_Str");
  origDir.delete();
  File targetDir=null;
  try {
    targetDir=File.createTempFile("String_Node_Str","String_Node_Str");
    targetDir.delete();
    targetDir.mkdir();
    origDir.mkdir();
    final URI dirURI=URI.create(DIR);
    final File dir=new File(origDir,DIR);
    dir.mkdirs();
    desiredResults.add(dir);
    final File file=new File(dir,FILE_NAME);
    desiredResults.add(new File(targetDir.toURI().resolve(FILE_PREFIX + FILE_NAME)));
    writeFile(file,"String_Node_Str","String_Node_Str","String_Node_Str");
    final long dirCreationTime=dir.lastModified();
    new CommonPermTest(){
      @Override protected CommonPermTest init(      File targetDir){
        super.init(targetDir);
        return this;
      }
      @Override protected void addParts(      Outbound ob,      PayloadFilesManager instance) throws Exception {
        ob.attachFile("String_Node_Str",URI.create(DIR),"String_Node_Str",dir);
        ob.attachFile("String_Node_Str",URI.create(FILE_PREFIX + file.getName()),"String_Node_Str",file);
      }
      @Override protected void checkResults(      Inbound ib,      PayloadFilesManager instance) throws Exception {
        instance.processParts(ib);
        final URI extractedDirURI=myTargetDir.toURI().resolve(dirURI);
        final File extractedDir=new File(extractedDirURI);
        final long extractedLastModified=extractedDir.lastModified();
        assertEquals("String_Node_Str",dirCreationTime,extractedLastModified);
      }
      @Override protected void cleanup(){
        for (        File f : desiredResults) {
          f.delete();
        }
      }
    }
.init(targetDir).run("String_Node_Str");
  }
  finally {
    if (targetDir != null) {
      FileUtils.whack(targetDir);
    }
  }
}

Fixed version (ground truth):
@Test public void simplePermanentTransferDirTest() throws Exception {
  final String DIR="String_Node_Str";
  final String FILE_PREFIX="String_Node_Str";
  final String FILE_NAME="String_Node_Str";
  final Set<File> desiredResults=new HashSet<File>();
  final File origDir=File.createTempFile("String_Node_Str","String_Node_Str");
  origDir.delete();
  File targetDir=null;
  try {
    targetDir=File.createTempFile("String_Node_Str","String_Node_Str");
    targetDir.delete();
    targetDir.mkdir();
    origDir.mkdir();
    final URI dirURI=URI.create(DIR);
    final File dir=new File(origDir,DIR);
    dir.mkdirs();
    desiredResults.add(dir);
    final File file=new File(dir,FILE_NAME);
    desiredResults.add(new File(targetDir.toURI().resolve(FILE_PREFIX + FILE_NAME)));
    writeFile(file,"String_Node_Str","String_Node_Str","String_Node_Str");
    final long dirCreationTime=dir.lastModified();
    new CommonPermTest(){
      @Override protected CommonPermTest init(      File targetDir){
        super.init(targetDir);
        return this;
      }
      @Override protected void addParts(      Outbound ob,      PayloadFilesManager instance) throws Exception {
        ob.attachFile("String_Node_Str",URI.create(DIR),"String_Node_Str",dir);
        ob.attachFile("String_Node_Str",URI.create(FILE_PREFIX + file.getName()),"String_Node_Str",file);
      }
      @Override protected void checkResults(      Inbound ib,      PayloadFilesManager instance) throws Exception {
        instance.processParts(ib);
        final URI extractedDirURI=myTargetDir.toURI().resolve(dirURI);
        final File extractedDir=new File(extractedDirURI);
        final long extractedLastModified=extractedDir.lastModified();
        assertEquals("String_Node_Str",dirCreationTime,extractedLastModified);
      }
      @Override protected void cleanup(){
        for (        File f : desiredResults) {
          f.delete();
        }
        PayloadFilesManagerTest.cleanup(origDir);
      }
    }
.init(targetDir).run("String_Node_Str");
  }
  finally {
    if (targetDir != null) {
      FileUtils.whack(targetDir);
    }
  }
}