All of lore.kernel.org
 help / color / mirror / Atom feed
From: mornfall@sourceware.org <mornfall@sourceware.org>
To: lvm-devel@redhat.com
Subject: LVM2/test Makefile.in harness.c
Date: 14 Oct 2010 14:36:27 -0000	[thread overview]
Message-ID: <20101014143627.12501.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	mornfall at sourceware.org	2010-10-14 14:36:26

Modified files:
	test           : Makefile.in harness.c 

Log message:
	Add a VERBOSE option to make check (make check VERBOSE=1).

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/test/Makefile.in.diff?cvsroot=lvm2&r1=1.43&r2=1.44
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/test/harness.c.diff?cvsroot=lvm2&r1=1.13&r2=1.14

--- LVM2/test/Makefile.in	2010/10/12 16:17:25	1.43
+++ LVM2/test/Makefile.in	2010/10/14 14:36:26	1.44
@@ -27,6 +27,7 @@
 
 T ?= .
 S ?= @ # never match anything by default
+VERBOSE ?= 0
 RUN = $(shell find -regextype posix-egrep -name t-\*.sh -and -regex ".*($(T)).*" -and -not -regex ".*($(S)).*" | sort)
 
 # Shell quote;
@@ -49,17 +50,17 @@
 
 all check: init.sh
 	@echo Testing with locking_type 1
-	./bin/harness $(RUN)
+	VERBOSE=$(VERBOSE) ./bin/harness $(RUN)
 	@echo Testing with locking_type 3
-	LVM_TEST_LOCKING=3 ./bin/harness $(RUN)
+	VERBOSE=$(VERBOSE) LVM_TEST_LOCKING=3 ./bin/harness $(RUN)
 
 check_cluster: init.sh
 	@echo Testing with locking_type 3
-	LVM_TEST_LOCKING=3 ./bin/harness $(RUN)
+	VERBOSE=$(VERBOSE) LVM_TEST_LOCKING=3 ./bin/harness $(RUN)
 
 check_local: init.sh
 	@echo Testing with locking_type 1
-	LVM_TEST_LOCKING=1 ./bin/harness $(RUN)
+	VERBOSE=$(VERBOSE) LVM_TEST_LOCKING=1 ./bin/harness $(RUN)
 
 bin/not: $(srcdir)/not.c .bin-dir-stamp
 	$(CC) -o bin/not $<
--- LVM2/test/harness.c	2010/07/28 12:20:41	1.13
+++ LVM2/test/harness.c	2010/10/14 14:36:26	1.14
@@ -39,6 +39,7 @@
 int readbuf_sz = 0, readbuf_used = 0;
 
 int die = 0;
+int verbose = 0;
 
 #define PASSED 0
 #define SKIPPED 1
@@ -64,6 +65,8 @@
 	char buf[2048];
 	while (1) {
 		sz = read(fds[1], buf, 2048);
+		if (verbose)
+			write(1, buf, sz);
 		if (sz <= 0)
 			return;
 		if (readbuf_used + sz >= readbuf_sz) {
@@ -164,7 +167,10 @@
 	s.nwarned = s.nfailed = s.npassed = s.nskipped = 0;
 
 	char *config = getenv("LVM_TEST_CONFIG"),
-	     *config_debug;
+		*config_debug,
+		*be_verbose = getenv("VERBOSE");
+	if (be_verbose && atoi(be_verbose))
+		verbose = 1; // XXX
 	config = config ? config : "";
 	asprintf(&config_debug, "%s\n%s\n", config, "log { verbose=4 }");
 



             reply	other threads:[~2010-10-14 14:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-14 14:36 mornfall [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-02-12 19:54 LVM2/test Makefile.in harness.c mornfall

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20101014143627.12501.qmail@sourceware.org \
    --to=mornfall@sourceware.org \
    --cc=lvm-devel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.