diff options
Diffstat (limited to 'test/functional/ex_cmds/write_spec.lua')
| -rw-r--r-- | test/functional/ex_cmds/write_spec.lua | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/functional/ex_cmds/write_spec.lua b/test/functional/ex_cmds/write_spec.lua index 6c550b3395..38cc85fdb6 100644 --- a/test/functional/ex_cmds/write_spec.lua +++ b/test/functional/ex_cmds/write_spec.lua @@ -124,6 +124,10 @@ describe(':write', function() eq(1, eval("filereadable('Xtest_write/write2/p_opt.txt')")) eq(1, eval("filereadable('Xtest_write/write2/p_opt2.txt')")) eq(0, eval("filereadable('Xtest_write/write3/p_opt3.txt')")) + t.matches( + 'E474: Invalid argument', + pcall_err(command, 'read ++edits Xtest_write/write/p_opt.txt') + ) eq('Vim(write):E32: No file name', pcall_err(command, 'write ++p Xotherdir/')) if not is_os('win') then @@ -136,6 +140,11 @@ describe(':write', function() pcall_err(command, 'write ++p ./') ) end + + t.matches( + 'E474: Invalid argument', + pcall_err(command, 'write ++patate Xtest_write/garbage.txt') + ) end) it('errors out correctly', function() |
