summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoracolyer <acolyer>2005-02-17 15:05:58 +0000
committeracolyer <acolyer>2005-02-17 15:05:58 +0000
commit2eb9dd812120f6e8fbfbf59c31ee16d2ff68b032 (patch)
tree6b3f2b4ddedc0caa461435357da06b784f4306ad
parent5a308d4ff7800bfeee07f5e67841e938d63c17de (diff)
downloadaspectj-2eb9dd812120f6e8fbfbf59c31ee16d2ff68b032.tar.gz
aspectj-2eb9dd812120f6e8fbfbf59c31ee16d2ff68b032.zip
only inspect results if test could run
-rw-r--r--tests/src/org/aspectj/systemtest/ajc150/Annotations.java18
1 files changed, 10 insertions, 8 deletions
diff --git a/tests/src/org/aspectj/systemtest/ajc150/Annotations.java b/tests/src/org/aspectj/systemtest/ajc150/Annotations.java
index d242697bf..f8bc17ce1 100644
--- a/tests/src/org/aspectj/systemtest/ajc150/Annotations.java
+++ b/tests/src/org/aspectj/systemtest/ajc150/Annotations.java
@@ -49,15 +49,17 @@ public class Annotations extends XMLBasedAjcTestCase {
*/
public void testBugWithAnnotationsLostOnWovenMethods() throws ClassNotFoundException {
runTest("losing annotations...");
-
- JavaClass jc = getClassFrom(ajc.getSandboxDirectory(),"Program");
- Method[] meths = jc.getMethods();
- for (int i = 0; i < meths.length; i++) {
- Method method = meths[i];
- if (method.getName().equals("m1")) {
- assertTrue("Didn't have annotations - were they lost? method="+method.getName(),method.getAnnotations().length==1);
+ if (getCurrentTest().canRunOnThisVM()) {
+
+ JavaClass jc = getClassFrom(ajc.getSandboxDirectory(),"Program");
+ Method[] meths = jc.getMethods();
+ for (int i = 0; i < meths.length; i++) {
+ Method method = meths[i];
+ if (method.getName().equals("m1")) {
+ assertTrue("Didn't have annotations - were they lost? method="+method.getName(),method.getAnnotations().length==1);
+ }
}
- }
+ }
}
public void testAnnotatedAnnotations() {