summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-06-07 14:02:29 +0100
committerw0rp <devw0rp@gmail.com>2017-06-07 14:02:29 +0100
commit7517fd82260f03cc3ab7f77c391b6f1ff7372c6a (patch)
treea57fe71dbd2cd41d4299bf9313e9ddd10f9e981d /test
parentedddb1910ba69ccfda938d81b7307bc1656128c8 (diff)
downloadale-7517fd82260f03cc3ab7f77c391b6f1ff7372c6a.zip
Move all functions for fixing things to autoload/ale/fixers, and only accept the lines of input where needed.
Diffstat (limited to 'test')
-rw-r--r--test/fixers/test_python_add_blank_lines_fixer.vader2
-rw-r--r--test/test_function_arg_count.vader4
2 files changed, 5 insertions, 1 deletions
diff --git a/test/fixers/test_python_add_blank_lines_fixer.vader b/test/fixers/test_python_add_blank_lines_fixer.vader
index 6a3c58da..04ae8b45 100644
--- a/test/fixers/test_python_add_blank_lines_fixer.vader
+++ b/test/fixers/test_python_add_blank_lines_fixer.vader
@@ -39,7 +39,7 @@ Given python(Some Python without blank lines):
pass
Execute(Blank lines should be added appropriately):
- let g:ale_fixers = {'python': ['ale#handlers#python#AddLinesBeforeControlStatements']}
+ let g:ale_fixers = {'python': ['add_blank_lines_for_python_control_statements']}
ALEFix
Expect python(Newlines should be added):
diff --git a/test/test_function_arg_count.vader b/test/test_function_arg_count.vader
index 748eed33..d256c403 100644
--- a/test/test_function_arg_count.vader
+++ b/test/test_function_arg_count.vader
@@ -39,3 +39,7 @@ Execute(We should be able to compute the argument count for lambdas):
AssertEqual 3, ale#util#FunctionArgCount({x,y,z->1})
AssertEqual 3, ale#util#FunctionArgCount({x,y,z,...->1})
endif
+
+Execute(We should be able to compute the argument count autoload functions not yet loaded):
+ AssertEqual 1, ale#util#FunctionArgCount(function('ale#fixers#yapf#Fix'))
+ AssertEqual 1, ale#util#FunctionArgCount('ale#fixers#yapf#Fix')