java.lang.VerifyError

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When changing portal source and target level to 1.7 the mockito throws exception when runnin integration tests contains static mocking. {noformat} Inconsistent stackmap frames at branch target 40 Exception Details: Location: com/liferay/portal/kernel/lar/ExportImportDateUtilTest.<init>()V @40: aload_1 Reason: Type uninitializedThis (current frame, locals[1]) is not assignable to 'com/liferay/portal/kernel/lar/ExportImportDateUtilTest' (stack [1]) Current Frame: bci: @26 flags: { flagThisUninit } locals: { uninitializedThis, uninitializedThis, top, 'java/lang/Object' } stack: { 'java/lang/Object', 'java/lang/Object' } Stackmap Frame: bci: @40 flags: { flagThisUninit } locals: { uninitializedThis, 'com/liferay/portal/kernel/lar/ExportImportDateUtilTest' } stack: { } Bytecode: 0000000: 2a4c 1300 1cb8 0022 03bd 0024 1300 25b8 0000010: 0029 b800 2f4e 2db2 0033 a500 0e2a 01c0 0000020: 0035 b700 39a7 0009 2bb7 003b 0157 b1 Stackmap Table: append_frame(@40,Object[#18]) chop_frame(@46,1) java.lang.VerifyError: Inconsistent stackmap frames at branch target 40 Exception Details: Location: com/liferay/portal/kernel/lar/ExportImportDateUtilTest.<init>()V @40: aload_1 Reason: Type uninitializedThis (current frame, locals[1]) is not assignable to 'com/liferay/portal/kernel/lar/ExportImportDateUtilTest' (stack [1]) Current Frame: bci: @26 flags: { flagThisUninit } locals: { uninitializedThis, uninitializedThis, top, 'java/lang/Object' } stack: { 'java/lang/Object', 'java/lang/Object' } Stackmap Frame: bci: @40 flags: { flagThisUninit } locals: { uninitializedThis, 'com/liferay/portal/kernel/lar/ExportImportDateUtilTest' } stack: { } Bytecode: 0000000: 2a4c 1300 1cb8 0022 03bd 0024 1300 25b8 0000010: 0029 b800 2f4e 2db2 0033 a500 0e2a 01c0 0000020: 0035 b700 39a7 0009 2bb7 003b 0157 b1 Stackmap Table: append_frame(@40,Object[#18]) chop_frame(@46,1) at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2531) at java.lang.Class.privateGetPublicMethods(Class.java:2651) at java.lang.Class.getMethods(Class.java:1467) at org.powermock.modules.junit4.internal.impl.PowerMockJUnit44RunnerDelegateImpl.getTestMethods(PowerMockJUnit44RunnerDelegateImpl.jav at org.powermock.modules.junit4.internal.impl.PowerMockJUnit44RunnerDelegateImpl.<init>(PowerMockJUnit44RunnerDelegateImpl.java:71) at org.powermock.modules.junit4.internal.impl.PowerMockJUnit49RunnerDelegateImpl.<init>(PowerMockJUnit49RunnerDelegateImpl.java:29) at java.lang.reflect.Constructor.newInstance(Constructor.java:526) at org.powermock.modules.junit4.common.internal.impl.JUnit4TestSuiteChunkerImpl.createDelegatorFromClassloader(JUnit4TestSuiteChunkerI ) at org.powermock.modules.junit4.common.internal.impl.JUnit4TestSuiteChunkerImpl.createDelegatorFromClassloader(JUnit4TestSuiteChunkerI at org.powermock.tests.utils.impl.AbstractTestSuiteChunkerImpl.createTestDelegators(AbstractTestSuiteChunkerImpl.java:217) at org.powermock.modules.junit4.common.internal.impl.JUnit4TestSuiteChunkerImpl.<init>(JUnit4TestSuiteChunkerImpl.java:59) at org.powermock.modules.junit4.common.internal.impl.AbstractCommonPowerMockRunner.<init>(AbstractCommonPowerMockRunner.java:32) at org.powermock.modules.junit4.PowerMockRunner.<init>(PowerMockRunner.java:33) at java.lang.reflect.Constructor.newInstance(Constructor.java:526) at java.lang.reflect.Constructor.newInstance(Constructor.java:526) Test com.liferay.portal.kernel.lar.ExportImportDateUtilTest FAILED {noformat} More details about the issue can be found on the Powermock official site: http://code.google.com/p/powermock/issues/detail?id=355 One possible solution is to upgrade the library to version 1.5.4 or later.
    via by Daniel Kocsis,
  • IntelliJ Unit Test issues
    via Stack Overflow by n00b
    ,
  • Builds but cannot run...
    via GitHub by kodpraktikanten
    ,
  • powermock
    via by Unknown author,
  • PowerMock and Java 7 (Java 1.7)
    via by Kevin Wong,
  • GitHub comment 375#124557669
    via GitHub by johanhaleby
    ,
  • GitHub comment 6#70095458
    via GitHub by danhaywood
    ,
    • java.lang.VerifyError: Inconsistent stackmap frames at branch target 40 Exception Details: Location: com/liferay/portal/kernel/lar/ExportImportDateUtilTest.<init>()V @40: aload_1 Reason: Type uninitializedThis (current frame, locals[1]) is not assignable to 'com/liferay/portal/kernel/lar/ExportImportDateUtilTest' (stack [1]) Current Frame: bci: @26 flags: { flagThisUninit } locals: { uninitializedThis, uninitializedThis, top, 'java/lang/Object' } stack: { 'java/lang/Object', 'java/lang/Object' } Stackmap Frame: bci: @40 flags: { flagThisUninit } locals: { uninitializedThis, 'com/liferay/portal/kernel/lar/ExportImportDateUtilTest' } stack: { } Bytecode: 0000000: 2a4c 1300 1cb8 0022 03bd 0024 1300 25b8 0000010: 0029 b800 2f4e 2db2 0033 a500 0e2a 01c0 0000020: 0035 b700 39a7 0009 2bb7 003b 0157 b1 Stackmap Table: append_frame(@40,Object[#18]) chop_frame(@46,1) at java.lang.Class.getDeclaredMethods0(Native Method) at java.lang.Class.privateGetDeclaredMethods(Class.java:2531) at java.lang.Class.privateGetPublicMethods(Class.java:2651) at java.lang.Class.getMethods(Class.java:1467)

    Users with the same issue

    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    3 more bugmates