mirror of
https://github.com/dense-analysis/ale.git
synced 2026-11-01 18:12:16 +08:00
Make the nearest file search result absolute paths, and add tests to cover it.
This commit is contained in:
1 parent
7c2a16e149
commit
654a172473
4 files changed
+20
-1
No files matched your search
@@ -0,0 +1,11 @@
|
||||
Execute(Open a file some directory down):
|
||||
silent! cd /testplugin/test
|
||||
:e! top/middle/bottom/dummy.txt
|
||||
|
||||
Then(We should be able to find a configuration file further up):
|
||||
AssertEqual expand('%:p:h:h:h:h') . '/top/example.ini', ale#util#FindNearestFile(bufnr('%'), 'example.ini')
|
||||
|
||||
Execute(Do nothing):
|
||||
|
||||
Then(We shouldn't find anything for files which don't match):
|
||||
AssertEqual '', ale#util#FindNearestFile(bufnr('%'), 'cantfindthis')
|
||||
Whitespace-only changes.
Whitespace-only changes.
Reference in new issue
Block a user