diff src/testdir/test_shell.vim @ 30626:5bc844667d46 v9.0.0648

patch 9.0.0648: when using powershell input redirection does not work Commit: https://github.com/vim/vim/commit/0a016671b96ae7d27926e9d36dc11945c8f5749d Author: Yegappan Lakshmanan <yegappan@yahoo.com> Date: Mon Oct 3 16:05:28 2022 +0100 patch 9.0.0648: when using powershell input redirection does not work Problem: When using powershell input redirection does not work. Solution: Use a different shell command for powershell. (Yegappan Lakshmanan, closes #11257)
author Bram Moolenaar <Bram@vim.org>
date Mon, 03 Oct 2022 17:15:03 +0200
parents 008808e60963
children ae10b91ac6b3
line wrap: on
line diff
--- a/src/testdir/test_shell.vim
+++ b/src/testdir/test_shell.vim
@@ -97,6 +97,18 @@ func Test_shell_options()
       finally
         bwipe!
       endtry
+
+      " filter buffer contents through an external command
+      new
+      call setline(1, ['tom', 'sam', 'andy'])
+      try
+        %!sort
+        call assert_equal(['andy', 'sam', 'tom'], getline(1, '$'), e[0])
+      catch
+        call assert_report($'Failed to filter buffer contents, shell: {e[0]}, caught {v:exception}')
+      finally
+        bwipe!
+      endtry
     endif
   endfor
   set shell& shellcmdflag& shellpipe& shellquote&