diff options
author | w0rp <devw0rp@gmail.com> | 2017-12-19 18:23:09 +0000 |
---|---|---|
committer | w0rp <devw0rp@gmail.com> | 2017-12-19 18:23:09 +0000 |
commit | 1568bf81281507aaaa8c71af85e244e94bd2924c (patch) | |
tree | 4694f6d24b82b6b57a7b934aebe68ea1c09ec57b /test/command_callback | |
parent | 73f61514c9039e7e863da3544f251d3f8d7d1956 (diff) | |
download | ale-1568bf81281507aaaa8c71af85e244e94bd2924c.zip |
Fix the mscs tests on Windows, and use the improved Simplify for all tests instead.v1.7.0
Diffstat (limited to 'test/command_callback')
26 files changed, 65 insertions, 65 deletions
diff --git a/test/command_callback/test_brakeman_command_callback.vader b/test/command_callback/test_brakeman_command_callback.vader index f98801b3..1772c9d6 100644 --- a/test/command_callback/test_brakeman_command_callback.vader +++ b/test/command_callback/test_brakeman_command_callback.vader @@ -25,7 +25,7 @@ Execute(The brakeman command callback should find a valid Rails app root): AssertEqual \ 'brakeman -f json -q -p ' - \ . ale#Escape(ale#path#Winify(g:dir . '/../ruby_fixtures/valid_rails_app')), + \ . ale#Escape(ale#path#Simplify(g:dir . '/../ruby_fixtures/valid_rails_app')), \ ale_linters#ruby#brakeman#GetCommand(bufnr('')) Execute(The brakeman command callback should include configured options): @@ -35,5 +35,5 @@ Execute(The brakeman command callback should include configured options): AssertEqual \ 'brakeman -f json -q --combobulate -p ' - \ . ale#Escape(ale#path#Winify(g:dir . '/../ruby_fixtures/valid_rails_app')), + \ . ale#Escape(ale#path#Simplify(g:dir . '/../ruby_fixtures/valid_rails_app')), \ ale_linters#ruby#brakeman#GetCommand(bufnr('')) diff --git a/test/command_callback/test_c_cppcheck_command_callbacks.vader b/test/command_callback/test_c_cppcheck_command_callbacks.vader index e6fe1b7d..1643e3e0 100644 --- a/test/command_callback/test_c_cppcheck_command_callbacks.vader +++ b/test/command_callback/test_c_cppcheck_command_callbacks.vader @@ -43,7 +43,7 @@ Execute(cppcheck for C++ should detect compile_commands.json files): call ale#test#SetFilename('cppcheck_paths/one/foo.cpp') AssertEqual - \ 'cd ' . ale#Escape(ale#path#Winify(g:dir . '/cppcheck_paths/one')) . ' && ' + \ 'cd ' . ale#Escape(ale#path#Simplify(g:dir . '/cppcheck_paths/one')) . ' && ' \ . ale#Escape('cppcheck') \ . ' -q --language=c --project=compile_commands.json --enable=style %t', \ ale_linters#c#cppcheck#GetCommand(bufnr('')) diff --git a/test/command_callback/test_cpp_cppcheck_command_callbacks.vader b/test/command_callback/test_cpp_cppcheck_command_callbacks.vader index f7b37d4f..2c9d7298 100644 --- a/test/command_callback/test_cpp_cppcheck_command_callbacks.vader +++ b/test/command_callback/test_cpp_cppcheck_command_callbacks.vader @@ -43,7 +43,7 @@ Execute(cppcheck for C++ should detect compile_commands.json files): call ale#test#SetFilename('cppcheck_paths/one/foo.cpp') AssertEqual - \ 'cd ' . ale#Escape(ale#path#Winify(g:dir . '/cppcheck_paths/one')) . ' && ' + \ 'cd ' . ale#Escape(ale#path#Simplify(g:dir . '/cppcheck_paths/one')) . ' && ' \ . ale#Escape('cppcheck') \ . ' -q --language=c++ --project=compile_commands.json --enable=style %t', \ ale_linters#cpp#cppcheck#GetCommand(bufnr('')) diff --git a/test/command_callback/test_dartanalyzer_command_callback.vader b/test/command_callback/test_dartanalyzer_command_callback.vader index 6685ab4a..c7b51396 100644 --- a/test/command_callback/test_dartanalyzer_command_callback.vader +++ b/test/command_callback/test_dartanalyzer_command_callback.vader @@ -35,6 +35,6 @@ Execute(The .packages file should be set if detected): AssertEqual \ ale#Escape('dartanalyzer') - \ . ' --packages ' . ale#Escape(ale#path#Winify(g:dir . '/dart_paths/.packages')) + \ . ' --packages ' . ale#Escape(ale#path#Simplify(g:dir . '/dart_paths/.packages')) \ . ' %s', \ ale_linters#dart#dartanalyzer#GetCommand(bufnr('')) diff --git a/test/command_callback/test_flake8_command_callback.vader b/test/command_callback/test_flake8_command_callback.vader index 8cb4ded2..1784b81f 100644 --- a/test/command_callback/test_flake8_command_callback.vader +++ b/test/command_callback/test_flake8_command_callback.vader @@ -76,7 +76,7 @@ Execute(You should be able to set a custom executable and it should be escaped): Execute(The flake8 callbacks should detect virtualenv directories): silent execute 'file ' . fnameescape(g:dir . '/python_paths/with_virtualenv/subdir/foo/bar.py') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir . '/python_paths/with_virtualenv/env/' . b:bin_dir . '/flake8' \) @@ -95,35 +95,35 @@ Execute(The FindProjectRoot should detect the project root directory for namespa silent execute 'file ' . fnameescape(g:dir . '/python_paths/namespace_package_manifest/namespace/foo/bar.py') AssertEqual - \ ale#path#Winify(g:dir . '/python_paths/namespace_package_manifest'), + \ ale#path#Simplify(g:dir . '/python_paths/namespace_package_manifest'), \ ale#python#FindProjectRoot(bufnr('')) Execute(The FindProjectRoot should detect the project root directory for namespace package via setup.cf): silent execute 'file ' . fnameescape(g:dir . '/python_paths/namespace_package_setup/namespace/foo/bar.py') AssertEqual - \ ale#path#Winify(g:dir . '/python_paths/namespace_package_setup'), + \ ale#path#Simplify(g:dir . '/python_paths/namespace_package_setup'), \ ale#python#FindProjectRoot(bufnr('')) Execute(The FindProjectRoot should detect the project root directory for namespace package via pytest.ini): silent execute 'file ' . fnameescape(g:dir . '/python_paths/namespace_package_pytest/namespace/foo/bar.py') AssertEqual - \ ale#path#Winify(g:dir . '/python_paths/namespace_package_pytest'), + \ ale#path#Simplify(g:dir . '/python_paths/namespace_package_pytest'), \ ale#python#FindProjectRoot(bufnr('')) Execute(The FindProjectRoot should detect the project root directory for namespace package via tox.ini): silent execute 'file ' . fnameescape(g:dir . '/python_paths/namespace_package_tox/namespace/foo/bar.py') AssertEqual - \ ale#path#Winify(g:dir . '/python_paths/namespace_package_tox'), + \ ale#path#Simplify(g:dir . '/python_paths/namespace_package_tox'), \ ale#python#FindProjectRoot(bufnr('')) Execute(The FindProjectRoot should detect the project root directory for non-namespace package): silent execute 'file ' . fnameescape(g:dir . '/python_paths/no_virtualenv/subdir/foo/bar.py') AssertEqual - \ ale#path#Winify(g:dir . '/python_paths/no_virtualenv/subdir'), + \ ale#path#Simplify(g:dir . '/python_paths/no_virtualenv/subdir'), \ ale#python#FindProjectRoot(bufnr('')) " Some users currently run flake8 this way, so we should support it. diff --git a/test/command_callback/test_haml_hamllint_command_callback.vader b/test/command_callback/test_haml_hamllint_command_callback.vader index 68aa1e62..0d9b1e06 100644 --- a/test/command_callback/test_haml_hamllint_command_callback.vader +++ b/test/command_callback/test_haml_hamllint_command_callback.vader @@ -18,7 +18,7 @@ Execute(The default command should be correct): Execute(The command should have the .rubocop.yml prepended as an env var if one exists): call ale#test#SetFilename('../hamllint-test-files/rubocop-yml/subdir/file.haml') - let b:conf = ale#path#Winify(g:dir . '/../hamllint-test-files/rubocop-yml/.rubocop.yml') + let b:conf = ale#path#Simplify(g:dir . '/../hamllint-test-files/rubocop-yml/.rubocop.yml') if has('win32') " Windows uses 'set var=... && command' @@ -38,7 +38,7 @@ Execute(The command should have the .rubocop.yml prepended as an env var if one Execute(The command should have the nearest .haml-lint.yml set as --config if it exists): call ale#test#SetFilename('../hamllint-test-files/haml-lint-yml/subdir/file.haml') - let b:conf = ale#path#Winify(g:dir . '/../hamllint-test-files/haml-lint-yml/.haml-lint.yml') + let b:conf = ale#path#Simplify(g:dir . '/../hamllint-test-files/haml-lint-yml/.haml-lint.yml') AssertEqual \ 'haml-lint --config ' @@ -48,8 +48,8 @@ Execute(The command should have the nearest .haml-lint.yml set as --config if it Execute(The command should include a .rubocop.yml and a .haml-lint if both are found): call ale#test#SetFilename('../hamllint-test-files/haml-lint-and-rubocop/subdir/file.haml') - let b:conf_hamllint = ale#path#Winify(g:dir . '/../hamllint-test-files/haml-lint-and-rubocop/.haml-lint.yml') - let b:conf_rubocop = ale#path#Winify(g:dir . '/../hamllint-test-files/haml-lint-and-rubocop/.rubocop.yml') + let b:conf_hamllint = ale#path#Simplify(g:dir . '/../hamllint-test-files/haml-lint-and-rubocop/.haml-lint.yml') + let b:conf_rubocop = ale#path#Simplify(g:dir . '/../hamllint-test-files/haml-lint-and-rubocop/.rubocop.yml') if has('win32') " Windows uses 'set var=... && command' diff --git a/test/command_callback/test_javac_command_callback.vader b/test/command_callback/test_javac_command_callback.vader index fe545307..7823d030 100644 --- a/test/command_callback/test_javac_command_callback.vader +++ b/test/command_callback/test_javac_command_callback.vader @@ -122,7 +122,7 @@ Execute(The javac callback should detect source directories): AssertEqual \ 'cd ' . ale#Escape(expand('%:p:h')) . ' && javac -Xlint' \ . ' -sourcepath ' . ale#Escape( - \ ale#path#Winify(g:dir . '/java_paths/src/main/java/') + \ ale#path#Simplify(g:dir . '/java_paths/src/main/java/') \ ) \ . ' -d TEMP %t', \ GetCommand([]) @@ -136,7 +136,7 @@ Execute(The javac callback should combine detected source directories and classp \ 'cd ' . ale#Escape(expand('%:p:h')) . ' && javac -Xlint' \ . ' -cp ' . ale#Escape(join(['/foo/bar.jar', '/xyz/abc.jar'], g:cp_sep)) \ . ' -sourcepath ' . ale#Escape( - \ ale#path#Winify(g:dir . '/java_paths/src/main/java/') + \ ale#path#Simplify(g:dir . '/java_paths/src/main/java/') \ ) \ . ' -d TEMP %t', \ GetCommand([ @@ -166,8 +166,8 @@ Execute(The javac callback should include src/test/java for test paths): AssertEqual \ 'cd ' . ale#Escape(expand('%:p:h')) . ' && javac -Xlint' \ . ' -sourcepath ' . ale#Escape(join([ - \ ale#path#Winify(g:dir . '/java_paths/src/main/java/'), - \ ale#path#Winify(g:dir . '/java_paths/src/test/java/'), + \ ale#path#Simplify(g:dir . '/java_paths/src/main/java/'), + \ ale#path#Simplify(g:dir . '/java_paths/src/test/java/'), \ ], g:cp_sep)) \ . ' -d TEMP %t', \ GetCommand([]) @@ -180,8 +180,8 @@ Execute(The javac callback should include src/main/jaxb when available): AssertEqual \ 'cd ' . ale#Escape(expand('%:p:h')) . ' && javac -Xlint' \ . ' -sourcepath ' . ale#Escape(join([ - \ ale#path#Winify(g:dir . '/java_paths_with_jaxb/src/main/java/'), - \ ale#path#Winify(g:dir . '/java_paths_with_jaxb/src/main/jaxb/'), + \ ale#path#Simplify(g:dir . '/java_paths_with_jaxb/src/main/java/'), + \ ale#path#Simplify(g:dir . '/java_paths_with_jaxb/src/main/jaxb/'), \ ], g:cp_sep)) \ . ' -d TEMP %t', \ GetCommand([]) diff --git a/test/command_callback/test_less_stylelint_command_callback.vader b/test/command_callback/test_less_stylelint_command_callback.vader index d5aa3b97..a5912ecf 100644 --- a/test/command_callback/test_less_stylelint_command_callback.vader +++ b/test/command_callback/test_less_stylelint_command_callback.vader @@ -30,7 +30,7 @@ After: Execute(node_modules directories should be discovered): call ale#test#SetFilename('stylelint_paths/nested/testfile.less') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir \ . '/stylelint_paths/node_modules/.bin/stylelint' \) diff --git a/test/command_callback/test_lessc_command_callback.vader b/test/command_callback/test_lessc_command_callback.vader index 785c38c0..ec2899d1 100644 --- a/test/command_callback/test_lessc_command_callback.vader +++ b/test/command_callback/test_lessc_command_callback.vader @@ -30,7 +30,7 @@ After: Execute(node_modules directories should be discovered): call ale#test#SetFilename('lessc_paths/nested/testfile.less') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir \ . '/lessc_paths/node_modules/.bin/lessc' \) @@ -43,7 +43,7 @@ Execute(node_modules directories should be discovered): \ ale#Escape(b:executable) \ . ' --no-color --lint' \ . ' --include-path=' - \ . ale#Escape(ale#path#Winify(g:dir . '/lessc_paths/nested')) + \ . ale#Escape(ale#path#Simplify(g:dir . '/lessc_paths/nested')) \ . ' -', \ ale_linters#less#lessc#GetCommand(bufnr('')) @@ -61,7 +61,7 @@ Execute(The global override should work): \ ale#Escape('foobar') \ . ' --no-color --lint' \ . ' --include-path=' - \ . ale#Escape(ale#path#Winify(g:dir . '/lessc_paths/nested')) + \ . ale#Escape(ale#path#Simplify(g:dir . '/lessc_paths/nested')) \ . ' -', \ ale_linters#less#lessc#GetCommand(bufnr('')) @@ -76,7 +76,7 @@ Execute(Extra options should be configurable): \ ale#Escape('lessc') \ . ' --no-color --lint' \ . ' --include-path=' - \ . ale#Escape(ale#path#Winify(g:dir)) + \ . ale#Escape(ale#path#Simplify(g:dir)) \ . ' --whatever' \ . ' -', \ ale_linters#less#lessc#GetCommand(bufnr('')) diff --git a/test/command_callback/test_mypy_command_callback.vader b/test/command_callback/test_mypy_command_callback.vader index 4ccc008e..6a0add52 100644 --- a/test/command_callback/test_mypy_command_callback.vader +++ b/test/command_callback/test_mypy_command_callback.vader @@ -61,7 +61,7 @@ Execute(The mypy command should switch directories to the detected project root) \ 'mypy', \ ale_linters#python#mypy#GetExecutable(bufnr('')) AssertEqual - \ 'cd ' . ale#Escape(ale#path#Winify(g:dir . '/python_paths/no_virtualenv/subdir')) + \ 'cd ' . ale#Escape(ale#path#Simplify(g:dir . '/python_paths/no_virtualenv/subdir')) \ . ' && ' . ale#Escape('mypy') \ . ' --show-column-numbers ' \ . '--shadow-file %s %t %s', @@ -70,13 +70,13 @@ Execute(The mypy command should switch directories to the detected project root) Execute(The mypy callbacks should detect virtualenv directories and switch to the project root): silent execute 'file ' . fnameescape(g:dir . '/python_paths/with_virtualenv/subdir/foo/bar.py') - let b:executable = ale#path#Winify(g:dir . '/python_paths/with_virtualenv/env/' . b:bin_dir . '/mypy') + let b:executable = ale#path#Simplify(g:dir . '/python_paths/with_virtualenv/env/' . b:bin_dir . '/mypy') AssertEqual \ b:executable, \ ale_linters#python#mypy#GetExecutable(bufnr('')) AssertEqual - \ 'cd ' . ale#Escape(ale#path#Winify(g:dir . '/python_paths/with_virtualenv/subdir')) + \ 'cd ' . ale#Escape(ale#path#Simplify(g:dir . '/python_paths/with_virtualenv/subdir')) \ . ' && ' . ale#Escape(b:executable) \ . ' --show-column-numbers ' \ . '--shadow-file %s %t %s', @@ -90,7 +90,7 @@ Execute(You should able able to use the global mypy instead): \ 'mypy', \ ale_linters#python#mypy#GetExecutable(bufnr('')) AssertEqual - \ 'cd ' . ale#Escape(ale#path#Winify(g:dir . '/python_paths/with_virtualenv/subdir')) + \ 'cd ' . ale#Escape(ale#path#Simplify(g:dir . '/python_paths/with_virtualenv/subdir')) \ . ' && ' . ale#Escape('mypy') \ . ' --show-column-numbers ' \ . '--shadow-file %s %t %s', diff --git a/test/command_callback/test_ocaml_ols_callbacks.vader b/test/command_callback/test_ocaml_ols_callbacks.vader index 2c44dbc9..d10898fa 100644 --- a/test/command_callback/test_ocaml_ols_callbacks.vader +++ b/test/command_callback/test_ocaml_ols_callbacks.vader @@ -32,14 +32,14 @@ Execute(The project root should be detected correctly): call ale#test#SetFilename('ols_paths/file.ml') AssertEqual - \ ale#path#Winify(g:dir . '/ols_paths'), + \ ale#path#Simplify(g:dir . '/ols_paths'), \ ale#handlers#ols#GetProjectRoot(bufnr('')) Execute(The local executable should be used when available): call ale#test#SetFilename('ols_paths/file.ml') AssertEqual - \ ale#path#Winify(g:dir . '/ols_paths/node_modules/.bin/ocaml-language-server'), + \ ale#path#Simplify(g:dir . '/ols_paths/node_modules/.bin/ocaml-language-server'), \ ale#handlers#ols#GetExecutable(bufnr('')) Execute(The gloabl executable should always be used when use_global is set): diff --git a/test/command_callback/test_perlcritic_command_callback.vader b/test/command_callback/test_perlcritic_command_callback.vader index 8f339d31..6507868b 100644 --- a/test/command_callback/test_perlcritic_command_callback.vader +++ b/test/command_callback/test_perlcritic_command_callback.vader @@ -43,7 +43,7 @@ Execute(The command should be correct with g:ale_perl_perlcritic_showrules on): Execute(The command search for the profile file when set): let b:ale_perl_perlcritic_profile = 'README.md' - let b:readme_path = ale#path#Winify(expand('%:p:h:h:h') . '/README.md') + let b:readme_path = ale#path#Simplify(expand('%:p:h:h:h') . '/README.md') AssertEqual \ ale#Escape('perlcritic') . ' --verbose ''%l:%c %m\n'' --nocolor' diff --git a/test/command_callback/test_php_langserver_callbacks.vader b/test/command_callback/test_php_langserver_callbacks.vader index 0c7e69ef..0dc30630 100644 --- a/test/command_callback/test_php_langserver_callbacks.vader +++ b/test/command_callback/test_php_langserver_callbacks.vader @@ -33,10 +33,10 @@ Execute(Vendor executables should be detected): call ale#test#SetFilename('php-langserver-project/test.php') AssertEqual - \ ale#path#Winify(g:dir . '/php-langserver-project/vendor/bin/php-language-server.php'), + \ ale#path#Simplify(g:dir . '/php-langserver-project/vendor/bin/php-language-server.php'), \ ale_linters#php#langserver#GetExecutable(bufnr('')) AssertEqual - \ 'php ' . ale#Escape(ale#path#Winify( + \ 'php ' . ale#Escape(ale#path#Simplify( \ g:dir \ . '/php-langserver-project/vendor/bin/php-language-server.php' \ )), diff --git a/test/command_callback/test_puglint_command_callback.vader b/test/command_callback/test_puglint_command_callback.vader index 11946582..f9b4a856 100644 --- a/test/command_callback/test_puglint_command_callback.vader +++ b/test/command_callback/test_puglint_command_callback.vader @@ -21,12 +21,12 @@ Execute(puglint should detect local executables and package.json): call ale#test#SetFilename('puglint_project/test.pug') AssertEqual - \ ale#path#Winify(g:dir . '/puglint_project/node_modules/.bin/pug-lint'), + \ ale#path#Simplify(g:dir . '/puglint_project/node_modules/.bin/pug-lint'), \ ale_linters#pug#puglint#GetExecutable(bufnr('')) AssertEqual - \ ale#Escape(ale#path#Winify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) - \ . ' -c ' . ale#Escape(ale#path#Winify(g:dir . '/puglint_project/package.json')) + \ ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) + \ . ' -c ' . ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/package.json')) \ . ' -r inline %t', \ ale_linters#pug#puglint#GetCommand(bufnr('')) @@ -39,7 +39,7 @@ Execute(puglint should use global executables if configured): AssertEqual \ ale#Escape('pug-lint') - \ . ' -c ' . ale#Escape(ale#path#Winify(g:dir . '/puglint_project/package.json')) + \ . ' -c ' . ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/package.json')) \ . ' -r inline %t', \ ale_linters#pug#puglint#GetCommand(bufnr('')) @@ -47,8 +47,8 @@ Execute(puglint should detect .pug-lintrc): call ale#test#SetFilename('puglint_project/puglint_rc_dir/subdir/test.pug') AssertEqual - \ ale#Escape(ale#path#Winify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) - \ . ' -c ' . ale#Escape(ale#path#Winify(g:dir . '/puglint_project/puglint_rc_dir/.pug-lintrc')) + \ ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) + \ . ' -c ' . ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/puglint_rc_dir/.pug-lintrc')) \ . ' -r inline %t', \ ale_linters#pug#puglint#GetCommand(bufnr('')) @@ -56,8 +56,8 @@ Execute(puglint should detect .pug-lintrc.js): call ale#test#SetFilename('puglint_project/puglint_rc_js_dir/subdir/test.pug') AssertEqual - \ ale#Escape(ale#path#Winify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) - \ . ' -c ' . ale#Escape(ale#path#Winify(g:dir . '/puglint_project/puglint_rc_js_dir/.pug-lintrc.js')) + \ ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) + \ . ' -c ' . ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/puglint_rc_js_dir/.pug-lintrc.js')) \ . ' -r inline %t', \ ale_linters#pug#puglint#GetCommand(bufnr('')) @@ -65,7 +65,7 @@ Execute(puglint should detect .pug-lintrc.json): call ale#test#SetFilename('puglint_project/puglint_rc_json_dir/subdir/test.pug') AssertEqual - \ ale#Escape(ale#path#Winify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) - \ . ' -c ' . ale#Escape(ale#path#Winify(g:dir . '/puglint_project/puglint_rc_json_dir/.pug-lintrc.json')) + \ ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/node_modules/.bin/pug-lint')) + \ . ' -c ' . ale#Escape(ale#path#Simplify(g:dir . '/puglint_project/puglint_rc_json_dir/.pug-lintrc.json')) \ . ' -r inline %t', \ ale_linters#pug#puglint#GetCommand(bufnr('')) diff --git a/test/command_callback/test_pyflakes_command_callback.vader b/test/command_callback/test_pyflakes_command_callback.vader index 30a106c8..e8486ca8 100644 --- a/test/command_callback/test_pyflakes_command_callback.vader +++ b/test/command_callback/test_pyflakes_command_callback.vader @@ -33,7 +33,7 @@ Execute(The pyflakes executable should be configurable): Execute(The pyflakes executable should be run from the virtualenv path): call ale#test#SetFilename('python_paths/with_virtualenv/subdir/foo/bar.py') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir . '/python_paths/with_virtualenv/env/' . b:bin_dir . '/pyflakes' \) diff --git a/test/command_callback/test_pylint_command_callback.vader b/test/command_callback/test_pylint_command_callback.vader index 447409b2..1ff8e354 100644 --- a/test/command_callback/test_pylint_command_callback.vader +++ b/test/command_callback/test_pylint_command_callback.vader @@ -61,7 +61,7 @@ Execute(The pylint callbacks shouldn't detect virtualenv directories where they Execute(The pylint callbacks should detect virtualenv directories): silent execute 'file ' . fnameescape(g:dir . '/python_paths/with_virtualenv/subdir/foo/bar.py') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir . '/python_paths/with_virtualenv/env/' . b:bin_dir . '/pylint' \) diff --git a/test/command_callback/test_pyls_command_callback.vader b/test/command_callback/test_pyls_command_callback.vader index 9f9703d7..06ea718f 100644 --- a/test/command_callback/test_pyls_command_callback.vader +++ b/test/command_callback/test_pyls_command_callback.vader @@ -33,7 +33,7 @@ Execute(The pyls executable should be configurable): Execute(The pyls executable should be run from the virtualenv path): call ale#test#SetFilename('python_paths/with_virtualenv/subdir/foo/bar.py') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir . '/python_paths/with_virtualenv/env/' . b:bin_dir . '/pyls' \) diff --git a/test/command_callback/test_rails_best_practices_command_callback.vader b/test/command_callback/test_rails_best_practices_command_callback.vader index 7305f4a6..b4d2e82d 100644 --- a/test/command_callback/test_rails_best_practices_command_callback.vader +++ b/test/command_callback/test_rails_best_practices_command_callback.vader @@ -9,7 +9,7 @@ Before: let b:args = '--silent -f json' \ . ' --output-file ' . (has('win32') ? '%t' : '/dev/stdout') - let b:app_path = ale#path#Winify(g:dir . '/../ruby_fixtures/valid_rails_app') + let b:app_path = ale#path#Simplify(g:dir . '/../ruby_fixtures/valid_rails_app') let b:suffix = has('win32') ? '; type %t' : '' After: diff --git a/test/command_callback/test_reason_ols_callbacks.vader b/test/command_callback/test_reason_ols_callbacks.vader index ffe403f4..5fb39afe 100644 --- a/test/command_callback/test_reason_ols_callbacks.vader +++ b/test/command_callback/test_reason_ols_callbacks.vader @@ -32,14 +32,14 @@ Execute(The project root should be detected correctly): call ale#test#SetFilename('ols_paths/file.re') AssertEqual - \ ale#path#Winify(g:dir . '/ols_paths'), + \ ale#path#Simplify(g:dir . '/ols_paths'), \ ale#handlers#ols#GetProjectRoot(bufnr('')) Execute(The local executable should be used when available): call ale#test#SetFilename('ols_paths/file.re') AssertEqual - \ ale#path#Winify(g:dir . '/ols_paths/node_modules/.bin/ocaml-language-server'), + \ ale#path#Simplify(g:dir . '/ols_paths/node_modules/.bin/ocaml-language-server'), \ ale#handlers#ols#GetExecutable(bufnr('')) Execute(The gloabl executable should always be used when use_global is set): diff --git a/test/command_callback/test_rubocop_command_callback.vader b/test/command_callback/test_rubocop_command_callback.vader index fddf7145..f0aa194f 100644 --- a/test/command_callback/test_rubocop_command_callback.vader +++ b/test/command_callback/test_rubocop_command_callback.vader @@ -17,7 +17,7 @@ Execute(Executable should default to rubocop): AssertEqual \ ale#Escape('rubocop') \ . ' --format json --force-exclusion --stdin ' - \ . ale#Escape(ale#path#Winify(g:dir . '/dummy.rb')), + \ . ale#Escape(ale#path#Simplify(g:dir . '/dummy.rb')), \ ale_linters#ruby#rubocop#GetCommand(bufnr('')) Execute(Should be able to set a custom executable): @@ -26,7 +26,7 @@ Execute(Should be able to set a custom executable): AssertEqual \ ale#Escape('bin/rubocop') \ . ' --format json --force-exclusion --stdin ' - \ . ale#Escape(ale#path#Winify(g:dir . '/dummy.rb')), + \ . ale#Escape(ale#path#Simplify(g:dir . '/dummy.rb')), \ ale_linters#ruby#rubocop#GetCommand(bufnr('')) Execute(Setting bundle appends 'exec rubocop'): @@ -35,5 +35,5 @@ Execute(Setting bundle appends 'exec rubocop'): AssertEqual \ ale#Escape('path to/bundle') . ' exec rubocop' \ . ' --format json --force-exclusion --stdin ' - \ . ale#Escape(ale#path#Winify(g:dir . '/dummy.rb')), + \ . ale#Escape(ale#path#Simplify(g:dir . '/dummy.rb')), \ ale_linters#ruby#rubocop#GetCommand(bufnr('')) diff --git a/test/command_callback/test_rust_rls_callbacks.vader b/test/command_callback/test_rust_rls_callbacks.vader index e467fd96..693d6e9f 100644 --- a/test/command_callback/test_rust_rls_callbacks.vader +++ b/test/command_callback/test_rust_rls_callbacks.vader @@ -37,5 +37,5 @@ Execute(The project root should be detected correctly): call ale#test#SetFilename('rust-rls-project/test.rs') AssertEqual - \ ale#path#Winify(g:dir . '/rust-rls-project'), + \ ale#path#Simplify(g:dir . '/rust-rls-project'), \ ale_linters#rust#rls#GetProjectRoot(bufnr('')) diff --git a/test/command_callback/test_shellcheck_command_callback.vader b/test/command_callback/test_shellcheck_command_callback.vader index bf422b21..68694b67 100644 --- a/test/command_callback/test_shellcheck_command_callback.vader +++ b/test/command_callback/test_shellcheck_command_callback.vader @@ -12,7 +12,7 @@ Before: call ale#test#SetDirectory('/testplugin/test/command_callback') call ale#test#SetFilename('test.sh') - let b:prefix = 'cd ' . ale#Escape(ale#path#Winify(g:dir)) . ' && ' + let b:prefix = 'cd ' . ale#Escape(ale#path#Simplify(g:dir)) . ' && ' let b:suffix = ' -f gcc -' After: diff --git a/test/command_callback/test_slimlint_command_callback.vader b/test/command_callback/test_slimlint_command_callback.vader index d4dad4c4..38588a1f 100644 --- a/test/command_callback/test_slimlint_command_callback.vader +++ b/test/command_callback/test_slimlint_command_callback.vader @@ -20,7 +20,7 @@ Execute(The default command should be correct): Execute(The command should have the .rubocop.yml prepended as an env var if one exists): call ale#test#SetFilename('../slimlint-test-files/subdir/file.slim') - let b:conf = ale#path#Winify(g:dir . '/../slimlint-test-files/.rubocop.yml') + let b:conf = ale#path#Simplify(g:dir . '/../slimlint-test-files/.rubocop.yml') if has('win32') " Windows uses 'set var=... && command' diff --git a/test/command_callback/test_standard_command_callback.vader b/test/command_callback/test_standard_command_callback.vader index 279109e0..3dee2856 100644 --- a/test/command_callback/test_standard_command_callback.vader +++ b/test/command_callback/test_standard_command_callback.vader @@ -27,7 +27,7 @@ After: Execute(bin/cmd.js paths should be preferred): call ale#test#SetFilename('standard-test-files/with-cmd/testfile.js') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir \ . '/standard-test-files/with-cmd/node_modules/standard/bin/cmd.js' \) @@ -45,7 +45,7 @@ Execute(bin/cmd.js paths should be preferred): Execute(.bin directories should be used too): call ale#test#SetFilename('standard-test-files/with-bin/testfile.js') - let b:executable = ale#path#Winify( + let b:executable = ale#path#Simplify( \ g:dir \ . '/standard-test-files/with-bin/node_modules/.bin/standard' \) diff --git a/test/command_callback/test_swaglint_command_callback.vader b/test/command_callback/test_swaglint_command_callback.vader index 0f1d870e..51a10094 100644 --- a/test/command_callback/test_swaglint_command_callback.vader +++ b/test/command_callback/test_swaglint_command_callback.vader @@ -34,10 +34,10 @@ Execute(The yaml swaglint command callback should allow a local installation to call ale#test#SetFilename('swaglint_paths/docs/swagger.yaml') AssertEqual - \ ale#path#Winify(g:dir . '/swaglint_paths/node_modules/.bin/swaglint'), + \ ale#path#Simplify(g:dir . '/swaglint_paths/node_modules/.bin/swaglint'), \ ale_linters#yaml#swaglint#GetExecutable(bufnr('')) AssertEqual - \ ale#path#Winify(g:dir . '/swaglint_paths/node_modules/.bin/swaglint') + \ ale#path#Simplify(g:dir . '/swaglint_paths/node_modules/.bin/swaglint') \ . ' -r compact --stdin', \ ale_linters#yaml#swaglint#GetCommand(bufnr('')) diff --git a/test/command_callback/test_write_good_command_callback.vader b/test/command_callback/test_write_good_command_callback.vader index d9f00495..8d9e9a00 100644 --- a/test/command_callback/test_write_good_command_callback.vader +++ b/test/command_callback/test_write_good_command_callback.vader @@ -34,10 +34,10 @@ Execute(Should use the node_modules/.bin executable, if available): call ale#test#SetFilename('write-good-node-modules/test.txt') AssertEqual - \ ale#path#Winify(g:dir . '/write-good-node-modules/node_modules/.bin/write-good'), + \ ale#path#Simplify(g:dir . '/write-good-node-modules/node_modules/.bin/write-good'), \ ale#handlers#writegood#GetExecutable(bufnr('')) AssertEqual - \ ale#Escape(ale#path#Winify(g:dir . '/write-good-node-modules/node_modules/.bin/write-good')) + \ ale#Escape(ale#path#Simplify(g:dir . '/write-good-node-modules/node_modules/.bin/write-good')) \ . ' %t', \ ale#handlers#writegood#GetCommand(bufnr('')) @@ -45,11 +45,11 @@ Execute(Should use the node_modules/write-good executable, if available): call ale#test#SetFilename('write-good-node-modules-2/test.txt') AssertEqual - \ ale#path#Winify(g:dir . '/write-good-node-modules-2/node_modules/write-good/bin/write-good.js'), + \ ale#path#Simplify(g:dir . '/write-good-node-modules-2/node_modules/write-good/bin/write-good.js'), \ ale#handlers#writegood#GetExecutable(bufnr('')) AssertEqual \ (has('win32') ? 'node.exe ' : '') - \ . ale#Escape(ale#path#Winify(g:dir . '/write-good-node-modules-2/node_modules/write-good/bin/write-good.js')) + \ . ale#Escape(ale#path#Simplify(g:dir . '/write-good-node-modules-2/node_modules/write-good/bin/write-good.js')) \ . ' %t', \ ale#handlers#writegood#GetCommand(bufnr('')) |