7086071: tools/javac/7079713/TestCircularClassfile.java fails on windows

Thu, 01 Sep 2011 14:35:59 -0700

author
jjh
date
Thu, 01 Sep 2011 14:35:59 -0700
changeset 1075
a45d78d26450
parent 1074
04f983e3e825
child 1076
02b8381781ab

7086071: tools/javac/7079713/TestCircularClassfile.java fails on windows
Summary: delete file before renaming another file to it
Reviewed-by: jjg

test/tools/javac/7079713/TestCircularClassfile.java file | annotate | diff | comparison | revisions
     1.1 --- a/test/tools/javac/7079713/TestCircularClassfile.java	Thu Sep 01 09:14:25 2011 -0700
     1.2 +++ b/test/tools/javac/7079713/TestCircularClassfile.java	Thu Sep 01 14:35:59 2011 -0700
     1.3 @@ -149,6 +149,7 @@
     1.4          //step 3: move a classfile from the temp folder to the test subfolder
     1.5          File fileToMove = new File(tmpDir, tk.targetClass);
     1.6          File target = new File(destDir, tk.targetClass);
     1.7 +        target.delete();
     1.8          boolean success = fileToMove.renameTo(target);
     1.9  
    1.10          if (!success) {

mercurial