patch 8.1.0456: running test hangs when the input file is being edited
Problem: Running test hangs when the input file is being edited.
Solution: Use a SwapExists autocommand to ignore editing the test script.
diff --git a/src/testdir/Makefile b/src/testdir/Makefile
index 6a9ef0f..e9e0f4b 100644
--- a/src/testdir/Makefile
+++ b/src/testdir/Makefile
@@ -9,8 +9,10 @@
SCRIPTSOURCE = ../../runtime
-# Change this to empty to see the verbose output of tests.
-REDIR_TEST_TO_NULL = > /dev/null
+# Comment out this line to see the verbose output of tests.
+#
+# Catches SwapExists to avoid hanging at the ATTENTION prompt.
+REDIR_TEST_TO_NULL = --cmd 'au SwapExists * let v:swapchoice = "e"' > /dev/null
# Uncomment this line to use valgrind for memory leaks and extra warnings.
# The output goes into a file "valgrind.testN"