comparison src/testdir/test_file_perm.vim @ 8461:988ddc5742f5 v7.4.1521

commit https://github.com/vim/vim/commit/8322e1f06e8fa39a6bb790a7d8d7db5d7aff3366 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Mar 8 19:20:04 2016 +0100 patch 7.4.1521 Problem: File permission test fails on MS-Windows. Solution: Expect a different permission.
author Christian Brabandt <cb@256bit.org>
date Tue, 08 Mar 2016 19:30:05 +0100
parents c0b5c2b0a5ee
children 4935244c1128
comparison
equal deleted inserted replaced
8460:a6b86b34003f 8461:988ddc5742f5
6 6
7 call writefile(['one'], 'Xtest') 7 call writefile(['one'], 'Xtest')
8 call assert_true(len(getfperm('Xtest')) == 9) 8 call assert_true(len(getfperm('Xtest')) == 9)
9 9
10 call assert_equal(1, setfperm('Xtest', 'rwx------')) 10 call assert_equal(1, setfperm('Xtest', 'rwx------'))
11 call assert_equal('rwx------', getfperm('Xtest')) 11 if has('win32')
12 call assert_equal('rw-rw-rw-', getfperm('Xtest'))
13 else
14 call assert_equal('rwx------', getfperm('Xtest'))
15 endif
12 16
13 call assert_equal(1, setfperm('Xtest', 'r--r--r--')) 17 call assert_equal(1, setfperm('Xtest', 'r--r--r--'))
14 call assert_equal('r--r--r--', getfperm('Xtest')) 18 call assert_equal('r--r--r--', getfperm('Xtest'))
15 19
16 call assert_fails("setfperm('Xtest', '---')") 20 call assert_fails("setfperm('Xtest', '---')")