[Numpy-discussion] Interaction between Numpy and the nose framework (was : packaging scipy)
Mon Apr 7 11:38:25 CDT 2008
On Mon, Apr 7, 2008 at 4:25 PM, Stéfan van der Walt <firstname.lastname@example.org> wrote:
> On 07/04/2008, Matthieu Brucher <email@example.com> wrote:
> > BTW, I stumbled on something strange with the nose framework. If you from
> > numpy.testing import * in a test file, the nose framework will try to test
> > the testing module by calling every test* method.
> > I just mention it there because I think I'm not the only one to do this for
> > set_package_path, assert_equal, ...
> I've noticed that behaviour, too. Note, however, that you do not need
> to use set_package_path and friends with nose; you can instead do a
> fully qualified import:
> from numpy.submod.mod import foo
Actually, it was intentional to make the scipy.testing * space a more
limited version of the numpy testing space - in particular,
set_package_path was often being used unnecessarily (by me among
others) and was clearly leading to confusion. You do however have
assert_equal and friends with from scipy.testing import *, so I'd
strongly recommend you use that in preference to the numpy.testing
import within scipy.
More information about the Numpy-discussion