Nosetests changes my sys.path. There is a flag to disable this.

Per the ever useful documentation from http://nose.readthedocs.org/en/latest/usage.html:

-P, –no-path-adjustment
Don’t make any changes to sys.path when loading tests [NOSE_NOPATH]

Tests were written with PyCharm. If I just executed the Python script with “python my_script_test.py” it worked well. If I however used nosetests like this “nosetests my_script_test.py” it would not work as I used sys.path in one of the configuration parameters. So this worked:

nosetests -P my_script_test.py