nose-devs/nose — Issue #19: ImportError running nosetests on namespace package in subdirectory on Windows
Author: jpellerin
Created: 2011-12-14 15:55:20+00:00
State: closed

On Windows only, if I create a project that shares a namespace with another
project on which it depends, and the child project has a
packages=find_packages('src') parameter, the tests will fail when they
reference the parent project.

I originally described the problem at
http://mail.python.org/pipermail/distutils-sig/2008-June/009595.html

What steps will reproduce the problem?
1. On Windows XP or Vista, install Python 2.5.2, setuptools==0.6c8
2. Expand the two packages, myns.projA and myns.projB from zip file (attached)
3. in myns.projA run "python setup.py develop"
3.5. Install nose manually; there appears to be a different issue if nose
is installed via tests_require= during the same step as the tests are run.
4. In myns.projB run "python setup.py test"

What is the expected output? What do you see instead?
nosetests should run with "Ran 0 tests in 0.032s" (or similar).
Instead, the error is received:

"C:\Users\jaraco\projects\distutils_namespace\myns.projB\test\testBasic.py",
line 1, in
from myns.projA.modA import funcA
ImportError: No module named projA.modA

Please reference the distutils-sig thread for more details. Attached you
will find the two sample projects that reproduce the issue.

Google Code Info:
Issue #: 197
Author: jaracosan
Created On: 2008-06-30T16:01:03.000Z
Closed On: