From a809c4fa3a781af7401d2f11ee5155caef081457 Mon Sep 17 00:00:00 2001 From: w0rp Date: Sun, 8 Oct 2017 23:26:50 +0100 Subject: Get more random tests to pass on Windows --- .../test_fusionlint_command_callback.vader | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) (limited to 'test/command_callback/test_fusionlint_command_callback.vader') diff --git a/test/command_callback/test_fusionlint_command_callback.vader b/test/command_callback/test_fusionlint_command_callback.vader index 5398066c..34a44133 100644 --- a/test/command_callback/test_fusionlint_command_callback.vader +++ b/test/command_callback/test_fusionlint_command_callback.vader @@ -1,24 +1,34 @@ Before: + Save g:ale_fuse_fusionlint_options + Save g:ale_fuse_fusionlint_executable + + unlet! g:ale_fuse_fusionlint_options + unlet! g:ale_fuse_fusionlint_executable + runtime ale_linters/fuse/fusionlint.vim After: + Restore + call ale#linter#Reset() - let g:ale_fuse_fusionlint_options = '' - let g:ale_fuse_fusionlint_executable = 'fusion-lint' Execute(The fuse fusionlint command callback should return the correct default string): - AssertEqual '''fusion-lint'' --filename %s -i', + AssertEqual ale#Escape('fusion-lint') . ' --filename %s -i', \ join(split(ale_linters#fuse#fusionlint#GetCommand(1))) Execute(The fuse fusionlint command callback should let you set options): let g:ale_fuse_fusionlint_options = '--example-option argument' - AssertEqual '''fusion-lint'' --example-option argument --filename %s -i', + AssertEqual + \ ale#Escape('fusion-lint') + \ . ' --example-option argument --filename %s -i', \ join(split(ale_linters#fuse#fusionlint#GetCommand(1))) Execute(The fusionlint executable should be configurable): let g:ale_fuse_fusionlint_executable = 'util/linter.fuse' AssertEqual 'util/linter.fuse', ale_linters#fuse#fusionlint#GetExecutable(1) - AssertEqual '''util/linter.fuse'' --filename %s -i', + AssertEqual + \ ale#Escape('util/linter.fuse') + \ . ' --filename %s -i', \ join(split(ale_linters#fuse#fusionlint#GetCommand(1))) -- cgit v1.2.3