From 7043ac7100cd80345d7f12ece60d05a3ab2baf06 Mon Sep 17 00:00:00 2001
From: Andrew Dunstan <andrew@dunslane.net>
Date: Tue, 28 Jan 2014 18:10:00 -0500
Subject: [PATCH] Add new make targets check-tests and installcheck-tests.

These do not run any specific schedule of tests, but only those
specified as part of the invocation, e.g.:

    make check-tests TESTS="json jsonb"
---
 GNUmakefile.in               | 4 ++--
 src/test/regress/GNUmakefile | 6 ++++++
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/GNUmakefile.in b/GNUmakefile.in
index 80116a1fbf9..40ab2804f70 100644
--- a/GNUmakefile.in
+++ b/GNUmakefile.in
@@ -61,9 +61,9 @@ distclean maintainer-clean:
 # Garbage from autoconf:
 	@rm -rf autom4te.cache/
 
-check: all
+check check-tests: all
 
-check installcheck installcheck-parallel:
+check check-tests installcheck installcheck-parallel installcheck-tests:
 	$(MAKE) -C src/test/regress $@
 
 $(call recurse,check-world,src/test src/pl src/interfaces/ecpg contrib,check)
diff --git a/src/test/regress/GNUmakefile b/src/test/regress/GNUmakefile
index 94762d50778..b084e0a831e 100644
--- a/src/test/regress/GNUmakefile
+++ b/src/test/regress/GNUmakefile
@@ -142,12 +142,18 @@ REGRESS_OPTS = --dlpath=. $(EXTRA_REGRESS_OPTS)
 check: all tablespace-setup
 	$(pg_regress_check) $(REGRESS_OPTS) --schedule=$(srcdir)/parallel_schedule $(MAXCONNOPT) $(TEMP_CONF) $(EXTRA_TESTS)
 
+check-tests: all tablespace-setup
+	$(pg_regress_check) $(REGRESS_OPTS) $(MAXCONNOPT) $(TEMP_CONF) $(TESTS) $(EXTRA_TESTS)
+
 installcheck: all tablespace-setup
 	$(pg_regress_installcheck) $(REGRESS_OPTS) --schedule=$(srcdir)/serial_schedule $(EXTRA_TESTS)
 
 installcheck-parallel: all tablespace-setup
 	$(pg_regress_installcheck) $(REGRESS_OPTS) --schedule=$(srcdir)/parallel_schedule $(MAXCONNOPT) $(EXTRA_TESTS)
 
+installcheck-tests: all tablespace-setup
+	$(pg_regress_installcheck) $(REGRESS_OPTS) $(TESTS) $(EXTRA_TESTS)
+
 standbycheck: all
 	$(pg_regress_installcheck) $(REGRESS_OPTS) --schedule=$(srcdir)/standby_schedule --use-existing
 
-- 
GitLab