Patch 7.4.1910
Problem:    Tests using external command to delete directory.
Solution:   Use delete().
Files:      src/testdir/test17.in, src/testdir/test73.in,
            src/testdir/test_getcwd.in


*** ../vim-7.4.1909/src/testdir/test17.in       2015-08-11 18:33:43.074928052 
+0200
--- src/testdir/test17.in       2016-06-08 21:39:44.201175330 +0200
***************
*** 9,21 ****
  :else
  : set isfname=@,48-57,/,.,-,_,+,,,$,:,~,{,}
  :endif
! :function! DeleteDirectory(dir)
! : if has("win16") || has("win32") || has("win64") || has("dos16") || 
has("dos32")
! :  exec "silent !rmdir /Q /S " . a:dir
! : else
! :  exec "silent !rm -rf " . a:dir
! : endif
! :endfun
  :if has("unix")
  :let $CDIR = "."
  /CDIR
--- 9,15 ----
  :else
  : set isfname=@,48-57,/,.,-,_,+,,,$,:,~,{,}
  :endif
! :"
  :if has("unix")
  :let $CDIR = "."
  /CDIR
***************
*** 45,51 ****
  :" check for 'include' without \zs or \ze
  :lang C
  :call delete("./Xbase.a")
! :call DeleteDirectory("Xdir1")
  :!mkdir Xdir1
  :!mkdir "Xdir1/dir2"
  :e! Xdir1/dir2/foo.a
--- 39,45 ----
  :" check for 'include' without \zs or \ze
  :lang C
  :call delete("./Xbase.a")
! :call delete("Xdir1", "rf")
  :!mkdir Xdir1
  :!mkdir "Xdir1/dir2"
  :e! Xdir1/dir2/foo.a
***************
*** 70,76 ****
  STARTTEST
  :" check for 'include' with \zs and \ze
  :call delete("./Xbase.b")
! :call DeleteDirectory("Xdir1")
  :!mkdir Xdir1
  :!mkdir "Xdir1/dir2"
  :let &include='^\s*%inc\s*/\zs[^/]\+\ze'
--- 64,70 ----
  STARTTEST
  :" check for 'include' with \zs and \ze
  :call delete("./Xbase.b")
! :call delete("Xdir1", "rf")
  :!mkdir Xdir1
  :!mkdir "Xdir1/dir2"
  :let &include='^\s*%inc\s*/\zs[^/]\+\ze'
***************
*** 100,106 ****
  STARTTEST
  :" check for 'include' with \zs and no \ze
  :call delete("./Xbase.c")
! :call DeleteDirectory("Xdir1")
  :!mkdir Xdir1
  :!mkdir "Xdir1/dir2"
  :let &include='^\s*%inc\s*\%([[:upper:]][^[:space:]]*\s\+\)\?\zs\S\+\ze'
--- 94,100 ----
  STARTTEST
  :" check for 'include' with \zs and no \ze
  :call delete("./Xbase.c")
! :call delete("Xdir1", "rf")
  :!mkdir Xdir1
  :!mkdir "Xdir1/dir2"
  :let &include='^\s*%inc\s*\%([[:upper:]][^[:space:]]*\s\+\)\?\zs\S\+\ze'
*** ../vim-7.4.1909/src/testdir/test73.in       2013-04-24 17:22:14.000000000 
+0200
--- src/testdir/test73.in       2016-06-08 21:40:30.593174692 +0200
***************
*** 9,24 ****
  :set visualbell
  :set nocp viminfo+=nviminfo
  :"
- :function! DeleteDirectory(dir)
- : if has("win16") || has("win32") || has("win64") || has("dos16") || 
has("dos32")
- :  exec "silent !rmdir /Q /S " . a:dir
- : else
- :  exec "silent !rm -rf " . a:dir
- : endif
- :endfun
  :" On windows a stale "Xfind" directory may exist, remove it so that
  :" we start from a clean state.
! :call DeleteDirectory("Xfind")
  :new
  :let cwd=getcwd()
  :let test_out = cwd . '/test.out'
--- 9,17 ----
  :set visualbell
  :set nocp viminfo+=nviminfo
  :"
  :" On windows a stale "Xfind" directory may exist, remove it so that
  :" we start from a clean state.
! :call delete("Xfind", "rf")
  :new
  :let cwd=getcwd()
  :let test_out = cwd . '/test.out'
***************
*** 170,176 ****
  :exec "w >>" . test_out
  :q
  :exec "cd " . cwd
! :call DeleteDirectory("Xfind")
  :qa!
  ENDTEST
  
--- 163,169 ----
  :exec "w >>" . test_out
  :q
  :exec "cd " . cwd
! :call delete("Xfind", "rf")
  :qa!
  ENDTEST
  
*** ../vim-7.4.1909/src/testdir/test_getcwd.in  2016-01-17 21:48:55.837086369 
+0100
--- src/testdir/test_getcwd.in  2016-06-08 21:37:40.729177028 +0200
***************
*** 9,22 ****
  :set visualbell
  :set nocp viminfo+=nviminfo
  :"
- :function! DeleteDirectory(dir)
- : if has("win16") || has("win32") || has("win64") || has("dos16") || 
has("dos32")
- :  exec "silent !rmdir /Q /S " . a:dir
- : else
- :  exec "silent !rm -rf " . a:dir
- : endif
- :endfun
- :"
  :function! GetCwdInfo(win, tab)
  : let tab_changed = 0
  : let mod = ":t"
--- 9,14 ----
***************
*** 42,48 ****
  :endfunction
  :" On windows a stale "Xtopdir" directory may exist, remove it so that
  :" we start from a clean state.
! :call DeleteDirectory("Xtopdir")
  :let r=[]
  :new
  :let cwd=getcwd()
--- 34,40 ----
  :endfunction
  :" On windows a stale "Xtopdir" directory may exist, remove it so that
  :" we start from a clean state.
! :call delete("Xtopdir", "rf")
  :let r=[]
  :new
  :let cwd=getcwd()
***************
*** 94,100 ****
  :call writefile(r, test_out, "a")
  :q
  :exec "cd " . cwd
! :call DeleteDirectory("Xtopdir")
  :qa!
  ENDTEST
  
--- 86,92 ----
  :call writefile(r, test_out, "a")
  :q
  :exec "cd " . cwd
! :call delete("Xtopdir", "rf")
  :qa!
  ENDTEST
  
*** ../vim-7.4.1909/src/version.c       2016-06-08 21:17:39.053193558 +0200
--- src/version.c       2016-06-08 21:40:39.229174573 +0200
***************
*** 755,756 ****
--- 755,758 ----
  {   /* Add new patch number below this line */
+ /**/
+     1910,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
73. You give your dog used motherboards instead of bones

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui