7133314: The regression test for 7129225 fails when run with jtreg -samevm or jtreg -agentvm

Reviewed-by: jjg
This commit is contained in:
Jim Holmlund 2012-01-25 12:20:05 -08:00
parent 8f129be7fb
commit e1fa8cca42
4 changed files with 10 additions and 6 deletions

View File

@ -27,9 +27,10 @@ import java.util.Set;
import javax.annotation.processing.*;
import javax.lang.model.SourceVersion;
import javax.lang.model.element.TypeElement;
import javax.tools.Diagnostic.Kind;
@SupportedAnnotationTypes("Anno")
public class AnnoProcessor extends AbstractProcessor {
public class AnnoProcessor extends JavacTestingAbstractProcessor {
@Override
public SourceVersion getSupportedSourceVersion() {
return SourceVersion.latest();
@ -37,7 +38,8 @@ public class AnnoProcessor extends AbstractProcessor {
@Override
public boolean process(Set<? extends TypeElement> set, RoundEnvironment re) {
System.out.println("RUNNING...");
messager.printMessage(Kind.NOTE, "RUNNING - lastRound = " + re.processingOver());
return true;
}
}

View File

@ -1,2 +1,2 @@
TestImportStar.java:37:1: compiler.err.doesnt.exist: xxx
TestImportStar.java:39:1: compiler.err.doesnt.exist: xxx
1 error

View File

@ -26,6 +26,8 @@
/* @test
* @bug 7129225
* @summary import xxx.* isn't handled correctly by annotation processing
* @library ../lib
* @build JavacTestingAbstractProcessor
* @compile/fail/ref=NegTest.ref -XDrawDiagnostics TestImportStar.java
* @compile Anno.java AnnoProcessor.java
* @compile/ref=TestImportStar.ref -XDrawDiagnostics -processor AnnoProcessor -proc:only TestImportStar.java

View File

@ -1,3 +1,3 @@
RUNNING...
RUNNING...
TestImportStar.java:37:1: compiler.err.doesnt.exist: xxx
- compiler.note.proc.messager: RUNNING - lastRound = false
TestImportStar.java:39:1: compiler.err.doesnt.exist: xxx
- compiler.note.proc.messager: RUNNING - lastRound = true