diff options
author | aclement <aclement> | 2009-03-24 01:54:07 +0000 |
---|---|---|
committer | aclement <aclement> | 2009-03-24 01:54:07 +0000 |
commit | 24118fc5a91c72d5cea37d2ca433be6cb9785006 (patch) | |
tree | cb9e2bcbe9fcaae95959704f84024e55f0ed432a /asm | |
parent | 78decedeb5b689a9f2ec1bad7a813b2108c0f845 (diff) | |
download | aspectj-24118fc5a91c72d5cea37d2ca433be6cb9785006.tar.gz aspectj-24118fc5a91c72d5cea37d2ca433be6cb9785006.zip |
265993: more jdt like handles
Diffstat (limited to 'asm')
-rw-r--r-- | asm/testsrc/org/aspectj/asm/NameConvertorTest.java | 70 |
1 files changed, 35 insertions, 35 deletions
diff --git a/asm/testsrc/org/aspectj/asm/NameConvertorTest.java b/asm/testsrc/org/aspectj/asm/NameConvertorTest.java index c1162eed2..22ac3fb79 100644 --- a/asm/testsrc/org/aspectj/asm/NameConvertorTest.java +++ b/asm/testsrc/org/aspectj/asm/NameConvertorTest.java @@ -10,77 +10,77 @@ *******************************************************************/ package org.aspectj.asm; +import junit.framework.TestCase; + import org.aspectj.asm.internal.CharOperation; import org.aspectj.asm.internal.NameConvertor; -import junit.framework.TestCase; - public class NameConvertorTest extends TestCase { public void testBoolean() { - checkConversion("Z","boolean"); + checkConversion("Z", "boolean"); } - + public void testByte() { - checkConversion("B","byte"); + checkConversion("B", "byte"); } - + public void testChar() { - checkConversion("C","char"); - } - + checkConversion("C", "char"); + } + public void testDouble() { - checkConversion("D","double"); - } - + checkConversion("D", "double"); + } + public void testFloat() { - checkConversion("F","float"); + checkConversion("F", "float"); } - + public void testInt() { - checkConversion("I","int"); + checkConversion("I", "int"); } - + public void testLong() { - checkConversion("J","long"); - } - + checkConversion("J", "long"); + } + public void testShort() { - checkConversion("S","short"); - } - + checkConversion("S", "short"); + } + public void testString() { - checkConversion("Ljava/lang/String;","java.lang.String"); + checkConversion("Ljava/lang/String;", "java.lang.String"); } public void testType() { - checkConversion("LMyClass;","MyClass"); + checkConversion("LMyClass;", "MyClass"); } public void testListPameterizedWithString() { - checkConversion("Pjava/util/List<Ljava/lang/String;>;", - "java.util.List<java.lang.String>"); + checkConversion("Pjava/util/List<Ljava/lang/String;>;", "java.util.List<java.lang.String>"); } + public void testClassParameterizedWithStringAndType() { - checkConversion("PMyGenericClass<Ljava/lang/String;LMyClass;>;", - "MyGenericClass<java.lang.String,MyClass>"); + checkConversion("PMyGenericClass<Ljava/lang/String;LMyClass;>;", "MyGenericClass<java.lang.String,MyClass>"); } + public void testStringArray() { - checkConversion("[Ljava/lang/String;","java.lang.String[]"); + checkConversion("[Ljava/lang/String;", "java.lang.String[]"); } + public void testTwoDimensionalStringArray() { - checkConversion("[[Ljava/lang/String;","java.lang.String[][]"); + checkConversion("[[Ljava/lang/String;", "java.lang.String[][]"); } + public void testIntArray() { - checkConversion("[I","int[]"); + checkConversion("[I", "int[]"); } private void checkConversion(String signature, String expected) { char[] c = NameConvertor.convertFromSignature(signature.toCharArray()); - assertTrue("converting " + signature + ", expected " + expected + "," + - "but found " + String.valueOf(c), - CharOperation.equals(c,expected.toCharArray())); + assertTrue("converting " + signature + ", expected " + expected + "," + "but found " + String.valueOf(c), CharOperation + .equals(c, expected.toCharArray())); } - } |