diff options
author | paihu <paihu@users.noreply.github.com> | 2018-10-24 08:26:15 +0900 |
---|---|---|
committer | paihu <paihu@users.noreply.github.com> | 2018-10-24 08:29:11 +0900 |
commit | d14db50c4404cfdd95a5d3a19e7d6574b69aa2f0 (patch) | |
tree | c5b497f5ec607e23ff1c512988157694752a5232 /test/util | |
parent | f4395f5b8cb0078536e6033ca9c86e7299ed3ba1 (diff) | |
download | ale-d14db50c4404cfdd95a5d3a19e7d6574b69aa2f0.zip |
fix has('unix') equal 0 is windows.
Diffstat (limited to 'test/util')
-rw-r--r-- | test/util/test_cd_string_commands.vader | 20 |
1 files changed, 6 insertions, 14 deletions
diff --git a/test/util/test_cd_string_commands.vader b/test/util/test_cd_string_commands.vader index 04de4052..f2102e48 100644 --- a/test/util/test_cd_string_commands.vader +++ b/test/util/test_cd_string_commands.vader @@ -8,21 +8,13 @@ After: Execute(CdString should output the correct command string): " We will check that escaping is done correctly for each platform. - if has('win32') - AssertEqual - \ 'cd /d "/foo bar/baz" && ', - \ ale#path#CdString('/foo bar/baz') - else - AssertEqual - \ has('unix') ? 'cd ''/foo bar/baz'' && ' : 'cd "/foo bar/baz" && ', - \ ale#path#CdString('/foo bar/baz') - endif + AssertEqual + \ has('unix') ? 'cd ''/foo bar/baz'' && ' : 'cd /d "/foo bar/baz" && ', + \ ale#path#CdString('/foo bar/baz') Execute(BufferCdString should output the correct command string): call ale#test#SetFilename('foo.txt') - if has('win32') - AssertEqual 'cd /d ' .ale#Escape(g:dir) . ' && ', ale#path#BufferCdString(bufnr('')) - else - AssertEqual 'cd ' . ale#Escape(g:dir) . ' && ', ale#path#BufferCdString(bufnr('')) - endif + AssertEqual + \ has('unix') ? 'cd ' . ale#Escape(g:dir) . ' && ' : 'cd /d ' . ale#Escape(g:dir) . ' && ', + \ ale#path#BufferCdString(bufnr('')) |