py.test gives me an "import file mismatch" error. I believe its because I have test modules with the same name under different packages (see below).
Someone posted an identical question here: py.test - test discovery failure when tests in different directories are called the same. Unfortunately, none of the responses work for me.
I've also read the manual. I've tried not including the __init__.py
files in the test directories per the manual but that doesn't seem to make a difference.
The "app_class1" and "app_class2" directories each contain a test module named test_create.py.
Here is how my code is organized
/app
-setup.py
/app
-app.py
-__init__.py
/test
- __init__.py
/app_class1
- __init__.py
- test_create.py
/app_class2
- __init__.py
- test_create.py
Any help is greatly appreciated. Thank you.
P.S. I would have commented on the referenced conversation but my reputation isn't high enough to do so.