nickylin / powermock

Automatically exported from code.google.com/p/powermock
Apache License 2.0
0 stars 0 forks source link

PowerMockito + Mockito 1.9.5 NoClassDefFound #398

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It looks like Mockito 1.9.5 removed the MockitoInvocationHandler.java  class 
PowerMockito was counting on.

java.lang.NoClassDefFoundError: org/mockito/internal/MockitoInvocationHandler
    at org.powermock.api.mockito.PowerMockito.mock(PowerMockito.java:138)

Original issue reported on code.google.com by mellowaredev on 20 Jul 2012 at 5:53

GoogleCodeExporter commented 9 years ago
Hi,
I'm also getting same issue.

Original comment by shripad....@gmail.com on 31 Jul 2012 at 2:00

GoogleCodeExporter commented 9 years ago
I think Mockito has changed internally. PowerMock needs to catch up.

Original comment by johan.ha...@gmail.com on 4 Aug 2012 at 5:54

GoogleCodeExporter commented 9 years ago
Mockito definitely has changed and that class is no longer available.

Original comment by mellowaredev on 4 Aug 2012 at 6:54

GoogleCodeExporter commented 9 years ago
+1 on this one.. any ETA on the fix?
I'd like to avoid a downgrade if possible.
Thanks!

Original comment by pankajta...@gmail.com on 29 Aug 2012 at 1:03

GoogleCodeExporter commented 9 years ago
Sorry there's no ETA unfortunately. I'm incredibly busy and these things are 
typically really hard to fix :/

Original comment by johan.ha...@gmail.com on 29 Aug 2012 at 1:10

GoogleCodeExporter commented 9 years ago
Also I'd like to wait for the real 1.9.5 release since they may several 
additional changes internally which will mess up PowerMock again.

Original comment by johan.ha...@gmail.com on 29 Aug 2012 at 1:12

GoogleCodeExporter commented 9 years ago

Original comment by johan.ha...@gmail.com on 31 Aug 2012 at 6:23

GoogleCodeExporter commented 9 years ago
Hi Johan,
Do you know what version number you'll use when this is done?  1.4.13 or 1.5.0? 
 It's just that I'm writing some documentation for Mockito 1.9.5 at the moment, 
and I'd like to mention which version of PowerMock will be compatable with it.
Thanks.

Original comment by dmwallace.nz on 31 Aug 2012 at 7:45

GoogleCodeExporter commented 9 years ago
Not quite sure but I guess 1.4.13.

Original comment by johan.ha...@gmail.com on 31 Aug 2012 at 8:47

GoogleCodeExporter commented 9 years ago
I've made some good progress with this issue today  btw. There are some a few 
spring integrations tests failing and I think it's because PowerMock's new 
MockMaker cannot be found in classpath for some reason. I hope to find some 
more time to investigate soon.

Original comment by johan.ha...@gmail.com on 31 Aug 2012 at 8:49

GoogleCodeExporter commented 9 years ago
I've now implemented support for 1.9.5-rc1 in trunk. Please try it out by 
building from source and report an problems.

Original comment by johan.ha...@gmail.com on 1 Sep 2012 at 3:22

GoogleCodeExporter commented 9 years ago
That's fantastic news.  Thank you Johan.

Original comment by dmwallace.nz on 1 Sep 2012 at 6:28

GoogleCodeExporter commented 9 years ago
Great news indeed. In the past few months I have come to depend on Mockito and 
PowerMock so heavily that it drives me crazy that Mockito 1.9.5 rc1 cannot 
support PowerMock anymore. Please keep the communication open between Mockito 
and PowerMock. Thanks a lot for the great work.

Original comment by xudi...@gmail.com on 12 Sep 2012 at 2:45

GoogleCodeExporter commented 9 years ago
Could you try if it works for you? I'd like to release a new version but I 
really want to get someone to try it out so I feel more confident.

Original comment by johan.ha...@gmail.com on 12 Sep 2012 at 4:16

GoogleCodeExporter commented 9 years ago
Since no one else has commented I want to confirm that the changes in trunk 
work fine for me with the just released Mockito 1.9.5.

Hopefully a new version of PowerMock can be released soon.

Original comment by tom.fl...@gmail.com on 9 Oct 2012 at 5:35

GoogleCodeExporter commented 9 years ago
That is good news! I'm waiting for a new version of Javassist that I think will 
be release any day now before I release PowerMock.

Original comment by johan.ha...@gmail.com on 10 Oct 2012 at 6:05

GoogleCodeExporter commented 9 years ago
javassist 3.17.0-GA showed up on the maven central repo :)

Original comment by andrei.i...@gmail.com on 14 Nov 2012 at 12:00

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Hi! Where can I find patched version? JAR would be nice to have :)

Original comment by pawel.ur...@gmail.com on 16 Nov 2012 at 2:26

GoogleCodeExporter commented 9 years ago
There are some problems with the released version of Javassist that they will 
have to adress before a new version of PowerMock can be released.

Original comment by johan.ha...@gmail.com on 17 Nov 2012 at 12:09

GoogleCodeExporter commented 9 years ago
Is it safe to use version from trunk for now? Static mocking seams to be 
working.

Original comment by pawel.ur...@gmail.com on 17 Nov 2012 at 12:12

GoogleCodeExporter commented 9 years ago
I believe it's safe yes. I plan to release it as is as soon as the next version 
of javassist is released (without any changes unless someone commits a patch 
for something).

Original comment by johan.ha...@gmail.com on 17 Nov 2012 at 1:13

GoogleCodeExporter commented 9 years ago
What's the hold up with javassist 3.17.0-GA?

Original comment by tsuna...@gmail.com on 19 Nov 2012 at 1:27

GoogleCodeExporter commented 9 years ago
See http://code.google.com/p/powermock/issues/detail?id=355

Original comment by johan.ha...@gmail.com on 19 Nov 2012 at 7:09

GoogleCodeExporter commented 9 years ago
javassist 3.17.0GA released a couple of days ago. It is in maven central now.

Original comment by dana.ore...@workiva.com on 21 Nov 2012 at 3:55

GoogleCodeExporter commented 9 years ago
The problem is with 3.17.0-GA, so I guess we have to wait for either 3.17.1 or 
3.18.0 to come out.

Original comment by tsuna...@gmail.com on 21 Nov 2012 at 4:07