You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by James Carman <ja...@carmanconsulting.com> on 2010/08/01 01:22:58 UTC

Re: Disabling serialization in wicket tester....

Will mockito let you mock more than one class at once?   If so, you can add
Serializable to the list.

On Jul 31, 2010 5:40 PM, "Erik Brakkee" <er...@gmail.com> wrote:
> That my tests will not be equivalent is no big problem. In this case I am
> really unit testing the pages while mocking the backend. That allows me to
> also test anomalous behavior of the backend.
>
> In addition, I am also doing unit integration testing with rendering
wicket
> pages with an actual JPA backend with a relatively complete environment
> including transactions and JPA. So, overall my unit tests cover the
> functionality quite well.
>
> The trick I am doing now is storing the mock in a static variable of the
> test class and then creating a serializable proxy using LookupProxyFactory
(
>
http://utils.wamblee.org/support/general/apidocs/org/wamblee/general/LookupProxyFactory.html
)
> to lookup the mock dynamically. I guess this is screaming again for
another
> test utility on top of mockito for creating serializable mocks (if I
cannot
> solve it in wicket).
>
> Any suggestions on how to disable serialization in wicket tester?