diff options
Diffstat (limited to 'test/fixers')
-rw-r--r-- | test/fixers/test_astyle_fixer_callback.vader | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/fixers/test_astyle_fixer_callback.vader b/test/fixers/test_astyle_fixer_callback.vader index 1cd6b394..086d283c 100644 --- a/test/fixers/test_astyle_fixer_callback.vader +++ b/test/fixers/test_astyle_fixer_callback.vader @@ -81,3 +81,16 @@ Execute(The astyle callback should find nearest default option file _astylrc): \ . ' --stdin=' . ale#Escape(targetfile) \ }, \ ale#fixers#astyle#Fix(bufnr('')) + +Execute(The astyle callback should find .astylrc in the same directory as src): + call ale#test#SetFilename('../test_cpp_project/dummy.cpp') + set filetype=cpp " The test fails without this + let targetfile = bufname(bufnr('%')) + + AssertEqual + \ { + \ 'command': ale#Escape('invalidpp') + \ . ' --project=.astylerc' + \ . ' --stdin=' . ale#Escape(targetfile) + \ }, + \ ale#fixers#astyle#Fix(bufnr('')) |