[py-dev] Detect whether py.test is running

Frank Hempel red_socks at gmx.de
Sun Oct 17 10:59:45 CEST 2010


Am 16.10.2010 22:56, schrieb holger krekel:
...
> I drafted an example which should also work with py-1.3.1 as part of
> the examples section of the upcoming pytest docs:
> 
>     http://codespeak.net/~hpk/pytest/example/misc.html

I guess it's a typo:

"Usually it is a good idea to make application code behave differently
if called from a test."

It's usually a bad idea, isn't it?

Regards, Frank



More information about the Pytest-dev mailing list