title: Setuptools - how to run unittest test suite when tests are not in main directory?
body: <p>I have a following module structure:</p>
  
  <pre><code>main
  -&gt;module
  ---&gt;tests
  -----&gt;test_module.py
  ---&gt;module.py
  -&gt;setup.py
  </code></pre>
  
  <p>I have unit tests implemented using <code>unittest</code> package. When following this <a href="https://stackoverflow.com/questions/17001010/how-to-run-unittest-discover-from-python-setup-py-test">answer</a> I set my <code>setup.py</code> file to be:</p>
  
  <pre><code>from setuptools import setup
  
  setup(
      name='module',
      packages=['module', ],
      test_suite='module/tests',
  )
  </code></pre>
  
  <p>Produced the following error message:</p>
  
  <blockquote>
    <p>====================================================================== ERROR: tests (unittest.loader._FailedTest)
    ---------------------------------------------------------------------- ImportError: Failed to import test module: tests Traceback (most
    recent call last):   File
    "/opt/conda/lib/python3.6/unittest/loader.py", line 153, in
    loadTestsFromName
        module = <strong>import</strong>(module_name) ModuleNotFoundError: No module named 'tests/module'</p>
    
    <hr>
    
    <p>Ran 1 test in 0.000s</p>
    
    <p>FAILED (errors=1) Test failed:  error: Test failed:
    </p>
  </blockquote>
  
  <p>When setting <code>test_suite='tests</code> I've got:</p>
  
  <blockquote>
    <p>====================================================================== ERROR: tests (unittest.loader._FailedTest)
    ---------------------------------------------------------------------- ImportError: Failed to import test module: tests Traceback (most
    recent call last):   File
    "/opt/conda/lib/python3.6/unittest/loader.py", line 153, in
    loadTestsFromName
        module = <strong>import</strong>(module_name) ModuleNotFoundError: No module named 'tests'</p>
    
    <hr>
    
    <p>Ran 1 test in 0.000s</p>
    
    <p>FAILED (errors=1) Test failed:  error: Test failed:
    </p>
  </blockquote>
  
  <p>Can someone help me with this?</p>