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 53A236DE0B27 for ; Thu, 7 Jan 2016 13:50:01 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at cworth.org X-Spam-Flag: NO X-Spam-Score: 0.666 X-Spam-Level: X-Spam-Status: No, score=0.666 tagged_above=-999 required=5 tests=[AWL=0.014, SPF_NEUTRAL=0.652] 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 kuFCi-9i9Hes for ; Thu, 7 Jan 2016 13:49:58 -0800 (PST) Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34]) by arlo.cworth.org (Postfix) with ESMTP id EBDFA6DE0B26 for ; Thu, 7 Jan 2016 13:49:57 -0800 (PST) Received: from guru.guru-group.fi (localhost [IPv6:::1]) by guru.guru-group.fi (Postfix) with ESMTP id EC86C1000B3; Thu, 7 Jan 2016 23:50:10 +0200 (EET) From: Tomi Ollila To: J Farkas , David Bremner Cc: notmuch@notmuchmail.org Subject: Re: T070 tests portability In-Reply-To: <1452088279.96.560c52fa@201601.l2015aftruuq.dns007.net> References: <1451991305.14.acc64b88@201601.l2015aftruuq.dns007.net> <87ziwj9025.fsf@zancas.localnet> <1452088279.96.560c52fa@201601.l2015aftruuq.dns007.net> User-Agent: Notmuch/0.21+32~g73439f8 (http://notmuchmail.org) Emacs/24.3.1 (x86_64-unknown-linux-gnu) X-Face: HhBM'cA~ MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable 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: Thu, 07 Jan 2016 21:50:01 -0000 On Wed, Jan 06 2016, J Farkas wrote: > On 2016-01-05 at 17:41:06, David Bremner wrote: >> Tomi Ollila writes: >>=20 >> > The page https://sourceware.org/gdb/onlinedocs/gdb/Returning.html >> > talks something about gdb not knowing the return type if function >> > was compiled without debug info... well, is this is the reason, >> > perhaps we should allow testing w/o debug info compiled in. >>=20 >> The test suite overall assumes debug info is present; T000-basic tests >> for this. > > I'm not missing the debug infos (well, except for the thread library if I > understand correctly - and that affects a lot of other tests, but not thi= s). > Perhaps it the version of gdb, but not any compilation flags that can be > changed for the notmuch tree. > > Without the changes, I'm getting these two kind of errors (and as you can > see, the test for the debugging symbols passes too). ack... keep reading... > > $ ./T000-basic.sh > > T000-basic: Testing the test framework itself. > PASS success is reported like this > ... > PASS PATH is set to build directory > PASS notmuch is compiled with debugging symbols > $ ./T070-insert.sh > > T070-insert: Testing "notmuch insert" > PASS Insert zero-length file > ... > FAIL Insert duplicate message > --- T070-insert.6.expected 2016-01-06 13:31:01.644676102 +00= 00 > +++ T070-insert.6.output 2016-01-06 13:31:01.648675891 +00= 00 > @@ -1 +1 @@ > -2 > + 2 This is trivial to fix w/ the same output=3D$((`notmuch search --output=3Dfiles "subject:insert-subject" | wc = -l`)) construct that is used in T060-count.sh A separate patch doing just this would be appreciated. > PASS Duplicate message does not change tags > PASS Insert message, add tag > ... > PASS Tags starting with '-' in new.tags are forbidden > PASS Invalid tags set exit code > FAIL error exit when add_message returns OUT_OF_MEMORY > --- T070-insert.26.expected 2016-01-06 13:31:06.940397013 +00= 00 > +++ T070-insert.26.output 2016-01-06 13:31:06.940397013 +00= 00 > @@ -1 +1 @@ > -1 > +255 > warning: Unable to find libthread_db matching inferior's thread library, = thread debugging will not be available. > index-file-OUT_OF_MEMORY.gdb:7: Error in sourced command file: > Return value type not available for selected stack frame. > Please use an explicit cast of the value to return. > FAIL success exit with --keep when add_message returns OUT_OF_MEMORY Your setup is interesting -- you have GNU textutils 2.0.22, released 2002-07-20 (i.e. 13.5 years ago) and then gdb 7.4. I just run this test file on Scientific Linux 6.2 (gcc 4.4.6 and gdb 7.2), and the tests passed without problems. Apart from a few special cases, no typecasts should be added lightly to the code -- be it at innocent-looking as it can be. Those impedes the possibility for compiler (etc.) to do type checking. So, in this case, if you're the only one seeing this problem I'd suggest you tolerate the problem (by using private patch) (you could also dig deeper if interested). If this "problem" is (were!) more widespread, *and* unfixable in reasonable manner this thing like this typecast could be applied -- which would also mean this test system would be a bit less robust as it is now...(*) Tomi (*) imo these are hard facts, but someone(tm) may consider these as mere opinions... > ... > > (The above is then repeated for all gdb using `insert` tests.) > > J=C3=A1nos