summaryrefslogtreecommitdiffstats
path: root/src/testdir/Makefile
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-01-11 17:30:16 +0100
committerBram Moolenaar <Bram@vim.org>2019-01-11 17:30:16 +0100
commitec50401e1e1357a1340b3c92109fd4860e38a8ac (patch)
tree4e2437694f097dc4c34a88f10d3ae5701c048d15 /src/testdir/Makefile
parent977239ef52763b6e640ac632c53a57ee17e05eaa (diff)
patch 8.1.0723: cannot easily run specific test when in src/testdirv8.1.0723
Problem: Cannot run specific test when in src/testdir the same was as in the src directory. Solution: Move build rule to src/testdir/Makefile.
Diffstat (limited to 'src/testdir/Makefile')
-rw-r--r--src/testdir/Makefile20
1 files changed, 16 insertions, 4 deletions
diff --git a/src/testdir/Makefile b/src/testdir/Makefile
index e9e0f4b320..311701afa2 100644
--- a/src/testdir/Makefile
+++ b/src/testdir/Makefile
@@ -23,7 +23,8 @@ REDIR_TEST_TO_NULL = --cmd 'au SwapExists * let v:swapchoice = "e"' > /dev/null
default: nongui
# The list of tests is common to all systems.
-# This defines NEW_TESTS, SCRIPTS_ALL, SCRIPTS_MORE* and SCRIPTS_GUI.
+# This defines NEW_TESTS, NEW_TESTS_RES, SCRIPTS_ALL, SCRIPTS_MORE* and
+# SCRIPTS_GUI.
include Make_all.mak
@@ -50,10 +51,21 @@ report:
else echo ALL DONE; \
fi"
-$(SCRIPTS_FIRST) $(SCRIPTS) $(SCRIPTS_GUI) $(NEW_TESTS): $(VIMPROG)
+$(SCRIPTS_FIRST) $(SCRIPTS) $(SCRIPTS_GUI) $(NEW_TESTS_RES): $(VIMPROG)
# Must run test1 first to create small.vim.
-$(SCRIPTS) $(SCRIPTS_GUI) $(NEW_TESTS): $(SCRIPTS_FIRST)
+$(SCRIPTS) $(SCRIPTS_GUI) $(NEW_TESTS_RES): $(SCRIPTS_FIRST)
+
+
+# Execute an individual new style test, e.g.:
+# make test_largefile
+$(NEW_TESTS):
+ rm -f $@.res test.log messages
+ $(MAKE) -f Makefile $@.res
+ @if test -f test.log; then \
+ cat test.log; \
+ fi
+ cat messages
RM_ON_RUN = test.out X* viminfo
RM_ON_START = tiny.vim small.vim mbyte.vim mzscheme.vim test.ok benchmark.out
@@ -128,7 +140,7 @@ RUN_VIMTEST = VIMRUNTIME=$(SCRIPTSOURCE); export VIMRUNTIME; $(VALGRIND) $(VIMPR
newtests: newtestssilent
@/bin/sh -c "if test -f messages && grep -q 'SKIPPED\|FAILED' messages; then cat messages; fi"
-newtestssilent: $(NEW_TESTS)
+newtestssilent: $(NEW_TESTS_RES)
.vim.res: writevimcmd