patch 8.0.1176: job_start() does not handle quote and backslash correctly
Problem: Job_start() does not handle quote and backslash correctly.
Solution: Remove quotes, recognize and remove backslashes.
diff --git a/src/testdir/test_channel.vim b/src/testdir/test_channel.vim
index 951f9a3..9dba0c4 100644
--- a/src/testdir/test_channel.vim
+++ b/src/testdir/test_channel.vim
@@ -1590,6 +1590,22 @@
bwipe!
endfunc
+func Test_cmd_parsing()
+ if !has('unix')
+ return
+ endif
+ call assert_false(filereadable("file with space"))
+ let job = job_start('touch "file with space"')
+ call WaitFor('filereadable("file with space")')
+ call assert_true(filereadable("file with space"))
+ call delete("file with space")
+
+ let job = job_start('touch file\ with\ space')
+ call WaitFor('filereadable("file with space")')
+ call assert_true(filereadable("file with space"))
+ call delete("file with space")
+endfunc
+
func Test_raw_passes_nul()
if !executable('cat') || !has('job')
return