Mercurial > vim
comparison src/testdir/test_functions.vim @ 16180:1eaaa82ececf v8.1.1095
patch 8.1.1095: MS-Windows: executable() fails on very long filename
commit https://github.com/vim/vim/commit/8662189736e6cefb3fe852728adb5341f83973cf
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Mar 30 21:51:28 2019 +0100
patch 8.1.1095: MS-Windows: executable() fails on very long filename
Problem: MS-Windows: executable() fails on very long filename.
Solution: (Ken Takata, closes https://github.com/vim/vim/issues/4015)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 30 Mar 2019 22:00:04 +0100 |
parents | 4850744dc181 |
children | 0761a4c111a7 |
comparison
equal
deleted
inserted
replaced
16179:3dbabe1dc0b4 | 16180:1eaaa82ececf |
---|---|
942 call assert_equal(1, executable('cat')) | 942 call assert_equal(1, executable('cat')) |
943 call assert_equal(0, executable('nodogshere')) | 943 call assert_equal(0, executable('nodogshere')) |
944 endif | 944 endif |
945 endfunc | 945 endfunc |
946 | 946 |
947 func Test_executable_longname() | |
948 if !has('win32') | |
949 return | |
950 endif | |
951 | |
952 let fname = 'X' . repeat('あ', 200) . '.bat' | |
953 call writefile([], fname) | |
954 call assert_equal(1, executable(fname)) | |
955 call delete(fname) | |
956 endfunc | |
957 | |
947 func Test_hostname() | 958 func Test_hostname() |
948 let hostname_vim = hostname() | 959 let hostname_vim = hostname() |
949 if has('unix') | 960 if has('unix') |
950 let hostname_system = systemlist('uname -n')[0] | 961 let hostname_system = systemlist('uname -n')[0] |
951 call assert_equal(hostname_vim, hostname_system) | 962 call assert_equal(hostname_vim, hostname_system) |