I have a directory hierarchy containing tests, where I want to give the same name to test modules in different directories. For example,
/tests/xxx/test.py
/tests/yyy/test.py
nose2 discovery doesn't seem to handle this. I get an error as follows:
ImportError: 'test' module incorrectly imported from '/tests/xxx'. Expected '/tests/yyy'. Is this module globally installed?
Is there a way to handle this? It would make my life easier if I could give them the same name.
Try fitting this to your problem. Reloading the test module might work here.