[py-dev] bug in py.test
Carl Friedrich Bolz
cfbolz at gmx.de
Mon Mar 27 20:28:21 CEST 2006
Hi!
Ondrej Certik wrote:
[snip]
>
> The new module in the current directory is probably colliding with something in
> py.test. If I rename new to new2, then everything is fine and I got this
> result:
>
> ...
>
> def foo():
> E assert 1 == 0
>
>> assert 1 == 0
>
>
> [/tmp/test/abc-123</home/ondra/pytest/py-dist/py/code/source.py:215>:2]
> ================== tests finished: 21 failed in 1.46 seconds ===================
>
> One of my modules is called "new", so I have to rename it because if this.
>
> Is it a bug?
Not really, since the "new" module is really part of the standard
library (which makes e.g. renaming it a bit hard :-)
http://docs.python.org/lib/module-new.html
Any library that uses this standard library module would break if you
named your module new.
Thanks for being interested in py.test!
Cheers,
Carl Friedrich
More information about the py-dev
mailing list