在robolectric的使用中出现了
java.lang.VerifyError: Expecting a stackmap frame at branch target 37
Exception Details:
Location:
略
@3: ifnonnull
Reason:
Expected stackmap frame at this location.
Bytecode:
0x0000000: b200 57c7 0022 122e 594b c2b2 0057 c700
0x0000010: 0dbb 002e 59b7 006d b300 572a c3a7 0008
0x0000020: 4c2a c32b bfb2 0057 b0
Exception Handler Table:
bci [11, 29] => handler: 32
bci [32, 35] => handler: 32
在点击这里可见解决方案.
具体的解决如下
1.点击Edit configuration
2.选中对应的测试用例,选中Configuration->在VM options中填入
-ea -noverify
点击OK 允许即可
3. 运行的结果如下: (done)