You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by Robert Burrell Donkin <ro...@gmail.com> on 2008/11/08 14:50:55 UTC
[mailet-base] Move mocks from test into main?
ATM there are a number of concrete mocks contained in
http://svn.apache.org/repos/asf/james/mailet/base/trunk/src/test/java/org/apache/james/test/mock/.
they aren't unit tests and have no dependencies on junit but are
useful when creating unit tests. i think they'd be better in main,
probably repackaged into org.apache.mailet.base.mock.
opinions?
objections?
- robert
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: [mailet-base] Move mocks from test into main?
Posted by Stefano Bagnara <ap...@bago.org>.
Robert Burrell Donkin ha scritto:
> On Sat, Nov 8, 2008 at 6:14 PM, Stefano Bagnara <ap...@bago.org> wrote:
>> Robert Burrell Donkin ha scritto:
>>> ATM there are a number of concrete mocks contained in
>>> http://svn.apache.org/repos/asf/james/mailet/base/trunk/src/test/java/org/apache/james/test/mock/.
>>> they aren't unit tests and have no dependencies on junit but are
>>> useful when creating unit tests. i think they'd be better in main,
>>> probably repackaged into org.apache.mailet.base.mock.
>>>
>>> opinions?
>> I prefer to use tests because tests is where I look for similar things,
>> but I'm not strong on this and I've no objections to this, if this helps
>> you moving forward.
>
> i'm agnostic
>
> the packaging needs to be rationalised. not particularly sure about
> the best package: org.apache.mailet.base.test.mock?
> org.apache.mailet.base.mock? org.apache.mailet.base.test?
org.apache.mailet.base.test
"Mock" could be misleading as that package does not contain "proper"
mocks (as for Fowler summary:
http://martinfowler.com/bliki/TestDouble.html). Fowler (and many other)
would call most of that classes "Fake".
Stefano
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: [mailet-base] Move mocks from test into main?
Posted by Robert Burrell Donkin <ro...@gmail.com>.
On Sat, Nov 8, 2008 at 6:14 PM, Stefano Bagnara <ap...@bago.org> wrote:
> Robert Burrell Donkin ha scritto:
>> ATM there are a number of concrete mocks contained in
>> http://svn.apache.org/repos/asf/james/mailet/base/trunk/src/test/java/org/apache/james/test/mock/.
>> they aren't unit tests and have no dependencies on junit but are
>> useful when creating unit tests. i think they'd be better in main,
>> probably repackaged into org.apache.mailet.base.mock.
>>
>> opinions?
>
> I prefer to use tests because tests is where I look for similar things,
> but I'm not strong on this and I've no objections to this, if this helps
> you moving forward.
i'm agnostic
the packaging needs to be rationalised. not particularly sure about
the best package: org.apache.mailet.base.test.mock?
org.apache.mailet.base.mock? org.apache.mailet.base.test?
- robert
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: [mailet-base] Move mocks from test into main?
Posted by Stefano Bagnara <ap...@bago.org>.
Robert Burrell Donkin ha scritto:
> ATM there are a number of concrete mocks contained in
> http://svn.apache.org/repos/asf/james/mailet/base/trunk/src/test/java/org/apache/james/test/mock/.
> they aren't unit tests and have no dependencies on junit but are
> useful when creating unit tests. i think they'd be better in main,
> probably repackaged into org.apache.mailet.base.mock.
>
> opinions?
I prefer to use tests because tests is where I look for similar things,
but I'm not strong on this and I've no objections to this, if this helps
you moving forward.
Stefano
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: [mailet-base] Move mocks from test into main?
Posted by Robert Burrell Donkin <ro...@gmail.com>.
On Sat, Nov 8, 2008 at 5:41 PM, David Jencks <da...@yahoo.com> wrote:
> How about a jar with the test classifier?
that's what we have ATM
base is a micro-library: 13 classes in src/main plus 6 mock-related
classes in src/test. so, we end up with two small jars.
i can see arguments both ways...
- robert
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: [mailet-base] Move mocks from test into main?
Posted by Stefano Bagnara <ap...@bago.org>.
David Jencks ha scritto:
> How about a jar with the test classifier?
This is what we already do ;-)
Stefano
> thanks
> david jencks
>
> On Nov 8, 2008, at 5:50 AM, Robert Burrell Donkin wrote:
>
>> ATM there are a number of concrete mocks contained in
>> http://svn.apache.org/repos/asf/james/mailet/base/trunk/src/test/java/org/apache/james/test/mock/.
>>
>> they aren't unit tests and have no dependencies on junit but are
>> useful when creating unit tests. i think they'd be better in main,
>> probably repackaged into org.apache.mailet.base.mock.
>>
>> opinions?
>>
>> objections?
>>
>> - robert
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
>> For additional commands, e-mail: server-dev-help@james.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
> For additional commands, e-mail: server-dev-help@james.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org
Re: [mailet-base] Move mocks from test into main?
Posted by David Jencks <da...@yahoo.com>.
How about a jar with the test classifier?
thanks
david jencks
On Nov 8, 2008, at 5:50 AM, Robert Burrell Donkin wrote:
> ATM there are a number of concrete mocks contained in
> http://svn.apache.org/repos/asf/james/mailet/base/trunk/src/test/java/org/apache/james/test/mock/
> .
> they aren't unit tests and have no dependencies on junit but are
> useful when creating unit tests. i think they'd be better in main,
> probably repackaged into org.apache.mailet.base.mock.
>
> opinions?
>
> objections?
>
> - robert
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
> For additional commands, e-mail: server-dev-help@james.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org