From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15819 invoked by alias); 8 Aug 2006 17:34:03 -0000 Received: (qmail 15810 invoked by uid 22791); 8 Aug 2006 17:34:03 -0000 X-Spam-Check-By: sourceware.org Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.31.1) with ESMTP; Tue, 08 Aug 2006 17:34:01 +0000 Received: from drow by nevyn.them.org with local (Exim 4.54) id 1GAVSn-0006Ow-WD; Tue, 08 Aug 2006 13:33:58 -0400 Date: Tue, 08 Aug 2006 17:34:00 -0000 From: Daniel Jacobowitz To: Andrew STUBBS Cc: GDB Patches Subject: Re: [PATCH] Command trace testsuite Message-ID: <20060808173357.GA24191@nevyn.them.org> Mail-Followup-To: Andrew STUBBS , GDB Patches References: <44D772B2.5090301@st.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <44D772B2.5090301@st.com> User-Agent: Mutt/1.5.11+cvs20060403 X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-08/txt/msg00045.txt.bz2 On Mon, Aug 07, 2006 at 06:04:50PM +0100, Andrew STUBBS wrote: > Here is a set of tests for the 'set trace-commands' command that I added > a while back. Thanks! > +# Source the script with verbose mode. > +gdb_test "source -v tracecommandsscript" {source -v tracecommandsscript[\r\n]+\+echo in tracecommandsscript\\n[\r\n]+in tracecommandsscript[\r\n]+\+define func[\r\n]+\+if 1[\r\n]+\+\+if 2[\r\n]+\+\+\+if 3[\r\n]+\+\+\+\+if 4[\r\n]+\+\+\+\+\+echo deep\\n[\r\n]+deep[\r\n]+\+\+\+\+\+func 999[\r\n]+\+\+\+\+\+\+echo in func 999\\n[\r\n]+in func 999} "source -v" For this sort of test, there's gdb_expect_list. The nice thing about that is that it will tell you where there's a problem on errors (and not generate thousand-character lines). Could you give that a try? -- Daniel Jacobowitz CodeSourcery