You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Elijah Zupancic <el...@zupancic.name> on 2012/04/01 23:44:12 UTC

[chain] Example tests using Mockito

I'm busy updating the cookbook for the Chain project to use examples
that make use of the new 2.0 generics features. As part of the effort,
I'm adding the cookbook example code to the apps directory and making
all of the examples compilable with Maven. For most cases, this is
straight forward, however in some cases the cookbook uses isolated
examples that depend on resources beyond the scope of the example. For
these cases I would like to import Mockito as a dependency just to
have a clean way to stub out resources out of scope for the example.

Some key points regarding what I propose:

* Mockito will NOT be added as a dependency to any of the actual chain
source code (or tests).
* Mockito will be added as a dependency only to code usage examples.
* Mockito uses the MIT license.
* Mockito will be referenced as a library using Maven from the examples section.

Thanks,
-Elijah

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: [chain] Example tests using Mockito

Posted by Simone Tripodi <si...@apache.org>.
Hi Elijah,

thanks a lot for the follow-up (and sorry for the late reply, I've
been off for few days).

I like the idea and I don't see any issue on using Mockito as test
dependency; moreover MIT license can be considered to be similar in
terms to the Apache License 2.0, see [1].

Looking forward to your next patch, all the best!
-Simo

[1] http://www.apache.org/legal/resolved.html#category-a


http://people.apache.org/~simonetripodi/
http://simonetripodi.livejournal.com/
http://twitter.com/simonetripodi
http://www.99soft.org/



On Sun, Apr 1, 2012 at 11:44 PM, Elijah Zupancic <el...@zupancic.name> wrote:
> I'm busy updating the cookbook for the Chain project to use examples
> that make use of the new 2.0 generics features. As part of the effort,
> I'm adding the cookbook example code to the apps directory and making
> all of the examples compilable with Maven. For most cases, this is
> straight forward, however in some cases the cookbook uses isolated
> examples that depend on resources beyond the scope of the example. For
> these cases I would like to import Mockito as a dependency just to
> have a clean way to stub out resources out of scope for the example.
>
> Some key points regarding what I propose:
>
> * Mockito will NOT be added as a dependency to any of the actual chain
> source code (or tests).
> * Mockito will be added as a dependency only to code usage examples.
> * Mockito uses the MIT license.
> * Mockito will be referenced as a library using Maven from the examples section.
>
> Thanks,
> -Elijah
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org