]> source.dussan.org Git - aspectj.git/commitdiff
some useful AST tests
authoraclement <aclement>
Tue, 8 Nov 2005 17:19:44 +0000 (17:19 +0000)
committeraclement <aclement>
Tue, 8 Nov 2005 17:19:44 +0000 (17:19 +0000)
org.aspectj.ajdt.core/testsrc/org/aspectj/tools/ajc/ASTVisitorTest.java

index 785c7f3ecce3ac7e2207d8afb8dffc86cb4b7f59..ea0fc5872e2da8897cd7e90a3b199b566aeb6210 100644 (file)
@@ -54,6 +54,18 @@ import org.aspectj.weaver.patterns.DeclareSoft;
 
 public class ASTVisitorTest extends TestCase {
        
+    // from bug 110465 - will currently break because of casts
+//     public void testAspectWithITD() {
+//             check("aspect A{ public void B.x(){} }",
+//                       "(compilationUnit(aspect(simpleName)(methodITD(primitiveType)(simpleName)(block))))");
+//     }
+//     
+//     public void testAspectWithCommentThenITD() {
+//             check("aspect A{ /** */ public void B.x(){} }","yyy");
+//     }
+       
+                               
+       // original tests
        public void testAnInterface() {
                check("interface AnInterface{}","(compilationUnit(interface(simpleName)))");
        }
@@ -364,6 +376,7 @@ class TestVisitor extends AjASTVisitor {
        }
                
        public boolean visit(MethodDeclaration node) {
+               if (node instanceof InterTypeMethodDeclaration) return visit((InterTypeMethodDeclaration)node);
                if (node.isConstructor()){
                        b.append("(constructor");
                } else {