diff options
author | aclement <aclement> | 2005-11-28 17:44:35 +0000 |
---|---|---|
committer | aclement <aclement> | 2005-11-28 17:44:35 +0000 |
commit | b6980f2f7b2697e41b454a16d3a7bd1e0135aa8d (patch) | |
tree | e9588758e74d8587cc925e3de87f935d3dfc1442 /weaver5 | |
parent | 8e14e21ab33d44d6fcfdcdf3576569e1e9e69995 (diff) | |
download | aspectj-b6980f2f7b2697e41b454a16d3a7bd1e0135aa8d.tar.gz aspectj-b6980f2f7b2697e41b454a16d3a7bd1e0135aa8d.zip |
Further changes for 118192
Diffstat (limited to 'weaver5')
-rw-r--r-- | weaver5/java5-testsrc/org/aspectj/weaver/TestJava5ReflectionBasedReferenceTypeDelegate.java | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/weaver5/java5-testsrc/org/aspectj/weaver/TestJava5ReflectionBasedReferenceTypeDelegate.java b/weaver5/java5-testsrc/org/aspectj/weaver/TestJava5ReflectionBasedReferenceTypeDelegate.java index a91e674bc..530dd9844 100644 --- a/weaver5/java5-testsrc/org/aspectj/weaver/TestJava5ReflectionBasedReferenceTypeDelegate.java +++ b/weaver5/java5-testsrc/org/aspectj/weaver/TestJava5ReflectionBasedReferenceTypeDelegate.java @@ -44,5 +44,21 @@ public class TestJava5ReflectionBasedReferenceTypeDelegate extends ReflectionBas world.resolve("java.lang.Class").getGenericType(); } + public void testGenericInterfaceSuperclass_ReflectionWorldResolution() { + + UnresolvedType javaUtilMap = UnresolvedType.forName("java.util.Map"); + + ReferenceType rawType = (ReferenceType) world.resolve(javaUtilMap); + assertTrue("Should be the raw type ?!? "+rawType.getTypekind(),rawType.isRawType()); + + ReferenceType genericType = (ReferenceType)rawType.getGenericType(); + assertTrue("Should be the generic type ?!? "+genericType.getTypekind(),genericType.isGenericType()); + + ResolvedType rt = rawType.getSuperclass(); + assertTrue("Superclass for Map raw type should be Object but was "+rt,rt.equals(UnresolvedType.OBJECT)); + + ResolvedType rt2 = genericType.getSuperclass(); + assertTrue("Superclass for Map generic type should be Object but was "+rt2,rt2.equals(UnresolvedType.OBJECT)); + } } |