vim-pyunit
vim-pyunit copied to clipboard
Fixed erroneous search of test and source files in nested folders
Hello,
I might have found a solution to issue #22. It passes the automated tests, and finds the proper file even from a nested directory inside the project root. It seems the _relpath
function in ftplugin/python_pyunit.vim
should be called with the full path and not the path relative to project root (see the diff).
In @holandes22's case, with let g:PyUnitTestsStructure = "nose"
, doing:
cd project/project
vim foo/bar.py
and then hitting F8, should work (i.e. no need to be at the project root).
This is my first pull request, so my apologies if it's not in the right form (please be nice :-) ).