From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29834 invoked by alias); 6 Mar 2009 15:04:40 -0000 Mailing-List: contact archer-help@sourceware.org; run by ezmlm Sender: Precedence: bulk List-Post: List-Help: List-Subscribe: List-Id: Mail-Followup-To: archer@sourceware.org Received: (qmail 29822 invoked by uid 22791); 6 Mar 2009 15:04:37 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,J_CHICKENPOX_42,SPF_PASS X-Spam-Check-By: sourceware.org Subject: Re: [python] [approval request] Re: FYI a testcase FAIL: test Frame.read_var_value - error From: Thiago Jung Bauermann To: Jan Kratochvil Cc: archer@sourceware.org In-Reply-To: <20090306143106.GA17661@host0.dyn.jankratochvil.net> References: <20090303194756.GA8203@host0.dyn.jankratochvil.net> <1236186119.30573.69.camel@localhost.localdomain> <20090305225827.GA4161@host0.dyn.jankratochvil.net> <1236310518.4870.5.camel@localhost.localdomain> <20090306132509.GA32564@host0.dyn.jankratochvil.net> <1236349318.8765.3.camel@localhost.localdomain> <1236349690.8765.10.camel@localhost.localdomain> <20090306143106.GA17661@host0.dyn.jankratochvil.net> Content-Type: text/plain; charset=utf-8 Date: Fri, 06 Mar 2009 15:04:00 -0000 Message-Id: <1236351862.8765.14.camel@localhost.localdomain> Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-SW-Source: 2009-q1/txt/msg00353.txt.bz2 El vie, 06-03-2009 a las 15:31 +0100, Jan Kratochvil escribió: > On Fri, 06 Mar 2009 15:28:10 +0100, Thiago Jung Bauermann wrote: > > Actually, I think it's better to change the variable name from 'b' to > > something hwich will surely not exist anywhere else. What do you think? > > I can make that change. > > Good idea but already checked-in. Patch it a way you like. Ok, I reversed your patch and committed the patch below. I'm just worried about my lack of sense of humor when choosing the variable name... > Also XFAIL was probably not right as the system environment was correct. > KFAIL also would not be right as GDB behaves as expected. > Maybe it should have been just PASS as it comes from GDB breakage by design. PASS wouldn't be good either because if read_var finds a variable the test doesn't exercise the error path I want it to, so the PASS doesn't mean anything. -- []'s Thiago Jung Bauermann IBM Linux Technology Center commit 7479ac4e385bcaa2846c3aad5c616f571ff53c97 Author: Thiago Jung Bauermann Date: Fri Mar 6 11:49:59 2009 -0300 Fix python-frame.exp testcase when you have libm.so debuginfo. Revert "Fix false FAIL with libm.so debuginfo installed." This reverts commit eff2403b365bdda84c08eb68890152ca1a58f1c6. * gdb.python/python-frame.exp (test Frame.read_var - error): Use variable name which surely won't exist anywhere. diff --git a/gdb/testsuite/gdb.python/python-frame.exp b/gdb/testsuite/gdb.python/python-frame.exp index e9e063a..674c25e 100644 --- a/gdb/testsuite/gdb.python/python-frame.exp +++ b/gdb/testsuite/gdb.python/python-frame.exp @@ -81,20 +81,9 @@ gdb_test "python print 'result =', f0.pc ()" " = \[0-9\]+" "test Frame.pc" gdb_test "python print 'result =', f0.addr_in_block ()" " = \[0-9\]+" "test Frame.addr_in_block" gdb_test "python print 'result =', f0.older ().equals (f1)" " = True" "test Frame.older" gdb_test "python print 'result =', f1.newer ().equals (f0)" " = True" "test Frame.newer" - -set test "test Frame.read_var - error" -gdb_test_multiple "python print 'result =', f0.read_var ('b')" $test { - -re "ValueError: variable 'b' not found.*Error while executing Python code.\r\n$gdb_prompt $" { - pass $test - } - -re "result = \\\{i = \\\{0, \[0-9\]+\\\}, d = 0\\.\[0-9\]+\\\}\r\n$gdb_prompt $" { - # libm.so debuginfo contains file static symbol `b' from `atnat.h'. - # local `b' would be find first if it would exist so it is more a PASS. - setup_xfail *-*-* - fail $test - } -} - +gdb_test "python print 'result =', f0.read_var ('variable_which_surely_doesnt_exist')" \ + "ValueError: variable 'variable_which_surely_doesnt_exist' not found.*Error while executing Python code." \ + "test Frame.read_var - error" gdb_test "python print 'result =', f0.read_var ('a')" " = 1" "test Frame.read_var - success" gdb_test "python print 'result =', gdb.newest_frame ().equals (f0)" " = True" "test gdb.newest_frame"