From: David Bremner Date: Tue, 28 Jun 2016 21:08:54 +0000 (+0200) Subject: [PATCH] test: make gdb even quieter X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=b44a5f5fcebcb9c209359f7d322cb8c8856e6dd7;p=notmuch-archives.git [PATCH] test: make gdb even quieter --- diff --git a/3a/bef985562c33c3b345322c6522c1bd66d923ab b/3a/bef985562c33c3b345322c6522c1bd66d923ab new file mode 100644 index 000000000..e03c87710 --- /dev/null +++ b/3a/bef985562c33c3b345322c6522c1bd66d923ab @@ -0,0 +1,87 @@ +Return-Path: +X-Original-To: notmuch@notmuchmail.org +Delivered-To: notmuch@notmuchmail.org +Received: from localhost (localhost [127.0.0.1]) + by arlo.cworth.org (Postfix) with ESMTP id 72A766DE01D0 + for ; Tue, 28 Jun 2016 14:09:14 -0700 (PDT) +X-Virus-Scanned: Debian amavisd-new at cworth.org +X-Spam-Flag: NO +X-Spam-Score: -0.005 +X-Spam-Level: +X-Spam-Status: No, score=-0.005 tagged_above=-999 required=5 + tests=[AWL=-0.006, HEADER_FROM_DIFFERENT_DOMAINS=0.001] + autolearn=disabled +Received: from arlo.cworth.org ([127.0.0.1]) + by localhost (arlo.cworth.org [127.0.0.1]) (amavisd-new, port 10024) + with ESMTP id BznLXPazRYRq for ; + Tue, 28 Jun 2016 14:09:06 -0700 (PDT) +Received: from fethera.tethera.net (fethera.tethera.net [198.245.60.197]) + by arlo.cworth.org (Postfix) with ESMTPS id 121646DE00DA + for ; Tue, 28 Jun 2016 14:09:05 -0700 (PDT) +Received: from remotemail by fethera.tethera.net with local (Exim 4.84) + (envelope-from ) + id 1bI0FQ-0007dV-HT; Tue, 28 Jun 2016 17:08:44 -0400 +Received: (nullmailer pid 11794 invoked by uid 1000); + Tue, 28 Jun 2016 21:08:58 -0000 +From: David Bremner +To: notmuch@notmuchmail.org +Subject: [PATCH] test: make gdb even quieter +Date: Tue, 28 Jun 2016 23:08:54 +0200 +Message-Id: <1467148134-11748-1-git-send-email-david@tethera.net> +X-Mailer: git-send-email 2.8.1 +X-BeenThere: notmuch@notmuchmail.org +X-Mailman-Version: 2.1.20 +Precedence: list +List-Id: "Use and development of the notmuch mail system." + +List-Unsubscribe: , + +List-Archive: +List-Post: +List-Help: +List-Subscribe: , + +X-List-Received-Date: Tue, 28 Jun 2016 21:09:14 -0000 + +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 < 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 < 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 +