Currently my project's directory is organized as the following structure:
.
+-- module1
+-- module2
...
+-- moduleN
+-- test
+-- test_module1_item1.py
...
+-- test_moduleN_itemM.py
But when I execute py.test in my upper level directory, it throws an error like:
ImportError: No module named 'module1'
How the imports in the test files should be declared? Or how my project structure should be defined in order to the tests be separated from the rest of the code?
__init__.pypresent? Seems like you are not finding your module.