forked from aniani/vim
updated for version 7.4.231
Problem: An error in ":options" is not caught by the tests.
Solution: Add a test for ":options". Set $VIMRUNTIME for the tests so that
it uses the current runtime files instead of the installed ones.
This commit is contained in:
@@ -1867,7 +1867,7 @@ test check:
|
||||
-if test $(VIMTARGET) != vim -a ! -r vim; then \
|
||||
ln -s $(VIMTARGET) vim; \
|
||||
fi
|
||||
cd testdir; $(MAKE) -f Makefile $(GUI_TESTTARGET) VIMPROG=../$(VIMTARGET) $(GUI_TESTARG)
|
||||
cd testdir; $(MAKE) -f Makefile $(GUI_TESTTARGET) VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
|
||||
$(MAKE) -f Makefile unittest
|
||||
|
||||
unittesttargets:
|
||||
@@ -1880,6 +1880,7 @@ unittest unittests: $(UNITTEST_TARGETS)
|
||||
|
||||
# Run individual test, assuming that Vim was already compiled.
|
||||
test1 test2 test3 test4 test5 test6 test7 test8 test9 \
|
||||
test_options \
|
||||
test10 test11 test12 test13 test14 test15 test16 test17 test18 test19 \
|
||||
test20 test21 test22 test23 test24 test25 test26 test27 test28 test29 \
|
||||
test30 test31 test32 test33 test34 test35 test36 test37 test38 test39 \
|
||||
@@ -1890,7 +1891,7 @@ test1 test2 test3 test4 test5 test6 test7 test8 test9 \
|
||||
test80 test81 test82 test83 test84 test85 test86 test87 test88 test89 \
|
||||
test90 test91 test92 test93 test94 test95 test96 test97 test98 test99 \
|
||||
test100 test101 test102 test103 test104 test105 test106 test107:
|
||||
cd testdir; rm $@.out; $(MAKE) -f Makefile $@.out VIMPROG=../$(VIMTARGET)
|
||||
cd testdir; rm $@.out; $(MAKE) -f Makefile $@.out VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
|
||||
|
||||
testclean:
|
||||
cd testdir; $(MAKE) -f Makefile clean
|
||||
|
||||
@@ -35,7 +35,8 @@ SCRIPTS = test1.out test3.out test4.out test5.out test6.out \
|
||||
test89.out test90.out test91.out test92.out test93.out \
|
||||
test94.out test95.out test96.out test97.out test98.out \
|
||||
test99.out test100.out test101.out test102.out test103.out \
|
||||
test104.out test105.out test106.out
|
||||
test104.out test105.out test106.out \
|
||||
test_options.out
|
||||
|
||||
.SUFFIXES: .in .out
|
||||
|
||||
@@ -158,3 +159,4 @@ test103.out: test103.in
|
||||
test104.out: test104.in
|
||||
test105.out: test105.in
|
||||
test106.out: test106.in
|
||||
test_options.out: test_options.in
|
||||
|
||||
@@ -34,7 +34,8 @@ SCRIPTS = test3.out test4.out test5.out test6.out test7.out \
|
||||
test89.out test90.out test91.out test92.out test93.out \
|
||||
test94.out test95.out test96.out test98.out test99.out \
|
||||
test100.out test101.out test102.out test103.out test104.out \
|
||||
test105.out test106.out
|
||||
test105.out test106.out \
|
||||
test_options.out
|
||||
|
||||
SCRIPTS32 = test50.out test70.out
|
||||
|
||||
|
||||
@@ -54,7 +54,8 @@ SCRIPTS = test3.out test4.out test5.out test6.out test7.out \
|
||||
test89.out test90.out test91.out test92.out test93.out \
|
||||
test94.out test95.out test96.out test98.out test99.out \
|
||||
test100.out test101.out test102.out test103.out test104.out \
|
||||
test105.out test106.out
|
||||
test105.out test106.out \
|
||||
test_options.out
|
||||
|
||||
SCRIPTS32 = test50.out test70.out
|
||||
|
||||
|
||||
@@ -36,7 +36,8 @@ SCRIPTS = test1.out test3.out test4.out test5.out test6.out \
|
||||
test89.out test90.out test91.out test92.out test93.out \
|
||||
test94.out test95.out test96.out test98.out test99.out \
|
||||
test100.out test101.out test102.out test103.out test104.out \
|
||||
test105.out test106.out
|
||||
test105.out test106.out \
|
||||
test_options.out
|
||||
|
||||
.SUFFIXES: .in .out
|
||||
|
||||
|
||||
@@ -95,7 +95,8 @@ SCRIPT = test1.out test2.out test3.out test4.out test5.out \
|
||||
test90.out test91.out test92.out test93.out test94.out \
|
||||
test95.out test96.out test98.out test99.out \
|
||||
test100.out test101.out test103.out test104.out \
|
||||
test105.out test106.out
|
||||
test105.out test106.out \
|
||||
test_options.out
|
||||
|
||||
# Known problems:
|
||||
# test17: ?
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
#
|
||||
|
||||
VIMPROG = ../vim
|
||||
SCRIPTSOURCE = ../../runtime
|
||||
|
||||
# Uncomment this line to use valgrind for memory leaks and extra warnings.
|
||||
# The output goes into a file "valgrind.testN"
|
||||
@@ -31,7 +32,8 @@ SCRIPTS = test1.out test2.out test3.out test4.out test5.out test6.out \
|
||||
test89.out test90.out test91.out test92.out test93.out \
|
||||
test94.out test95.out test96.out test97.out test98.out \
|
||||
test99.out test100.out test101.out test102.out test103.out \
|
||||
test104.out test105.out test106.out
|
||||
test104.out test105.out test106.out \
|
||||
test_options.out
|
||||
|
||||
SCRIPTS_GUI = test16.out
|
||||
|
||||
@@ -53,7 +55,7 @@ $(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
|
||||
RUN_VIM = $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in
|
||||
RUN_VIM = export VIMRUNTIME=$(SCRIPTSOURCE); $(VALGRIND) $(VIMPROG) -u unix.vim -U NONE --noplugin -s dotest.in
|
||||
|
||||
clean:
|
||||
-rm -rf *.out *.failed *.rej *.orig test.log $(RM_ON_RUN) $(RM_ON_START) valgrind.*
|
||||
|
||||
17
src/testdir/test_options.in
Normal file
17
src/testdir/test_options.in
Normal file
@@ -0,0 +1,17 @@
|
||||
Test for ":options".
|
||||
|
||||
STARTTEST
|
||||
:so small.vim
|
||||
:let caught = 'ok'
|
||||
:try
|
||||
:options
|
||||
:catch
|
||||
:let caught = v:throwpoint . "\n" . v:exception
|
||||
:endtry
|
||||
:buf 1
|
||||
:$put =caught
|
||||
:/^result/,$w! test.out
|
||||
:qa!
|
||||
ENDTEST
|
||||
|
||||
result
|
||||
2
src/testdir/test_options.ok
Normal file
2
src/testdir/test_options.ok
Normal file
@@ -0,0 +1,2 @@
|
||||
result
|
||||
ok
|
||||
@@ -734,6 +734,8 @@ static char *(features[]) =
|
||||
|
||||
static int included_patches[] =
|
||||
{ /* Add new patch number below this line */
|
||||
/**/
|
||||
231,
|
||||
/**/
|
||||
230,
|
||||
/**/
|
||||
|
||||
Reference in New Issue
Block a user