From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 109399 invoked by alias); 28 Oct 2016 13:49:09 -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 109384 invoked by uid 89); 28 Oct 2016 13:49:09 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.0 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy=Tel, tel, commercial, office X-HELO: mga07.intel.com Received: from mga07.intel.com (HELO mga07.intel.com) (134.134.136.100) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 28 Oct 2016 13:48:59 +0000 Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga105.jf.intel.com with ESMTP; 28 Oct 2016 06:48:57 -0700 X-ExtLoop1: 1 Received: from irsmsx153.ger.corp.intel.com ([163.33.192.75]) by fmsmga001.fm.intel.com with ESMTP; 28 Oct 2016 06:48:56 -0700 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.177]) by IRSMSX153.ger.corp.intel.com ([169.254.9.226]) with mapi id 14.03.0248.002; Fri, 28 Oct 2016 14:48:55 +0100 From: "Wiederhake, Tim" To: Simon Marchi CC: "gdb-patches@sourceware.org" , "palves@redhat.com" , "Metzger, Markus T" Subject: RE: [PATCH 6/7] python: Add tests for record Python bindings Date: Fri, 28 Oct 2016 13:49:00 -0000 Message-ID: <9676A094AF46E14E8265E7A3F4CCE9AF90C979@irsmsx105.ger.corp.intel.com> References: <1477549711-2603-1-git-send-email-tim.wiederhake@intel.com> <1477549711-2603-7-git-send-email-tim.wiederhake@intel.com> In-Reply-To: Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2016-10/txt/msg00800.txt.bz2 Hi Simon, Thanks for the comments! > -----Original Message----- > From: Simon Marchi [mailto:simon.marchi@polymtl.ca] > Sent: Thursday, October 27, 2016 6:00 PM > To: Wiederhake, Tim > Cc: gdb-patches@sourceware.org; palves@redhat.com; Metzger, Markus T > > Subject: Re: [PATCH 6/7] python: Add tests for record Python bindings >=20 > On 2016-10-27 02:28, Tim Wiederhake wrote: > > +# Skip this test if btrace is disabled. > > + > > +if { [skip_btrace_tests] } { return -1 } >=20 > Would it be helpful to have at least some minimal tests using the "full" > method, even if btrace is not available? If you are recording using the "full" method and try to access the data fro= m Python, you get a not-yet-implemented exception. All we can test in this = case is that the recording method in the gdb.Record object is displayed pro= perly, i.e. gdb.current_recording().method =3D=3D "full". I could rename py= -record.exp to py-record-btrace.exp and add a py-record-full.exp with that = exact test in it, but I don't see too much value in that. Your opinion? > > +with_test_prefix "no or double record" { > > + gdb_test "python print(gdb.current_recording())" "None" > > + > > + gdb_test_no_output "python gdb.start_recording()" > > + gdb_test "python gdb.start_recording(\"full\")" ".*gdb\.error: > > The process is already being recorded\..*" > > + > > + gdb_test_no_output "python gdb.stop_recording()" > > + gdb_test "python gdb.stop_recording()" ".*gdb\.error: No record > > target is currently active\..*" >=20 > These last two tests give the same test name (which must be unique). > You could give a specific name to one of them. Tim Intel Deutschland GmbH Registered Address: Am Campeon 10-12, 85579 Neubiberg, Germany Tel: +49 89 99 8853-0, www.intel.de Managing Directors: Christin Eisenschmid, Christian Lamprechter Chairperson of the Supervisory Board: Nicole Lau Registered Office: Munich Commercial Register: Amtsgericht Muenchen HRB 186928