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.
-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:
# 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 \
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
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
test104.out: test104.in
test105.out: test105.in
test106.out: test106.in
+test_options.out: test_options.in
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
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
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
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: ?
#
VIMPROG = ../vim
+SCRIPTSOURCE = ../../runtime
# Uncomment this line to use valgrind for memory leaks and extra warnings.
# The output goes into a file "valgrind.testN"
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
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.*
--- /dev/null
+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
--- /dev/null
+result
+ok
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 231,
/**/
230,
/**/