Hi Bram and Vim developers,
How to reproduce. (on linux)
- set terminal size to 80x20
- make test
- test92 and test93 fail.
- test92.in and test93.in become empty. <--- unexpected!
Expect behavior
- test92.in and test93.in keep the contents of file.
Investigation result
Line 34th of test92.in
:new test.out
failed (E36: Not enough room).
and line 36th
:w
is update to test92.in empty.
(test93.in is similar)
...and some test requires a certain height or more.
(e.g. test37 and test47 requires height 20)
I wrote two patches.
#1 test92_93_empty.patch
Fixed above problem.
#2 check_term_size_at_1st_test.patch
Adding check terminal size 80x24 or higher at first test.
Please check this.
Best regards,
Hirohito Higashi
--
--
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/groups/opt_out.
diff -r a83960ec9e6d src/testdir/test92.in
--- a/src/testdir/test92.in Sun Sep 08 20:00:48 2013 +0200
+++ b/src/testdir/test92.in Thu Sep 12 08:41:27 2013 +0900
@@ -33,7 +33,7 @@
:mksession! test.out
:new test.out
:v/\(^ *normal! 0\|^ *exe 'normal!\)/d
-:w
+:w test.out
:qa!
ENDTEST
diff -r a83960ec9e6d src/testdir/test93.in
--- a/src/testdir/test93.in Sun Sep 08 20:00:48 2013 +0200
+++ b/src/testdir/test93.in Thu Sep 12 08:41:27 2013 +0900
@@ -33,7 +33,7 @@
:mksession! test.out
:new test.out
:v/\(^ *normal! 0\|^ *exe 'normal!\)/d
-:w
+:w test.out
:qa!
ENDTEST
diff -r a83960ec9e6d src/testdir/Makefile
--- a/src/testdir/Makefile Sun Sep 08 20:00:48 2013 +0200
+++ b/src/testdir/Makefile Thu Sep 12 08:41:27 2013 +0900
@@ -50,7 +50,8 @@
$(SCRIPTS) $(SCRIPTS_GUI): $(VIMPROG)
RM_ON_RUN = test.out X* viminfo
-RM_ON_START = tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok
+RM_ON_START = tiny.vim small.vim mbyte.vim mzscheme.vim lua.vim test.ok \
+ wrongtermsize
RUN_VIM = $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in
clean:
@@ -59,7 +60,11 @@
test1.out: test1.in
-rm -rf $*.failed $(RM_ON_RUN) $(RM_ON_START)
$(RUN_VIM) $*.in
- @/bin/sh -c "if diff test.out $*.ok; \
+ @/bin/sh -c "if test -e wrongtermsize; \
+ then echo; \
+ echo test1 FAILED - Require terminal size 80x24 or higher; \
+ echo; exit 1; \
+ elif diff test.out $*.ok; \
then mv -f test.out $*.out; \
else echo; \
echo test1 FAILED - Something basic is wrong; \
diff -r a83960ec9e6d src/testdir/test1.in
--- a/src/testdir/test1.in Sun Sep 08 20:00:48 2013 +0200
+++ b/src/testdir/test1.in Thu Sep 12 08:41:27 2013 +0900
@@ -21,6 +21,10 @@
:" Write a single line to test.out to check if testing works at all.
:%d
athis is a test:w! test.out
+:" If columns or lines are small, make wrongtermsize empty.
+:" (Some tests will fail. When columns and/or lines are small)
+:if &lines < 24 || &columns < 80 | sp another | w! wrongtermsize | q | endif
+:"
:" Create small.vim and tiny.vim empty, create mbyte.vim to skip the test.
0D:w! small.vim
:w! tiny.vim