Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[JDK18] MethodHandleAccessorsTest.testOneArgMethod failures #14084

Closed
babsingh opened this issue Dec 6, 2021 · 6 comments
Closed

[JDK18] MethodHandleAccessorsTest.testOneArgMethod failures #14084

babsingh opened this issue Dec 6, 2021 · 6 comments

Comments

@babsingh
Copy link
Contributor

babsingh commented Dec 6, 2021

OpenJDK Tests

TEST: java/lang/reflect/MethodHandleAccessorsTest.java#id0
TEST: java/lang/reflect/MethodHandleAccessorsTest.java#id1

Errors

 ==== Error 1 ====
[2021-11-17T18:32:26.238Z] test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_I", int, null, [Ljava.lang.Object;@946876cb, null, [Ljava.lang.Throwable;@a6a6c011): failure
[2021-11-17T18:32:26.238Z] java.lang.RuntimeException: jdk.internal.reflect.DirectMethodHandleAccessor for method: public static int MethodHandleAccessorsTest.public_static_I_I(int) test failure
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:351)
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.testOneArgMethod(MethodHandleAccessorsTest.java:512)
[2021-11-17T18:32:26.238Z]      at java.lang.invoke.LambdaForm$DMH/0x0000000010110a90.invokeVirtual(LambdaForm$DMH)
[2021-11-17T18:32:26.238Z]      at java.lang.invoke.LambdaForm$MH/0x000000001012aae0.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.238Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000c570.invokeExact_MT(LambdaForm$MH)
[2021-11-17T18:32:26.238Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:158)
[2021-11-17T18:32:26.238Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
[2021-11-17T18:32:26.238Z]      at java.base/java.lang.reflect.Method.invoke(Method.java:577)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
[2021-11-17T18:32:26.238Z]      at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
[2021-11-17T18:32:26.238Z]      at org.testng.TestRunner$$Lambda$79/0x00000000100bf050.accept(Unknown Source)
[2021-11-17T18:32:26.238Z]      at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
[2021-11-17T18:32:26.238Z]      at org.testng.TestRunner.privateRun(TestRunner.java:764)
[2021-11-17T18:32:26.238Z]      at org.testng.TestRunner.run(TestRunner.java:585)
[2021-11-17T18:32:26.238Z]      at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
[2021-11-17T18:32:26.238Z]      at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
[2021-11-17T18:32:26.238Z]      at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
[2021-11-17T18:32:26.238Z]      at org.testng.SuiteRunner.run(SuiteRunner.java:286)
[2021-11-17T18:32:26.238Z]      at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
[2021-11-17T18:32:26.238Z]      at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
[2021-11-17T18:32:26.238Z]      at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
[2021-11-17T18:32:26.238Z]      at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
[2021-11-17T18:32:26.238Z]      at org.testng.TestNG.runSuites(TestNG.java:1069)
[2021-11-17T18:32:26.238Z]      at org.testng.TestNG.run(TestNG.java:1037)
[2021-11-17T18:32:26.238Z]      at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
[2021-11-17T18:32:26.238Z]      at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
[2021-11-17T18:32:26.238Z]      at java.lang.invoke.LambdaForm$DMH/0x00000000100069a0.invokeStatic(LambdaForm$DMH)
[2021-11-17T18:32:26.238Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000bd40.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.238Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000c570.invokeExact_MT(LambdaForm$MH)
[2021-11-17T18:32:26.238Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
[2021-11-17T18:32:26.238Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
[2021-11-17T18:32:26.238Z]      at java.base/java.lang.reflect.Method.invoke(Method.java:577)
[2021-11-17T18:32:26.238Z]      at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
[2021-11-17T18:32:26.238Z]      at java.base/java.lang.Thread.run(Thread.java:884)
[2021-11-17T18:32:26.238Z] Caused by: java.lang.AssertionError: Exception thrown (see cause) but expected exceptions were different (see suppressed)
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.fail(MethodHandleAccessorsTest.java:341)
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.checkException(MethodHandleAccessorsTest.java:320)
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.chechResult(MethodHandleAccessorsTest.java:296)
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:232)
[2021-11-17T18:32:26.238Z]      at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:349)
[2021-11-17T18:32:26.238Z]      ... 39 more
[2021-11-17T18:32:26.238Z]      Suppressed: java.lang.IllegalArgumentException: argument type mismatch
[2021-11-17T18:32:26.238Z]              at MethodHandleAccessorsTest.<clinit>(MethodHandleAccessorsTest.java:381)
[2021-11-17T18:32:26.238Z]              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
[2021-11-17T18:32:26.238Z]              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1522)
[2021-11-17T18:32:26.238Z]              at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.ensureClassInitialized(MethodHandleAccessorFactory.java:300)
[2021-11-17T18:32:26.238Z]              at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.newConstructorAccessor(MethodHandleAccessorFactory.java:103)
[2021-11-17T18:32:26.238Z]              at java.base/jdk.internal.reflect.ReflectionFactory.newConstructorAccessor(ReflectionFactory.java:236)
[2021-11-17T18:32:26.239Z]              at java.base/java.lang.reflect.Constructor.acquireConstructorAccessor(Constructor.java:546)
[2021-11-17T18:32:26.239Z]              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:496)
[2021-11-17T18:32:26.239Z]              at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
[2021-11-17T18:32:26.239Z]              at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:23)
[2021-11-17T18:32:26.239Z]              at org.testng.internal.InstanceCreator.instantiateUsingDefaultConstructor(InstanceCreator.java:193)
[2021-11-17T18:32:26.239Z]              at org.testng.internal.InstanceCreator.createInstanceUsingObjectFactory(InstanceCreator.java:113)
[2021-11-17T18:32:26.239Z]              at org.testng.internal.InstanceCreator.createInstance(InstanceCreator.java:79)
[2021-11-17T18:32:26.239Z]              at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:109)
[2021-11-17T18:32:26.239Z]              at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:167)
[2021-11-17T18:32:26.239Z]              at org.testng.TestClass.getInstances(TestClass.java:102)
[2021-11-17T18:32:26.239Z]              at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:82)
[2021-11-17T18:32:26.239Z]              at org.testng.TestClass.init(TestClass.java:74)
[2021-11-17T18:32:26.239Z]              at org.testng.TestClass.<init>(TestClass.java:39)
[2021-11-17T18:32:26.239Z]              at org.testng.TestRunner.initMethods(TestRunner.java:457)
[2021-11-17T18:32:26.239Z]              at org.testng.TestRunner.init(TestRunner.java:336)
[2021-11-17T18:32:26.239Z]              at org.testng.TestRunner.init(TestRunner.java:289)
[2021-11-17T18:32:26.239Z]              at org.testng.TestRunner.<init>(TestRunner.java:180)
[2021-11-17T18:32:26.239Z]              at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:613)
[2021-11-17T18:32:26.239Z]              at org.testng.SuiteRunner.init(SuiteRunner.java:178)
[2021-11-17T18:32:26.239Z]              at org.testng.SuiteRunner.<init>(SuiteRunner.java:112)
[2021-11-17T18:32:26.239Z]              at org.testng.TestNG.createSuiteRunner(TestNG.java:1306)
[2021-11-17T18:32:26.239Z]              at org.testng.TestNG.createSuiteRunners(TestNG.java:1282)
[2021-11-17T18:32:26.239Z]              at org.testng.TestNG.runSuitesLocally(TestNG.java:1131)
[2021-11-17T18:32:26.239Z]              ... 12 more
[2021-11-17T18:32:26.239Z] Caused by: java.lang.reflect.InvocationTargetException
[2021-11-17T18:32:26.239Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:110)
[2021-11-17T18:32:26.239Z]      at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:224)
[2021-11-17T18:32:26.239Z]      ... 40 more
[2021-11-17T18:32:26.239Z] Caused by: java.lang.ClassCastException: java.lang.String incompatible with java.lang.Number
[2021-11-17T18:32:26.239Z]      at java.base/sun.invoke.util.ValueConversions.primitiveConversion(ValueConversions.java:247)
[2021-11-17T18:32:26.239Z]      at java.base/sun.invoke.util.ValueConversions.unboxInteger(ValueConversions.java:81)
[2021-11-17T18:32:26.239Z]      at java.lang.invoke.LambdaForm$DMH/0x0000000010122eb0.invokeStatic(LambdaForm$DMH)
[2021-11-17T18:32:26.239Z]      at java.lang.invoke.LambdaForm$MH/0x0000000010124530.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.239Z]      at java.lang.invoke.LambdaForm$MH/0x000000001013d920.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.239Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000c570.invokeExact_MT(LambdaForm$MH)
[2021-11-17T18:32:26.239Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
[2021-11-17T18:32:26.239Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
[2021-11-17T18:32:26.239Z]      ... 41 more

 ==== Error 2 ====
[2021-11-17T18:32:26.243Z] public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: MethodHandleAccessorsTest@a1dfee6b, args: [null]
[2021-11-17T18:32:26.243Z] test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, MethodHandleAccessorsTest@a1dfee6b, [Ljava.lang.Object;@6b8d1c87, null, [Ljava.lang.Throwable;@d12ecc): failure
[2021-11-17T18:32:26.243Z] java.lang.RuntimeException: jdk.internal.reflect.DirectMethodHandleAccessor for method: public int MethodHandleAccessorsTest.public_I_I(int) test failure
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:351)
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.testOneArgMethod(MethodHandleAccessorsTest.java:512)
[2021-11-17T18:32:26.243Z]      at java.lang.invoke.LambdaForm$DMH/0x0000000010110a90.invokeVirtual(LambdaForm$DMH)
[2021-11-17T18:32:26.243Z]      at java.lang.invoke.LambdaForm$MH/0x000000001012aae0.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.243Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000c570.invokeExact_MT(LambdaForm$MH)
[2021-11-17T18:32:26.243Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:158)
[2021-11-17T18:32:26.243Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
[2021-11-17T18:32:26.243Z]      at java.base/java.lang.reflect.Method.invoke(Method.java:577)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
[2021-11-17T18:32:26.243Z]      at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
[2021-11-17T18:32:26.243Z]      at org.testng.TestRunner$$Lambda$79/0x00000000100bf050.accept(Unknown Source)
[2021-11-17T18:32:26.243Z]      at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
[2021-11-17T18:32:26.243Z]      at org.testng.TestRunner.privateRun(TestRunner.java:764)
[2021-11-17T18:32:26.243Z]      at org.testng.TestRunner.run(TestRunner.java:585)
[2021-11-17T18:32:26.243Z]      at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
[2021-11-17T18:32:26.243Z]      at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
[2021-11-17T18:32:26.243Z]      at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
[2021-11-17T18:32:26.243Z]      at org.testng.SuiteRunner.run(SuiteRunner.java:286)
[2021-11-17T18:32:26.243Z]      at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
[2021-11-17T18:32:26.243Z]      at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
[2021-11-17T18:32:26.243Z]      at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
[2021-11-17T18:32:26.243Z]      at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
[2021-11-17T18:32:26.243Z]      at org.testng.TestNG.runSuites(TestNG.java:1069)
[2021-11-17T18:32:26.243Z]      at org.testng.TestNG.run(TestNG.java:1037)
[2021-11-17T18:32:26.243Z]      at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
[2021-11-17T18:32:26.243Z]      at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
[2021-11-17T18:32:26.243Z]      at java.lang.invoke.LambdaForm$DMH/0x00000000100069a0.invokeStatic(LambdaForm$DMH)
[2021-11-17T18:32:26.243Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000bd40.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.243Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000c570.invokeExact_MT(LambdaForm$MH)
[2021-11-17T18:32:26.243Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
[2021-11-17T18:32:26.243Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
[2021-11-17T18:32:26.243Z]      at java.base/java.lang.reflect.Method.invoke(Method.java:577)
[2021-11-17T18:32:26.243Z]      at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
[2021-11-17T18:32:26.243Z]      at java.base/java.lang.Thread.run(Thread.java:884)
[2021-11-17T18:32:26.243Z] Caused by: java.lang.AssertionError: Exception thrown (see cause) but expected exceptions were different (see suppressed)
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.fail(MethodHandleAccessorsTest.java:341)
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.checkException(MethodHandleAccessorsTest.java:320)
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.chechResult(MethodHandleAccessorsTest.java:296)
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:232)
[2021-11-17T18:32:26.243Z]      at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:349)
[2021-11-17T18:32:26.243Z]      ... 39 more
[2021-11-17T18:32:26.243Z]      Suppressed: java.lang.IllegalArgumentException: java.lang.NullPointerException
[2021-11-17T18:32:26.243Z]              at MethodHandleAccessorsTest.<clinit>(MethodHandleAccessorsTest.java:408)
[2021-11-17T18:32:26.243Z]              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
[2021-11-17T18:32:26.243Z]              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1522)
[2021-11-17T18:32:26.243Z]              at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.ensureClassInitialized(MethodHandleAccessorFactory.java:300)
[2021-11-17T18:32:26.243Z]              at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.newConstructorAccessor(MethodHandleAccessorFactory.java:103)
[2021-11-17T18:32:26.243Z]              at java.base/jdk.internal.reflect.ReflectionFactory.newConstructorAccessor(ReflectionFactory.java:236)
[2021-11-17T18:32:26.243Z]              at java.base/java.lang.reflect.Constructor.acquireConstructorAccessor(Constructor.java:546)
[2021-11-17T18:32:26.243Z]              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:496)
[2021-11-17T18:32:26.243Z]              at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
[2021-11-17T18:32:26.243Z]              at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:23)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.InstanceCreator.instantiateUsingDefaultConstructor(InstanceCreator.java:193)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.InstanceCreator.createInstanceUsingObjectFactory(InstanceCreator.java:113)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.InstanceCreator.createInstance(InstanceCreator.java:79)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:109)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:167)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.getInstances(TestClass.java:102)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:82)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.init(TestClass.java:74)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.<init>(TestClass.java:39)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.initMethods(TestRunner.java:457)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.init(TestRunner.java:336)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.init(TestRunner.java:289)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.<init>(TestRunner.java:180)
[2021-11-17T18:32:26.244Z]              at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:613)
[2021-11-17T18:32:26.244Z]              at org.testng.SuiteRunner.init(SuiteRunner.java:178)
[2021-11-17T18:32:26.244Z]              at org.testng.SuiteRunner.<init>(SuiteRunner.java:112)
[2021-11-17T18:32:26.244Z]              at org.testng.TestNG.createSuiteRunner(TestNG.java:1306)
[2021-11-17T18:32:26.244Z]              at org.testng.TestNG.createSuiteRunners(TestNG.java:1282)
[2021-11-17T18:32:26.244Z]              at org.testng.TestNG.runSuitesLocally(TestNG.java:1131)
[2021-11-17T18:32:26.244Z]              ... 12 more
[2021-11-17T18:32:26.244Z]      Suppressed: java.lang.NullPointerException
[2021-11-17T18:32:26.244Z]              at MethodHandleAccessorsTest.<clinit>(MethodHandleAccessorsTest.java:408)
[2021-11-17T18:32:26.244Z]              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized0(Native Method)
[2021-11-17T18:32:26.244Z]              at java.base/jdk.internal.misc.Unsafe.ensureClassInitialized(Unsafe.java:1522)
[2021-11-17T18:32:26.244Z]              at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.ensureClassInitialized(MethodHandleAccessorFactory.java:300)
[2021-11-17T18:32:26.244Z]              at java.base/jdk.internal.reflect.MethodHandleAccessorFactory.newConstructorAccessor(MethodHandleAccessorFactory.java:103)
[2021-11-17T18:32:26.244Z]              at java.base/jdk.internal.reflect.ReflectionFactory.newConstructorAccessor(ReflectionFactory.java:236)
[2021-11-17T18:32:26.244Z]              at java.base/java.lang.reflect.Constructor.acquireConstructorAccessor(Constructor.java:546)
[2021-11-17T18:32:26.244Z]              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:496)
[2021-11-17T18:32:26.244Z]              at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:23)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.InstanceCreator.instantiateUsingDefaultConstructor(InstanceCreator.java:193)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.InstanceCreator.createInstanceUsingObjectFactory(InstanceCreator.java:113)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.InstanceCreator.createInstance(InstanceCreator.java:79)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:109)
[2021-11-17T18:32:26.244Z]              at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:167)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.getInstances(TestClass.java:102)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:82)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.init(TestClass.java:74)
[2021-11-17T18:32:26.244Z]              at org.testng.TestClass.<init>(TestClass.java:39)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.initMethods(TestRunner.java:457)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.init(TestRunner.java:336)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.init(TestRunner.java:289)
[2021-11-17T18:32:26.244Z]              at org.testng.TestRunner.<init>(TestRunner.java:180)
[2021-11-17T18:32:26.244Z]              at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:613)
[2021-11-17T18:32:26.244Z]              at org.testng.SuiteRunner.init(SuiteRunner.java:178)
[2021-11-17T18:32:26.244Z]              at org.testng.SuiteRunner.<init>(SuiteRunner.java:112)
[2021-11-17T18:32:26.244Z]              at org.testng.TestNG.createSuiteRunner(TestNG.java:1306)
[2021-11-17T18:32:26.244Z]              at org.testng.TestNG.createSuiteRunners(TestNG.java:1282)
[2021-11-17T18:32:26.244Z]              at org.testng.TestNG.runSuitesLocally(TestNG.java:1131)
[2021-11-17T18:32:26.244Z]              ... 12 more
[2021-11-17T18:32:26.244Z] Caused by: java.lang.reflect.InvocationTargetException
[2021-11-17T18:32:26.244Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:116)
[2021-11-17T18:32:26.244Z]      at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:224)
[2021-11-17T18:32:26.244Z]      ... 40 more
[2021-11-17T18:32:26.244Z] Caused by: java.lang.NullPointerException
[2021-11-17T18:32:26.244Z]      at java.base/sun.invoke.util.ValueConversions.unboxInteger(ValueConversions.java:81)
[2021-11-17T18:32:26.244Z]      at java.lang.invoke.LambdaForm$DMH/0x0000000010122eb0.invokeStatic(LambdaForm$DMH)
[2021-11-17T18:32:26.244Z]      at java.lang.invoke.LambdaForm$MH/0x0000000010124530.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.244Z]      at java.lang.invoke.LambdaForm$MH/0x0000000010125fb0.invoke(LambdaForm$MH)
[2021-11-17T18:32:26.244Z]      at java.lang.invoke.LambdaForm$MH/0x000000001000c570.invokeExact_MT(LambdaForm$MH)
[2021-11-17T18:32:26.244Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
[2021-11-17T18:32:26.244Z]      at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
[2021-11-17T18:32:26.244Z]      ... 41 more

 ==== Error 3 ====
[2021-11-17T18:32:26.253Z] test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_V", int, null, [Ljava.lang.Object;@6080bc4f, null, [Ljava.lang.Throwable;@b9299020): failure
[2021-11-17T18:32:26.253Z] java.lang.RuntimeException: jdk.internal.reflect.DelegatingMethodAccessorImpl for method: public static void MethodHandleAccessorsTest.public_static_I_V(int) test failure
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:351)
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.testOneArgMethod(MethodHandleAccessorsTest.java:512)
[2021-11-17T18:32:26.253Z]      at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2021-11-17T18:32:26.253Z]      at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
[2021-11-17T18:32:26.253Z]      at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
[2021-11-17T18:32:26.253Z]      at java.base/java.lang.reflect.Method.invoke(Method.java:577)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
[2021-11-17T18:32:26.253Z]      at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
[2021-11-17T18:32:26.253Z]      at org.testng.TestRunner$$Lambda$79/0x00000000040bb2e0.accept(Unknown Source)
[2021-11-17T18:32:26.253Z]      at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
[2021-11-17T18:32:26.253Z]      at org.testng.TestRunner.privateRun(TestRunner.java:764)
[2021-11-17T18:32:26.253Z]      at org.testng.TestRunner.run(TestRunner.java:585)
[2021-11-17T18:32:26.253Z]      at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
[2021-11-17T18:32:26.253Z]      at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
[2021-11-17T18:32:26.253Z]      at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
[2021-11-17T18:32:26.253Z]      at org.testng.SuiteRunner.run(SuiteRunner.java:286)
[2021-11-17T18:32:26.253Z]      at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
[2021-11-17T18:32:26.253Z]      at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
[2021-11-17T18:32:26.253Z]      at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
[2021-11-17T18:32:26.253Z]      at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
[2021-11-17T18:32:26.253Z]      at org.testng.TestNG.runSuites(TestNG.java:1069)
[2021-11-17T18:32:26.253Z]      at org.testng.TestNG.run(TestNG.java:1037)
[2021-11-17T18:32:26.253Z]      at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
[2021-11-17T18:32:26.253Z]      at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
[2021-11-17T18:32:26.253Z]      at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2021-11-17T18:32:26.253Z]      at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
[2021-11-17T18:32:26.253Z]      at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
[2021-11-17T18:32:26.253Z]      at java.base/java.lang.reflect.Method.invoke(Method.java:577)
[2021-11-17T18:32:26.253Z]      at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
[2021-11-17T18:32:26.253Z]      at java.base/java.lang.Thread.run(Thread.java:884)
[2021-11-17T18:32:26.253Z] Caused by: java.lang.AssertionError: Exception thrown (see cause) but expected exceptions were different (see suppressed)
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.fail(MethodHandleAccessorsTest.java:341)
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.checkException(MethodHandleAccessorsTest.java:320)
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.chechResult(MethodHandleAccessorsTest.java:296)
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:232)
[2021-11-17T18:32:26.253Z]      at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:349)
[2021-11-17T18:32:26.253Z]      ... 35 more
[2021-11-17T18:32:26.253Z]      Suppressed: java.lang.IllegalArgumentException
[2021-11-17T18:32:26.253Z]              at MethodHandleAccessorsTest.<clinit>(MethodHandleAccessorsTest.java:405)
[2021-11-17T18:32:26.253Z]              at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
[2021-11-17T18:32:26.253Z]              at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:76)
[2021-11-17T18:32:26.253Z]              at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:53)
[2021-11-17T18:32:26.253Z]              at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
[2021-11-17T18:32:26.253Z]              at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
[2021-11-17T18:32:26.253Z]              at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:23)
[2021-11-17T18:32:26.253Z]              at org.testng.internal.InstanceCreator.instantiateUsingDefaultConstructor(InstanceCreator.java:193)
[2021-11-17T18:32:26.253Z]              at org.testng.internal.InstanceCreator.createInstanceUsingObjectFactory(InstanceCreator.java:113)
[2021-11-17T18:32:26.253Z]              at org.testng.internal.InstanceCreator.createInstance(InstanceCreator.java:79)
[2021-11-17T18:32:26.253Z]              at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:109)
[2021-11-17T18:32:26.253Z]              at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:167)
[2021-11-17T18:32:26.253Z]              at org.testng.TestClass.getInstances(TestClass.java:102)
[2021-11-17T18:32:26.253Z]              at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:82)
[2021-11-17T18:32:26.253Z]              at org.testng.TestClass.init(TestClass.java:74)
[2021-11-17T18:32:26.253Z]              at org.testng.TestClass.<init>(TestClass.java:39)
[2021-11-17T18:32:26.253Z]              at org.testng.TestRunner.initMethods(TestRunner.java:457)
[2021-11-17T18:32:26.253Z]              at org.testng.TestRunner.init(TestRunner.java:336)
[2021-11-17T18:32:26.253Z]              at org.testng.TestRunner.init(TestRunner.java:289)
[2021-11-17T18:32:26.253Z]              at org.testng.TestRunner.<init>(TestRunner.java:180)
[2021-11-17T18:32:26.253Z]              at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:613)
[2021-11-17T18:32:26.253Z]              at org.testng.SuiteRunner.init(SuiteRunner.java:178)
[2021-11-17T18:32:26.253Z]              at org.testng.SuiteRunner.<init>(SuiteRunner.java:112)
[2021-11-17T18:32:26.253Z]              at org.testng.TestNG.createSuiteRunner(TestNG.java:1306)
[2021-11-17T18:32:26.253Z]              at org.testng.TestNG.createSuiteRunners(TestNG.java:1282)
[2021-11-17T18:32:26.253Z]              at org.testng.TestNG.runSuitesLocally(TestNG.java:1131)
[2021-11-17T18:32:26.254Z]              ... 10 more
[2021-11-17T18:32:26.254Z] Caused by: java.lang.IllegalArgumentException: argument type mismatch
[2021-11-17T18:32:26.254Z]      at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[2021-11-17T18:32:26.254Z]      at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
[2021-11-17T18:32:26.254Z]      at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
[2021-11-17T18:32:26.254Z]      at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:224)
[2021-11-17T18:32:26.254Z]      ... 36 more

Related: #13946

@babsingh babsingh added this to the Release 0.31 (Java 18) milestone Dec 6, 2021
@babsingh babsingh changed the title [JDK18] MethodHandleAccessorsTest.testOneArgMethod failure [JDK18] MethodHandleAccessorsTest.testOneArgMethod failures Dec 6, 2021
babsingh added a commit to babsingh/aqa-tests that referenced this issue Dec 6, 2021
babsingh added a commit to babsingh/aqa-tests that referenced this issue Dec 6, 2021
llxia pushed a commit to adoptium/aqa-tests that referenced this issue Dec 7, 2021
@JasonFengJ9
Copy link
Member

Observed at an internal build /job/Test_openjdk18_j9_sanity.openjdk_aarch64_linux_Personal/1/consoleFull

14:53:38  openjdk version "18-internal" 2022-03-22
14:53:38  OpenJDK Runtime Environment (build 18-internal+0-adhoc.jenkins.BuildJDK18aarch64linuxPersonal)
14:53:38  Eclipse OpenJ9 VM (build master-3cf0509e7e0, JRE 18 Linux aarch64-64-Bit Compressed References 20220105_1 (JIT enabled, AOT enabled)
14:53:38  OpenJ9   - 3cf0509e7e0
14:53:38  OMR      - b5643d01920
14:53:38  JCL      - 03a0ab353e1 based on jdk-18+29)

14:55:56  variation: -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage Mode150
14:55:56  JVM_OPTIONS:  -Xdump:system:none -Xdump:heap:none -Xdump:system:events=gpf+abort+traceassert+corruptcache -XX:-JITServerTechPreviewMessage -XX:+UseCompressedOops 

15:03:39  --------------------------------------------------
15:03:39  TEST: java/lang/reflect/IllegalArgumentsTest.java

15:03:39  STDOUT:
15:03:39  test IllegalArgumentsTest.illegalArguments(): success
15:03:39  test IllegalArgumentsTest.nullArguments(): failure
15:03:39  java.lang.reflect.InvocationTargetException
15:03:39  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:77)
15:03:39  	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
15:03:39  	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
15:03:39  	at IllegalArgumentsTest.nullArguments(IllegalArgumentsTest.java:68)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x0000000024110540.invokeVirtual(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x00000000241127d0.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x00000000b032b9a0.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:154)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
15:03:39  	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
15:03:39  	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
15:03:39  	at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
15:03:39  	at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
15:03:39  	at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
15:03:39  	at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
15:03:39  	at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
15:03:39  	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
15:03:39  	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
15:03:39  	at org.testng.TestRunner$$Lambda$69/0x00000000240d8528.accept(Unknown Source)
15:03:39  	at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
15:03:39  	at org.testng.TestRunner.privateRun(TestRunner.java:764)
15:03:39  	at org.testng.TestRunner.run(TestRunner.java:585)
15:03:39  	at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
15:03:39  	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
15:03:39  	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
15:03:39  	at org.testng.SuiteRunner.run(SuiteRunner.java:286)
15:03:39  	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
15:03:39  	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
15:03:39  	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
15:03:39  	at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
15:03:39  	at org.testng.TestNG.runSuites(TestNG.java:1069)
15:03:39  	at org.testng.TestNG.run(TestNG.java:1037)
15:03:39  	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
15:03:39  	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x0000000024006980.invokeStatic(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x000000002400b8d0.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x000000002400be50.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
15:03:39  	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
15:03:39  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
15:03:39  	at java.base/java.lang.Thread.run(Thread.java:884)
15:03:39  Caused by: java.lang.NullPointerException: Cannot invoke "java.lang.Number.intValue()" because the return value of "sun.invoke.util.ValueConversions.primitiveConversion(sun.invoke.util.Wrapper, java.lang.Object, boolean)" is null
15:03:39  	at java.base/sun.invoke.util.ValueConversions.unboxInteger(ValueConversions.java:81)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x00000000241130d0.invokeStatic(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x0000000024115670.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x0000000024116d00.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x00000000b032b9a0.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.invokeImpl(DirectConstructorHandleAccessor.java:92)
15:03:39  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:67)
15:03:39  	... 41 more
15:03:39  test IllegalArgumentsTest.wrongArgumentType(): failure
15:03:39  java.lang.reflect.InvocationTargetException
15:03:39  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:72)
15:03:39  	at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
15:03:39  	at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
15:03:39  	at IllegalArgumentsTest.wrongArgumentType(IllegalArgumentsTest.java:49)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x0000000024110540.invokeVirtual(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x00000000241127d0.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x00000000b032b9a0.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:154)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
15:03:39  	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
15:03:39  	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
15:03:39  	at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
15:03:39  	at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
15:03:39  	at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
15:03:39  	at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
15:03:39  	at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
15:03:39  	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
15:03:39  	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
15:03:39  	at org.testng.TestRunner$$Lambda$69/0x00000000240d8528.accept(Unknown Source)
15:03:39  	at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
15:03:39  	at org.testng.TestRunner.privateRun(TestRunner.java:764)
15:03:39  	at org.testng.TestRunner.run(TestRunner.java:585)
15:03:39  	at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
15:03:39  	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
15:03:39  	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
15:03:39  	at org.testng.SuiteRunner.run(SuiteRunner.java:286)
15:03:39  	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
15:03:39  	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
15:03:39  	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
15:03:39  	at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
15:03:39  	at org.testng.TestNG.runSuites(TestNG.java:1069)
15:03:39  	at org.testng.TestNG.run(TestNG.java:1037)
15:03:39  	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
15:03:39  	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x0000000024006980.invokeStatic(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x000000002400b8d0.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x000000002400be50.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
15:03:39  	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
15:03:39  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
15:03:39  	at java.base/java.lang.Thread.run(Thread.java:884)
15:03:39  Caused by: java.lang.ClassCastException: java.lang.Class incompatible with java.lang.Number
15:03:39  	at java.base/sun.invoke.util.ValueConversions.primitiveConversion(ValueConversions.java:247)
15:03:39  	at java.base/sun.invoke.util.ValueConversions.unboxInteger(ValueConversions.java:81)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x00000000241130d0.invokeStatic(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x0000000024115670.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x0000000024116d00.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x00000000b032b9a0.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.invokeImpl(DirectConstructorHandleAccessor.java:92)
15:03:39  	at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:67)
15:03:39  	... 41 more
15:03:39  test IllegalArgumentsTest.wrongReceiver(): success
15:03:39  
15:03:39  ===============================================
15:03:39  java/lang/reflect/IllegalArgumentsTest.java
15:03:39  Total tests run: 4, Passes: 2, Failures: 2, Skips: 0
15:03:39  ===============================================
15:03:39  
15:03:39  STDERR:
15:03:39  java.lang.Exception: failures: 2
15:03:39  	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:96)
15:03:39  	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
15:03:39  	at java.lang.invoke.LambdaForm$DMH/0x0000000024006980.invokeStatic(LambdaForm$DMH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x000000002400b8d0.invoke(LambdaForm$MH)
15:03:39  	at java.lang.invoke.LambdaForm$MH/0x000000002400be50.invokeExact_MT(LambdaForm$MH)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invokeImpl(DirectMethodHandleAccessor.java:155)
15:03:39  	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
15:03:39  	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
15:03:39  	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
15:03:39  	at java.base/java.lang.Thread.run(Thread.java:884)
15:03:39  
15:03:39  JavaTest Message: Test threw exception: java.lang.Exception: failures: 2

15:03:39  TEST RESULT: Failed. Execution failed: `main' threw exception: java.lang.Exception: failures: 2
15:03:39  --------------------------------------------------
15:06:36  Test results: passed: 796; failed: 1
15:06:54  
15:06:54  jdk_lang_0_FAILED

@babsingh
Copy link
Contributor Author

Failing Tests

TEST: java/lang/reflect/MethodHandleAccessorsTest.java#id0
TEST: java/lang/reflect/MethodHandleAccessorsTest.java#id1
TEST: java/lang/reflect/IllegalArgumentsTest.java

The above tests depend on iterating the stack trace to throw the correct exception: AccessorUtils.isIllegalArgument.

@fengxue-IS

@fengxue-IS
Copy link
Contributor

fengxue-IS commented Jan 19, 2022

@babsingh
I've tested with my local build that with #3627 the following tests passed:

java/lang/reflect/MethodHandleAccessorsTest.java#id0
java/lang/reflect/IllegalArgumentsTest.java

as with id1, I got the follow output, I think we would need to look at the test failure more closely.

STDOUT:

private final int MethodHandleAccessorsTest$Public.i, invoked with target: Public{i=100, s='null', b=9}, value: 100
    Got expected return: 100
test MethodHandleAccessorsTest.testFieldReadAccess("i", Public{i=100, s='null', b=9}, 100, [Ljava.lang.Throwable;@511b40ed): success

private final java.lang.String MethodHandleAccessorsTest$Public.s, invoked with target: Public{i=0, s='test', b=9}, value: test
    Got expected return: test
test MethodHandleAccessorsTest.testFieldReadAccess("s", Public{i=0, s='test', b=9}, "test", [Ljava.lang.Throwable;@511b40ed): success

private final java.lang.String MethodHandleAccessorsTest$Public.s, invoked with target: null, value: null
    Got expected exception: java.lang.NullPointerException
test MethodHandleAccessorsTest.testFieldReadAccess("s", null, "test", [Ljava.lang.Throwable;@57b455e2): success

private final java.lang.String MethodHandleAccessorsTest$Public.s, invoked with target: , value: null
    Got expected exception: java.lang.IllegalArgumentException: Can not set final java.lang.String field MethodHandleAccessorsTest$Public.s to java.lang.String
test MethodHandleAccessorsTest.testFieldReadAccess("s", "", "test", [Ljava.lang.Throwable;@626043dd): success

private byte MethodHandleAccessorsTest$Public.b, invoked with target: , value: null
    Got expected exception: java.lang.IllegalArgumentException: Can not set byte field MethodHandleAccessorsTest$Public.b to java.lang.String
test MethodHandleAccessorsTest.testFieldReadAccess("b", "", 0, [Ljava.lang.Throwable;@626043dd): success

private final int MethodHandleAccessorsTest$Public.i, invoked with target: Public{i=200, s='null', b=9}, value: 200
    Got expected return: 200
test MethodHandleAccessorsTest.testFieldWriteAccess("i", Public{i=200, s='null', b=9}, 100, 200, [Ljava.lang.Throwable;@511b40ed): success

private final int MethodHandleAccessorsTest$Public.i, invoked with target: Public{i=10, s='null', b=9}, value: 10
    Got expected return: 10
test MethodHandleAccessorsTest.testFieldWriteAccess("i", Public{i=10, s='null', b=9}, 100, 10, [Ljava.lang.Throwable;@511b40ed): success

private final java.lang.String MethodHandleAccessorsTest$Public.s, invoked with target: Public{i=0, s='newValue', b=9}, value: newValue
    Got expected return: newValue
test MethodHandleAccessorsTest.testFieldWriteAccess("s", Public{i=0, s='newValue', b=9}, "test", "newValue", [Ljava.lang.Throwable;@511b40ed): success

private final java.lang.String MethodHandleAccessorsTest$Public.s, invoked with target: null, value: null
    Got expected exception: java.lang.NullPointerException
test MethodHandleAccessorsTest.testFieldWriteAccess("s", null, "test", "dummy", [Ljava.lang.Throwable;@57b455e2): success

private byte MethodHandleAccessorsTest$Public.b, invoked with target: Public{i=0, s='null', b=1}, value: null
    Got expected exception: java.lang.IllegalArgumentException: Can not set byte field MethodHandleAccessorsTest$Public.b to null value
test MethodHandleAccessorsTest.testFieldWriteAccess("b", Public{i=0, s='null', b=1}, 1, null, [Ljava.lang.Throwable;@4b3c9a35): success

private byte MethodHandleAccessorsTest$Public.b, invoked with target: Public{i=0, s='null', b=1}, value: null
    Got expected exception: java.lang.IllegalArgumentException: Can not set byte field MethodHandleAccessorsTest$Public.b to java.lang.Long
test MethodHandleAccessorsTest.testFieldWriteAccess("b", Public{i=0, s='null', b=1}, 1, 10, [Ljava.lang.Throwable;@4b3c9a35): success

private static java.lang.String MethodHandleAccessorsTest$Public.name, invoked with target: null, value: null
    Got expected exception: java.lang.IllegalArgumentException: Can not set static java.lang.String field MethodHandleAccessorsTest$Public.name to java.lang.Object
test MethodHandleAccessorsTest.testFieldWriteAccess("name", null, "name", java.lang.Object@33f68de6, [Ljava.lang.Throwable;@4b3c9a35): success

private final int MethodHandleAccessorsTest$Public.i, invoked with target: Public{i=100, s='null', b=9}, value: null
    Got expected exception: java.lang.IllegalArgumentException: Can not set final int field MethodHandleAccessorsTest$Public.i to java.lang.Object
test MethodHandleAccessorsTest.testFieldWriteAccess("i", Public{i=100, s='null', b=9}, 100, java.lang.Object@33f68de6, [Ljava.lang.Throwable;@4b3c9a35): success

public static void MethodHandleAccessorsTest$Thrower.throws_exception(java.lang.RuntimeException), invoked with target: null, args: [java.lang.NullPointerException: NPE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.NullPointerException: NPE

public MethodHandleAccessorsTest$Thrower(java.lang.RuntimeException), invoked with args: [java.lang.NullPointerException: NPE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.NullPointerException: NPE
test MethodHandleAccessorsTest.testInvocationTargetException(java.lang.NullPointerException@45ee7f59, [Ljava.lang.Throwable;@18053219): success

public static void MethodHandleAccessorsTest$Thrower.throws_exception(java.lang.RuntimeException), invoked with target: null, args: [java.lang.IllegalArgumentException: IAE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.IllegalArgumentException: IAE

public MethodHandleAccessorsTest$Thrower(java.lang.RuntimeException), invoked with args: [java.lang.IllegalArgumentException: IAE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.IllegalArgumentException: IAE
test MethodHandleAccessorsTest.testInvocationTargetException(java.lang.IllegalArgumentException@bebeb28c, [Ljava.lang.Throwable;@9abe89f1): success

public static void MethodHandleAccessorsTest$Thrower.throws_exception(java.lang.RuntimeException), invoked with target: null, args: [java.lang.ClassCastException: CCE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.ClassCastException: CCE

public MethodHandleAccessorsTest$Thrower(java.lang.RuntimeException), invoked with args: [java.lang.ClassCastException: CCE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.ClassCastException: CCE
test MethodHandleAccessorsTest.testInvocationTargetException(java.lang.ClassCastException@c9cb3b58, [Ljava.lang.Throwable;@32da8780): success

public int MethodHandleAccessorsTest$$Lambda$92/0x000000008c0f39b0.applyAsInt(int), invoked with target: MethodHandleAccessorsTest$$Lambda$92/0x000000008c0f39b0@ca1be026, args: [12]
    Got expected return: 12
test MethodHandleAccessorsTest.testLambdaProxyClass(): success

public static int MethodHandleAccessorsTest.varargs(int[]), invoked with target: null, args: [[I@402740]
    Got expected return: 6
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs", [Ljava.lang.Class;@a1b33abd, null, [Ljava.lang.Object;@5c73bb47, 6, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.varargs(int[]), invoked with target: null, args: [[I@818c8264]
    Got expected return: 0
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs", [Ljava.lang.Class;@a1b33abd, null, [Ljava.lang.Object;@54e3ffb9, 0, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.varargs(int[]), invoked with target: null, args: [null]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.NullPointerException
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs", [Ljava.lang.Class;@a1b33abd, null, [Ljava.lang.Object;@c205699c, 0, [Ljava.lang.Throwable;@244dc0b2): success

public static int MethodHandleAccessorsTest.varargs_primitive(int,int[]), invoked with target: null, args: [1, [I@6db2dd1]
    Got expected return: 105
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs_primitive", [Ljava.lang.Class;@7d809326, null, [Ljava.lang.Object;@69d63d99, 105, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.varargs_primitive(int,int[]), invoked with target: null, args: [1, [I@b495e106]
    Got expected return: 100
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs_primitive", [Ljava.lang.Class;@7d809326, null, [Ljava.lang.Object;@620eb274, 100, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.varargs_primitive(int,int[]), invoked with target: null, args: [1, null]
    Got expected return: 1
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs_primitive", [Ljava.lang.Class;@7d809326, null, [Ljava.lang.Object;@d6c9815f, 1, [Ljava.lang.Throwable;@511b40ed): success

public static java.lang.String MethodHandleAccessorsTest.varargs_object(java.lang.String,java.lang.String[]), invoked with target: null, args: [a, [Ljava.lang.String;@cd532841]
    Got expected return: a[b,c]
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs_object", [Ljava.lang.Class;@195c55cb, null, [Ljava.lang.Object;@7bb6097c, "a[b,c]", [Ljava.lang.Throwable;@511b40ed): success

public static java.lang.String MethodHandleAccessorsTest.varargs_object(java.lang.String,java.lang.String[]), invoked with target: null, args: [a, [Ljava.lang.String;@ffe42dc0]
    Got expected return: a[]
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs_object", [Ljava.lang.Class;@195c55cb, null, [Ljava.lang.Object;@29be3221, "a[]", [Ljava.lang.Throwable;@511b40ed): success

public static java.lang.String MethodHandleAccessorsTest.varargs_object(java.lang.String,java.lang.String[]), invoked with target: null, args: [a, null]
    Got expected return: a
test MethodHandleAccessorsTest.testMethodsWithVarargs("varargs_object", [Ljava.lang.Class;@195c55cb, null, [Ljava.lang.Object;@cabe4edd, "a", [Ljava.lang.Throwable;@511b40ed): success

public static void MethodHandleAccessorsTest.public_static_V(), invoked with target: null, args: []
    Got expected return: null
test MethodHandleAccessorsTest.testNoArgMethod("public_static_V", null, [Ljava.lang.Object;@cb3c1ff7, null, [Ljava.lang.Throwable;@511b40ed): success

public static void MethodHandleAccessorsTest.public_static_V(), invoked with target: null, args: null
    Got expected return: null
test MethodHandleAccessorsTest.testNoArgMethod("public_static_V", null, null, null, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.public_static_I(), invoked with target: null, args: []
    Got expected return: 42
test MethodHandleAccessorsTest.testNoArgMethod("public_static_I", null, [Ljava.lang.Object;@cb3c1ff7, 42, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.public_static_I(), invoked with target: null, args: null
    Got expected return: 42
test MethodHandleAccessorsTest.testNoArgMethod("public_static_I", null, null, 42, [Ljava.lang.Throwable;@511b40ed): success

public void MethodHandleAccessorsTest.public_V(), invoked with target: MethodHandleAccessorsTest@1352d930, args: []
    Got expected return: null
test MethodHandleAccessorsTest.testNoArgMethod("public_V", MethodHandleAccessorsTest@1352d930, [Ljava.lang.Object;@cb3c1ff7, null, [Ljava.lang.Throwable;@511b40ed): success

public void MethodHandleAccessorsTest.public_V(), invoked with target: MethodHandleAccessorsTest@1352d930, args: null
    Got expected return: null
test MethodHandleAccessorsTest.testNoArgMethod("public_V", MethodHandleAccessorsTest@1352d930, null, null, [Ljava.lang.Throwable;@511b40ed): success

public int MethodHandleAccessorsTest.public_I(), invoked with target: MethodHandleAccessorsTest@1352d930, args: []
    Got expected return: 42
test MethodHandleAccessorsTest.testNoArgMethod("public_I", MethodHandleAccessorsTest@1352d930, [Ljava.lang.Object;@cb3c1ff7, 42, [Ljava.lang.Throwable;@511b40ed): success

public int MethodHandleAccessorsTest.public_I(), invoked with target: MethodHandleAccessorsTest@1352d930, args: null
    Got expected return: 42
test MethodHandleAccessorsTest.testNoArgMethod("public_I", MethodHandleAccessorsTest@1352d930, null, 42, [Ljava.lang.Throwable;@511b40ed): success

private static void MethodHandleAccessorsTest.private_static_V(), invoked with target: null, args: []
    Got expected return: null
test MethodHandleAccessorsTest.testNoArgMethod("private_static_V", null, [Ljava.lang.Object;@cb3c1ff7, null, [Ljava.lang.Throwable;@511b40ed): success

private static int MethodHandleAccessorsTest.private_static_I(), invoked with target: null, args: []
    Got expected return: 42
test MethodHandleAccessorsTest.testNoArgMethod("private_static_I", null, [Ljava.lang.Object;@cb3c1ff7, 42, [Ljava.lang.Throwable;@511b40ed): success

private void MethodHandleAccessorsTest.private_V(), invoked with target: MethodHandleAccessorsTest@1352d930, args: []
    Got expected return: null
test MethodHandleAccessorsTest.testNoArgMethod("private_V", MethodHandleAccessorsTest@1352d930, [Ljava.lang.Object;@cb3c1ff7, null, [Ljava.lang.Throwable;@511b40ed): success

private int MethodHandleAccessorsTest.private_I(), invoked with target: MethodHandleAccessorsTest@1352d930, args: []
    Got expected return: 42
test MethodHandleAccessorsTest.testNoArgMethod("private_I", MethodHandleAccessorsTest@1352d930, [Ljava.lang.Object;@cb3c1ff7, 42, [Ljava.lang.Throwable;@511b40ed): success

public void MethodHandleAccessorsTest.public_V(), invoked with target: null, args: null
    Got expected exception: java.lang.NullPointerException
test MethodHandleAccessorsTest.testNoArgMethod("public_V", null, null, null, [Ljava.lang.Throwable;@57b455e2): success

public static void MethodHandleAccessorsTest.public_static_I_V(int), invoked with target: null, args: [12]
    Got expected return: null
test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_V", int, null, [Ljava.lang.Object;@f999d164, null, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.public_static_I_I(int), invoked with target: null, args: [12]
    Got expected return: 12
test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_I", int, null, [Ljava.lang.Object;@ea7e9c43, 12, [Ljava.lang.Throwable;@511b40ed): success

public void MethodHandleAccessorsTest.public_I_V(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [12]
    Got expected return: null
test MethodHandleAccessorsTest.testOneArgMethod("public_I_V", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@44538428, null, [Ljava.lang.Throwable;@511b40ed): success

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [12]
    Got expected return: 12
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@573ae638, 12, [Ljava.lang.Throwable;@511b40ed): success

private static void MethodHandleAccessorsTest.private_static_I_V(int), invoked with target: null, args: [12]
    Got expected return: null
test MethodHandleAccessorsTest.testOneArgMethod("private_static_I_V", int, null, [Ljava.lang.Object;@23f443d0, null, [Ljava.lang.Throwable;@511b40ed): success

private static int MethodHandleAccessorsTest.private_static_I_I(int), invoked with target: null, args: [12]
    Got expected return: 12
test MethodHandleAccessorsTest.testOneArgMethod("private_static_I_I", int, null, [Ljava.lang.Object;@8d1fda1b, 12, [Ljava.lang.Throwable;@511b40ed): success

private void MethodHandleAccessorsTest.private_I_V(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [12]
    Got expected return: null
test MethodHandleAccessorsTest.testOneArgMethod("private_I_V", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@e2a7313, null, [Ljava.lang.Throwable;@511b40ed): success

private int MethodHandleAccessorsTest.private_I_I(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [12]
    Got expected return: 12
test MethodHandleAccessorsTest.testOneArgMethod("private_I_I", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@6fc79493, 12, [Ljava.lang.Throwable;@511b40ed): success

public static int MethodHandleAccessorsTest.public_static_I_I(int), invoked with target: null, args: [a]
    Got expected exception: java.lang.IllegalArgumentException: argument type mismatch
test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_I", int, null, [Ljava.lang.Object;@44b5cd0f, null, [Ljava.lang.Throwable;@2aca336c): success

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [a]
    Got expected exception: java.lang.IllegalArgumentException: argument type mismatch
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@11818e7, null, [Ljava.lang.Throwable;@2aca336c): success

public static int MethodHandleAccessorsTest.public_static_I_I(int), invoked with target: null, args: [12, 13]
    Got expected exception: java.lang.IllegalArgumentException: wrong number of arguments
test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_I", int, null, [Ljava.lang.Object;@30f7cee3, null, [Ljava.lang.Throwable;@66e8a34d): success

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [12, 13]
    Got expected exception: java.lang.IllegalArgumentException: wrong number of arguments
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@b91a10e3, null, [Ljava.lang.Throwable;@66e8a34d): success

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: java.lang.Object@6aff74b6, args: [12]
    Got expected exception: java.lang.IllegalArgumentException: object is not an instance of declaring class
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, java.lang.Object@6aff74b6, [Ljava.lang.Object;@eed0837d, 12, [Ljava.lang.Throwable;@c38a053): success

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: null, args: [12]
    Got expected exception: java.lang.NullPointerException
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, null, [Ljava.lang.Object;@84fcab86, 12, [Ljava.lang.Throwable;@57b455e2): success

public static void MethodHandleAccessorsTest.public_static_I_V(int), invoked with target: null, args: null
    Got expected exception: java.lang.IllegalArgumentException: wrong number of arguments
test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_V", int, null, null, null, [Ljava.lang.Throwable;@e7a3f001): success

public static void MethodHandleAccessorsTest.public_static_I_V(int), invoked with target: null, args: [null]
test MethodHandleAccessorsTest.testOneArgMethod("public_static_I_V", int, null, [Ljava.lang.Object;@e43afdd, null, [Ljava.lang.Throwable;@3eea1f53): failure
java.lang.RuntimeException: jdk.internal.reflect.DelegatingMethodAccessorImpl for method: public static void MethodHandleAccessorsTest.public_static_I_V(int) test failure
	at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:359)
	at MethodHandleAccessorsTest.testOneArgMethod(MethodHandleAccessorsTest.java:523)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
	at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
	at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
	at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
	at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
	at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
	at org.testng.TestRunner.privateRun(TestRunner.java:764)
	at org.testng.TestRunner.run(TestRunner.java:585)
	at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
	at org.testng.SuiteRunner.run(SuiteRunner.java:286)
	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
	at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
	at org.testng.TestNG.runSuites(TestNG.java:1069)
	at org.testng.TestNG.run(TestNG.java:1037)
	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
	at java.base/java.lang.Thread.run(Thread.java:884)
Caused by: java.lang.AssertionError: Exception thrown (see cause) but expected exceptions were different (see suppressed)
	at MethodHandleAccessorsTest.fail(MethodHandleAccessorsTest.java:349)
	at MethodHandleAccessorsTest.checkException(MethodHandleAccessorsTest.java:328)
	at MethodHandleAccessorsTest.chechResult(MethodHandleAccessorsTest.java:304)
	at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:240)
	at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:357)
	... 34 more
	Suppressed: java.lang.IllegalArgumentException
		at MethodHandleAccessorsTest.<clinit>(MethodHandleAccessorsTest.java:416)
		at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
		at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:76)
		at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:53)
		at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
		at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
		at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:23)
		at org.testng.internal.InstanceCreator.instantiateUsingDefaultConstructor(InstanceCreator.java:193)
		at org.testng.internal.InstanceCreator.createInstanceUsingObjectFactory(InstanceCreator.java:113)
		at org.testng.internal.InstanceCreator.createInstance(InstanceCreator.java:79)
		at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:109)
		at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:167)
		at org.testng.TestClass.getInstances(TestClass.java:102)
		at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:82)
		at org.testng.TestClass.init(TestClass.java:74)
		at org.testng.TestClass.<init>(TestClass.java:39)
		at org.testng.TestRunner.initMethods(TestRunner.java:457)
		at org.testng.TestRunner.init(TestRunner.java:336)
		at org.testng.TestRunner.init(TestRunner.java:289)
		at org.testng.TestRunner.<init>(TestRunner.java:180)
		at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:613)
		at org.testng.SuiteRunner.init(SuiteRunner.java:178)
		at org.testng.SuiteRunner.<init>(SuiteRunner.java:112)
		at org.testng.TestNG.createSuiteRunner(TestNG.java:1306)
		at org.testng.TestNG.createSuiteRunners(TestNG.java:1282)
		at org.testng.TestNG.runSuitesLocally(TestNG.java:1131)
		... 10 more
Caused by: java.lang.IllegalArgumentException: argument type mismatch
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
	at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:232)
	... 35 more

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: null
    Got expected exception: java.lang.IllegalArgumentException: wrong number of arguments
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, MethodHandleAccessorsTest@847deb2d, null, null, [Ljava.lang.Throwable;@e7a3f001): success

public int MethodHandleAccessorsTest.public_I_I(int), invoked with target: MethodHandleAccessorsTest@847deb2d, args: [null]
test MethodHandleAccessorsTest.testOneArgMethod("public_I_I", int, MethodHandleAccessorsTest@847deb2d, [Ljava.lang.Object;@e83919b5, null, [Ljava.lang.Throwable;@3eea1f53): failure
java.lang.RuntimeException: jdk.internal.reflect.DelegatingMethodAccessorImpl for method: public int MethodHandleAccessorsTest.public_I_I(int) test failure
	at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:359)
	at MethodHandleAccessorsTest.testOneArgMethod(MethodHandleAccessorsTest.java:523)
	at jdk.internal.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
	at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:599)
	at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
	at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
	at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
	at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
	at java.base/java.util.ArrayList.forEach(ArrayList.java:1511)
	at org.testng.TestRunner.privateRun(TestRunner.java:764)
	at org.testng.TestRunner.run(TestRunner.java:585)
	at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
	at org.testng.SuiteRunner.run(SuiteRunner.java:286)
	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
	at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
	at org.testng.TestNG.runSuites(TestNG.java:1069)
	at org.testng.TestNG.run(TestNG.java:1037)
	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:94)
	at com.sun.javatest.regtest.agent.TestNGRunner.main(TestNGRunner.java:54)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
	at java.base/java.lang.reflect.Method.invoke(Method.java:577)
	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:127)
	at java.base/java.lang.Thread.run(Thread.java:884)
Caused by: java.lang.AssertionError: Exception thrown (see cause) but expected exceptions were different (see suppressed)
	at MethodHandleAccessorsTest.fail(MethodHandleAccessorsTest.java:349)
	at MethodHandleAccessorsTest.checkException(MethodHandleAccessorsTest.java:328)
	at MethodHandleAccessorsTest.chechResult(MethodHandleAccessorsTest.java:304)
	at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:240)
	at MethodHandleAccessorsTest.doTest(MethodHandleAccessorsTest.java:357)
	... 33 more
	Suppressed: java.lang.IllegalArgumentException
		at MethodHandleAccessorsTest.<clinit>(MethodHandleAccessorsTest.java:416)
		at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
		at java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:76)
		at java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:53)
		at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
		at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:483)
		at org.testng.internal.ObjectFactoryImpl.newInstance(ObjectFactoryImpl.java:23)
		at org.testng.internal.InstanceCreator.instantiateUsingDefaultConstructor(InstanceCreator.java:193)
		at org.testng.internal.InstanceCreator.createInstanceUsingObjectFactory(InstanceCreator.java:113)
		at org.testng.internal.InstanceCreator.createInstance(InstanceCreator.java:79)
		at org.testng.internal.ClassImpl.getDefaultInstance(ClassImpl.java:109)
		at org.testng.internal.ClassImpl.getInstances(ClassImpl.java:167)
		at org.testng.TestClass.getInstances(TestClass.java:102)
		at org.testng.TestClass.initTestClassesAndInstances(TestClass.java:82)
		at org.testng.TestClass.init(TestClass.java:74)
		at org.testng.TestClass.<init>(TestClass.java:39)
		at org.testng.TestRunner.initMethods(TestRunner.java:457)
		at org.testng.TestRunner.init(TestRunner.java:336)
		at org.testng.TestRunner.init(TestRunner.java:289)
		at org.testng.TestRunner.<init>(TestRunner.java:180)
		at org.testng.SuiteRunner$DefaultTestRunnerFactory.newTestRunner(SuiteRunner.java:613)
		at org.testng.SuiteRunner.init(SuiteRunner.java:178)
		at org.testng.SuiteRunner.<init>(SuiteRunner.java:112)
		at org.testng.TestNG.createSuiteRunner(TestNG.java:1306)
		at org.testng.TestNG.createSuiteRunners(TestNG.java:1282)
		at org.testng.TestNG.runSuitesLocally(TestNG.java:1131)
		... 10 more
Caused by: java.lang.IllegalArgumentException: argument type mismatch
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:76)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:52)
	at MethodHandleAccessorsTest.doTestAccessor(MethodHandleAccessorsTest.java:232)
	... 34 more

private MethodHandleAccessorsTest$Private(), invoked with args: []
    Got expected return: Private{i=0}

private MethodHandleAccessorsTest$Private(), invoked with args: null
    Got expected return: Private{i=0}

private MethodHandleAccessorsTest$Private(int), invoked with args: [12]
    Got expected return: Private{i=12}

public MethodHandleAccessorsTest$Abstract(), invoked with args: null
    Got expected exception: java.lang.InstantiationException
test MethodHandleAccessorsTest.testOtherConstructors(): success

public MethodHandleAccessorsTest$Public(), invoked with args: []
    Got expected return: Public{i=0, s='null', b=9}
test MethodHandleAccessorsTest.testPublicConstructors(null, [Ljava.lang.Object;@e956ada0, Public{i=0, s='null', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(), invoked with args: null
    Got expected return: Public{i=0, s='null', b=9}
test MethodHandleAccessorsTest.testPublicConstructors(null, null, Public{i=0, s='null', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(int), invoked with args: [12]
    Got expected return: Public{i=12, s='null', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@11de8e6e, [Ljava.lang.Object;@c61bf874, Public{i=12, s='null', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(java.lang.String), invoked with args: [a]
    Got expected return: Public{i=0, s='a', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@cde8c238, [Ljava.lang.Object;@d7045e03, Public{i=0, s='a', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(int,int[]), invoked with args: [1, [I@6e84962b]
    Got expected return: Public{i=105, s='null', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@6647301d, [Ljava.lang.Object;@79f19ed, Public{i=105, s='null', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(int,int[]), invoked with args: [1, [I@615f42ee]
    Got expected return: Public{i=100, s='null', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@c5a7470b, [Ljava.lang.Object;@9a266f1e, Public{i=100, s='null', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(int,int[]), invoked with args: [1, null]
    Got expected return: Public{i=1, s='null', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@83ac0a16, [Ljava.lang.Object;@a3ca8980, Public{i=1, s='null', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(java.lang.String,java.lang.String[]), invoked with args: [a, [Ljava.lang.String;@4745c5dd]
    Got expected return: Public{i=0, s='a[b,c]', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@3d6be509, [Ljava.lang.Object;@b7b6b6d0, Public{i=0, s='a[b,c]', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(java.lang.String,java.lang.String[]), invoked with args: [a, [Ljava.lang.String;@ef40b608]
    Got expected return: Public{i=0, s='a[]', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@c205ae7e, [Ljava.lang.Object;@6f491e6d, Public{i=0, s='a[]', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(java.lang.String,java.lang.String[]), invoked with args: [a, null]
    Got expected return: Public{i=0, s='a', b=9}
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@7bbe9c65, [Ljava.lang.Object;@babd632e, Public{i=0, s='a', b=9}, [Ljava.lang.Throwable;@511b40ed): success

public MethodHandleAccessorsTest$Public(int), invoked with args: [a]
    Got expected exception: java.lang.IllegalArgumentException: argument type mismatch
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@deffe6aa, [Ljava.lang.Object;@505012ee, null, [Ljava.lang.Throwable;@2aca336c): success

public MethodHandleAccessorsTest$Public(int), invoked with args: [12, 13]
    Got expected exception: java.lang.IllegalArgumentException: wrong number of arguments
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@7b223952, [Ljava.lang.Object;@53aac085, null, [Ljava.lang.Throwable;@66e8a34d): success

public MethodHandleAccessorsTest$Public(int), invoked with args: null
    Got expected exception: java.lang.IllegalArgumentException: wrong number of arguments
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@7ec66195, null, null, [Ljava.lang.Throwable;@e7a3f001): success

public MethodHandleAccessorsTest$Public(java.lang.RuntimeException), invoked with args: [java.lang.NullPointerException: NPE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.NullPointerException: NPE
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@e879af01, [Ljava.lang.Object;@288788a, null, [Ljava.lang.Throwable;@18053219): success

public MethodHandleAccessorsTest$Public(java.lang.RuntimeException), invoked with args: [java.lang.IllegalArgumentException: IAE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.IllegalArgumentException: IAE
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@49596618, [Ljava.lang.Object;@d7249306, null, [Ljava.lang.Throwable;@9abe89f1): success

public MethodHandleAccessorsTest$Public(java.lang.RuntimeException), invoked with args: [java.lang.ClassCastException: CCE]
    Got expected exception: java.lang.reflect.InvocationTargetException
                with cause: java.lang.ClassCastException: CCE
test MethodHandleAccessorsTest.testPublicConstructors([Ljava.lang.Class;@ff531c12, [Ljava.lang.Object;@de2ebaf1, null, [Ljava.lang.Throwable;@32da8780): success

public static final int MethodHandleAccessorsTest$Public.STATIC_FINAL, invoked with target: Public{i=0, s='null', b=9}, value: 1
    Got expected return: 1
test MethodHandleAccessorsTest.testStaticFinalFields(): success

===============================================
java/lang/reflect/MethodHandleAccessorsTest.java#id1
Total tests run: 75, Passes: 73, Failures: 2, Skips: 0
===============================================

babsingh added a commit to babsingh/aqa-tests that referenced this issue Jan 20, 2022
DelegateTest was fixed by eclipse-openj9/openj9#14177.
IllegalArgumentsTest is disabled due to eclipse-openj9/openj9#14084.

Signed-off-by: Babneet Singh <[email protected]>
babsingh added a commit to babsingh/aqa-tests that referenced this issue Jan 20, 2022
DelegateTest was fixed by eclipse-openj9/openj9#14177.

IllegalArgumentsTest is disabled due to eclipse-openj9/openj9#14084.

Signed-off-by: Babneet Singh <[email protected]>
@babsingh
Copy link
Contributor Author

re #14084 (comment)

java/lang/reflect/MethodHandleAccessorsTest.java#id1 failure happens because OpenJ9 does have the same exception message. OpenJ9 throws the correct exception: IllegalArgumentException. No exception message is expected by the test but OpenJ9 throws the following message: argument type mismatch. If there is a spec requirement for the message, then OpenJ9 will need to be updated. Otherwise, we can update the test to check for the message thrown by OpenJ9.

MethodHandleAccessorsTest.java#id1 is run with jdk.reflect.useDirectMethodHandle=false i.e. JEP416 is disabled and OpenJ9 uses the old core reflection support.

Failing test code: MethodHandleAccessorsTest.java#L487-L492. Refer to the public_static_I_V(int) and public_I_I(int) cases.

In OpenJ9, the above exception is thrown from two locations:

The exception is thrown based on the output of pushReflectArguments:

pushReflectArguments(J9VMThread *currentThread, j9object_t parameterTypes, j9object_t arguments)

@fengxue-IS
Copy link
Contributor

TODO: remove https://github.com/ibmruntimes/openj9-openjdk-jdk/blob/66c9122d0faa1473c464087bfde75949b070c10e/test/jdk/java/lang/reflect/MethodHandleAccessorsTest.java#L334-L336 from test so actual exception message is ignored when testing

Mesbah-Alam pushed a commit to adoptium/aqa-tests that referenced this issue Jan 20, 2022
DelegateTest was fixed by eclipse-openj9/openj9#14177.

IllegalArgumentsTest is disabled due to eclipse-openj9/openj9#14084.

Signed-off-by: Babneet Singh <[email protected]>
@babsingh
Copy link
Contributor Author

babsingh commented Feb 7, 2022

Closing this issue .. The intermittent failures for java/lang/reflect/IllegalArgumentsTest.java are fixed via #14419. java/lang/reflect/IllegalArgumentsTest.java is re-enabled via: adoptium/aqa-tests#3322.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants