Closed evdzhan closed 10 years ago
Yes, I can reproduce the VerifyError on JMockit 1.10; the problem is already fixed in release 1.11 (issue #41).
Oh I am sorry!
I should have upgraded to the latest JMockit. Thank you for the quick reply. I will try the with the new version, hope it works.
Regards.
Hi, yet again!
So I have this issue that I can't debug. I have a custom JDialog which I am trying to mock. When I call it's super constructor and then I try to use try catch block, I am getting a java.lang.VerifyError.
Please note that you have to uncomment the try body in order to get the verifyError with my example.
Java 1.7.0_51 (32 bit). Win7 64 bit JMockit 1.10 If you need any further information let me know.
Regards.
import mockit.Mocked; import mockit.integration.junit4.JMockit; import org.junit.runner.RunWith; import javax.swing.JDialog; import java.awt.Frame;
@RunWith(JMockit.class) public class test { @Mocked private MyJDialog changeManagerDlg = null; @org.junit.Test public void test(){}
// System.out.println("Uncommenting this line causes java.lang.VerifyError"); } catch (Exception e) { e.printStackTrace(); } } } }