Commit d0d75430 authored by Evgeny Mandrikov's avatar Evgeny Mandrikov
Browse files

add unit test

parent b5dc9017
Pipeline #4431 failed with stage
in 5 minutes and 6 seconds
......@@ -340,6 +340,17 @@ public class CheckClassAdapterTest extends AsmTest implements Opcodes {
assertEquals("<T::LI.J<*+LA;>;>()V^LA;X: error at index 24", exception.getMessage());
}
@Test
public void testVisitMethod_legal() {
CheckClassAdapter checkClassAdapter = new CheckClassAdapter(null);
checkClassAdapter.visit(V1_1, ACC_PUBLIC, "C", null, "java/lang/Object", null);
MethodVisitor mv = checkClassAdapter.visitMethod(ACC_PUBLIC, "m", "()V", null, null);
mv.visitCode();
mv.visitInsn(Opcodes.RETURN);
mv.visitMaxs(0, 1);
mv.visitEnd();
}
@Test
public void testVisitTypeAnnotation_illegalAnnotation1() {
CheckClassAdapter checkClassAdapter = new CheckClassAdapter(null);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment