Previously Mike Orr wrote:
> 
> On Mon, Jul 7, 2008 at 1:33 PM, Wichert Akkerman <[EMAIL PROTECTED]> wrote:
> >> What's wrong with using paste.loadapp to properly set 'g' for every
> >> test that needs it?  That way your test environment is the closest to
> >> the production environment -- which is the purpose of having tests in
> >> the first place.
> >
> > Unit tests want as little as possible of the full environment. And you
> > want to be able to unit test code that uses things like g.
> 
> Well, unit tests (as opposed to functional tests) should test the
> target routine as closely as possible, without the interference of
> something like 'g' which should be tested separately.  After all, a
> value on 'g' is the same as the value standalone.

You might want to unittest a method that uses g in some way. More
typically you may want to unit test something that stuffs data in c.

Wichert.

-- 
Wichert Akkerman <[EMAIL PROTECTED]>    It is simple to make things.
http://www.wiggy.net/                   It is hard to make things simple.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To post to this group, send email to pylons-discuss@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to