From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3440 invoked by alias); 16 May 2013 20:39:44 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 3429 invoked by uid 89); 16 May 2013 20:39:44 -0000 X-Spam-SWARE-Status: No, score=-7.3 required=5.0 tests=AWL,BAYES_00,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.1 Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Thu, 16 May 2013 20:39:44 +0000 Received: from int-mx12.intmail.prod.int.phx2.redhat.com (int-mx12.intmail.prod.int.phx2.redhat.com [10.5.11.25]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r4GKdgqr005172 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Thu, 16 May 2013 16:39:42 -0400 Received: from valrhona.uglyboxes.com (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx12.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r4GKdf2g019835 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO) for ; Thu, 16 May 2013 16:39:42 -0400 Message-ID: <5195440D.6070601@redhat.com> Date: Thu, 16 May 2013 20:39:00 -0000 From: Keith Seitz User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130402 Thunderbird/17.0.5 MIME-Version: 1.0 To: "gdb-patches@sourceware.org ml" Subject: Re: [RFA] gdb_expect -> gdb_test_multiple for filesym.exp References: <51951EAC.9090607@redhat.com> <51952C91.5040605@redhat.com> <51952E71.90601@redhat.com> <51953173.70002@redhat.com> In-Reply-To: <51953173.70002@redhat.com> Content-Type: multipart/mixed; boundary="------------060900000205030704010900" X-Virus-Found: No X-SW-Source: 2013-05/txt/msg00653.txt.bz2 This is a multi-part message in MIME format. --------------060900000205030704010900 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-length: 598 On 05/16/2013 12:20 PM, Pedro Alves wrote: > On 05/16/2013 08:07 PM, Keith Seitz wrote: > >> It can be easily removed, if you wished. Just let me know. > > It's fine with me as is. Actually, I'm revising this test a tiny bit. Jan mentioned privately that this test was failing the read1 test scenario (see testsuite/12649). With this update, the patch now passes that, too. Ok? Keith 2013-05-16 Keith Seitz * gdb.base/filesym.exp: Use gdb_test_multiple instead of gdb_expect. Add test to flush the remaining input buffer so that this file passes testsuite/12649. --------------060900000205030704010900 Content-Type: text/x-patch; name="completer-test-test_multiple.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="completer-test-test_multiple.patch" Content-length: 1387 Index: testsuite/gdb.base/filesym.exp =================================================================== RCS file: /cvs/src/src/gdb/testsuite/gdb.base/filesym.exp,v retrieving revision 1.1 diff -u -p -r1.1 filesym.exp --- testsuite/gdb.base/filesym.exp 15 May 2013 21:21:05 -0000 1.1 +++ testsuite/gdb.base/filesym.exp 16 May 2013 20:39:05 -0000 @@ -26,25 +26,26 @@ if {[prepare_for_testing $testfile.exp $ # complete to "filesym"; completing again, we expect the symbol name and the # filename (in that order). +set tst "complete on \"filesy\"" send_gdb "break filesy\t" -gdb_expect { - -re "m\$" { - pass "complete on \"filesy\"" +gdb_test_multiple "" $tst { + -re "m\$" { + pass $tst # Now ask for the completion list + set tst "completion list for \"filesym\"" send_gdb "\t\t" - gdb_expect { - -re ".*filesym\[ \t\]+filesym.c.*$gdb_prompt break filesym\$" { - pass "completion list for \"filesym\"" - } + gdb_test_multiple "" $tst { + -re ".*filesym\[ \t\]+filesym.c.*$gdb_prompt " { + pass $tst - default { - fail "completion list for \"filesym\"" + # Flush the rest of the output by creating the breakpoint. + # This ensures this file passes testsuite/12649. + send_gdb "\n" + gdb_test "" "Breakpoint 1.*" "set breakpoint at filesym" } } } - - default { - fail "complete on \"filesy\"" - } } + +unset -nocomplain tst --------------060900000205030704010900--