8007485: test creates .class files in the test/ directory

Tue, 05 Feb 2013 21:55:41 -0800

author
jjg
date
Tue, 05 Feb 2013 21:55:41 -0800
changeset 1549
de932285124c
parent 1546
2480aec9a3f1
child 1550
1df20330f6bd

8007485: test creates .class files in the test/ directory
Reviewed-by: mcimadamore

test/tools/javac/api/8007344/Test.java file | annotate | diff | comparison | revisions
     1.1 --- a/test/tools/javac/api/8007344/Test.java	Tue Feb 05 18:55:13 2013 +0000
     1.2 +++ b/test/tools/javac/api/8007344/Test.java	Tue Feb 05 21:55:41 2013 -0800
     1.3 @@ -41,6 +41,7 @@
     1.4  import javax.lang.model.element.TypeElement;
     1.5  import javax.tools.JavaFileObject;
     1.6  import javax.tools.StandardJavaFileManager;
     1.7 +import javax.tools.StandardLocation;
     1.8  
     1.9  import com.sun.source.doctree.DocCommentTree;
    1.10  import com.sun.source.tree.*;
    1.11 @@ -83,6 +84,7 @@
    1.12          File thisFile = new File(testSrc, getClass().getName() + ".java");
    1.13          JavacTool javac = JavacTool.create();
    1.14          StandardJavaFileManager fm = javac.getStandardFileManager(null, null, null);
    1.15 +        fm.setLocation(StandardLocation.CLASS_OUTPUT, Arrays.asList(new File(".")));
    1.16          Iterable<? extends JavaFileObject> fos = fm.getJavaFileObjects(thisFile);
    1.17          testAnnoProcessor(javac, fm, fos, out, EXPECT_DOC_COMMENTS);
    1.18          testTaskListener(javac, fm, fos, out, EXPECT_DOC_COMMENTS);

mercurial