Re: Prefer Mockito?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: Prefer Mockito?

John Patrick
Just did comment regarding typo.

I also advocate Mockito, so also would be recommending that.

It appeared Mockito supported junit v5 earlier than others and
compared to previous versions remove boiler plate setup. Or I missed
those other frameworks supporting junit v5.
PowerMock might be agued that is supports static, but most of the code
i've reviewed just highlight most developer mock static
classes/methods incorrectly and end up just verifying the mock they
create.
Not touched/used JMock or EasyMock for about 10 years so no idea about them.

John


On Mon, 27 Apr 2020 at 15:14, Elliotte Rusty Harold <[hidden email]> wrote:

>
> Anyone have an opinion on recommending Mockito as our preferred mocking
> library?
>
> https://github.com/apache/maven-site/pull/158/files
>
> This doesn't require us to port old unit tests, though we can. Right now we
> have a mix of Mockito, JMock, PowerMock, and EasyMock spread out across the
> plugins.
>
> --
> Elliotte Rusty Harold
> [hidden email]

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Prefer Mockito?

rfscholte
People are bad readers.
I'd suggest to spend some time to replace those frameworks with mockito (and powermock tests should be rewritten or removed, there should be no reason to use it).
Otherwise we'll get more easymock tests or no PRs at all as people don't know how to use easymock.

I've just removed it from maven-assembly-plugin. 
Yes it takes some time, but at least there's again a better maintainable codebase.

Robert
On 27-4-2020 16:14:14, Elliotte Rusty Harold <[hidden email]> wrote:
Anyone have an opinion on recommending Mockito as our preferred mocking
library?

https://github.com/apache/maven-site/pull/158/files

This doesn't require us to port old unit tests, though we can. Right now we
have a mix of Mockito, JMock, PowerMock, and EasyMock spread out across the
plugins.

--
Elliotte Rusty Harold
[hidden email]