unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
* [PATCH] test: make gdb even quieter
@ 2016-06-28 21:08 David Bremner
  2016-08-09  0:49 ` David Bremner
  0 siblings, 1 reply; 2+ messages in thread
From: David Bremner @ 2016-06-28 21:08 UTC (permalink / raw)
  To: notmuch

gdb sometimes writes warnings to stdout, which we don't need/want, and
for some reason --batch-silent isn't enough to hide. So in this commit
we write them to a log file, which is probably better for debugging
anyway. To see an illustrative test failure before this change, run

% make
% touch notmuch-count.c
% cd test && ./T060-count.sh
---
 test/T060-count.sh  | 2 ++
 test/T070-insert.sh | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/test/T060-count.sh b/test/T060-count.sh
index 0ac8314..d6933a7 100755
--- a/test/T060-count.sh
+++ b/test/T060-count.sh
@@ -103,6 +103,8 @@ restore_database
 
 cat <<EOF > count-files.gdb
 set breakpoint pending on
+set logging file count-files-gdb.log
+set logging on
 break count_files
 commands
 shell cp /dev/null ${MAIL_DIR}/.notmuch/xapian/postlist.${db_ending}
diff --git a/test/T070-insert.sh b/test/T070-insert.sh
index e7ec6a6..c2485bb 100755
--- a/test/T070-insert.sh
+++ b/test/T070-insert.sh
@@ -192,6 +192,8 @@ for code in OUT_OF_MEMORY XAPIAN_EXCEPTION FILE_NOT_EMAIL \
 gen_insert_msg
 cat <<EOF > index-file-$code.gdb
 set breakpoint pending on
+set logging file index-file-$code.log
+set logging on
 break notmuch_database_add_message
 commands
 return NOTMUCH_STATUS_$code
-- 
2.8.1

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] test: make gdb even quieter
  2016-06-28 21:08 [PATCH] test: make gdb even quieter David Bremner
@ 2016-08-09  0:49 ` David Bremner
  0 siblings, 0 replies; 2+ messages in thread
From: David Bremner @ 2016-08-09  0:49 UTC (permalink / raw)
  To: notmuch

David Bremner <david@tethera.net> writes:

> gdb sometimes writes warnings to stdout, which we don't need/want, and
> for some reason --batch-silent isn't enough to hide. So in this commit
> we write them to a log file, which is probably better for debugging
> anyway. To see an illustrative test failure before this change, run

pushed,

d

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2016-08-09  0:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-28 21:08 [PATCH] test: make gdb even quieter David Bremner
2016-08-09  0:49 ` David Bremner

Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).