This is the mail archive of the mailing list for the Archer project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [python] [approval request] Re: FYI a testcase FAIL: testFrame.read_var_value - error

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.
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 debuginfo.
    Revert "Fix false FAIL with 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 $" {
-	# 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"

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]