-
Notifications
You must be signed in to change notification settings - Fork 239
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
condy arrayindexoutofboundsexception fix #665
base: master
Are you sure you want to change the base?
Conversation
If a (real-world) test is required, please have a look at the example provided with #688 |
On a whim, I pulled this branch, built it locally, and used the resulting artifact in my project. It did not work for me, but that could very well be because I did something wrong. Here's the build error (in my code) that I get when using JDK 11.0.8 + Jacoco 0.8.6 + JMockit 1.49-mod:
Here's the test code being compiled:
Here's the class under test:
These combos work:
|
the method ConstructorReflection.newInstanceUsingCompatibleConstructor takes two parameters. A class and a String. |
OK, mea culpa, and that's what I get for using a class in the 'internal' package. You are correct, and switching to the 'newInstanceUsingDefaultConstructor' method (rather than newInstanceUsingCompatibleConstructor) solved that unrelated issue. In my defense, "it used to work" 👍 My new answer, I forked this branch, and tried it in my own application (affected by the aforementioned issue). This code works for me. Take that for what it's worth. I'd love to see this pull request get released. Even if it is just a 'milestone' or 'beta', it resolves blocking issues for a number of folks, including myself. JMockit, as a library, seems to have gone from releases every 3-months, to no release in the last 9-months, and this fix languishing (without real comment) for 6-months. I don't mean to sound critical, I am a big proponent of this framework. Just hoping to see it move forward. |
I can confirm that this MR fix our problem with JMockit and Jacoco too. So with this MR I can use a newer version of Jacoco (I tested it with 0.8.6). I hope that it will be merged soon. I start to be little nervous because I love this project. |
Next year, once I am no longer working at home; no time for JMockit now. |
@rliesenfeld looking forward for this fix to land in the next release |
@rliesenfeld Can this get merged in? Love this project, but don't see much work on it recently. Is JMockit going to be maintained? I really hope so! |
@rliesenfeld This fix works for me. Can you please merge it and create a new release for mvnrepository.com? |
Works for my projects also. Recently did an investigation at work for our internal projects.
|
Any idea when it is going to be merged and a new release be available? |
Does anyone know when this will be merged and released? I'd prefer to use an official release instead of creating my own private jmockit jar. |
Hopefully I will have some time for this, in 2022. That said, I see it as really the fault of JaCoCo. The change they made that generates the Condy bytecode, was supposedly a performance optimization. However, no benchmarking was ever done (that I know of). IMO, the JaCoCo team should reconsider if generating such unusual bytecode is a good idea. |
Work for me too after a JDK bump JDK: 16 |
works for me too, because of Jacoco to SonarQube integration its becoming hard to skip any of these components :( |
It is surprising, why no more releases after Dec 2019 (v1.49)? |
@rliesenfeld As regards this fix from @vimil , if this PR were merged then it would unblock a lot of devs - many more than are listed above. (Plus maybe #736 if required too ?) |
Hope this can get fixed, I use jmockit for many years and I think it is the best testing tool for java. |
there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]>
there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]> (cherry picked from commit 2f3ed5a)
there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]> (cherry picked from commit 2f3ed5a)
…Rocks#23445) there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]> Signed-off-by: Moonm3n <[email protected]>
…Rocks#23445) there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]>
…Rocks#23445) there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]>
…Rocks#23445) there is conflicting with jdk11 + jmockit + jcoco0.85, and more details in jmockit/jmockit1#665 jmockit/jmockit1#615 Signed-off-by: zombee0 <[email protected]>
really hope this can get fixed, |
Is it possible to merge this PR and make a new release ? I have been blocked for a while now. |
this is to fix arrayindexoutofbounds issue when running jmockit in eclipse 2020.03 with code coverage