Uniquify test names from gdb.python/{py-objfile.exp,py-pp-registration.exp}

Message ID 873807niyc.fsf@redhat.com
State New, archived
Headers

Commit Message

Sergio Durigan Junior July 29, 2015, 2:20 p.m. UTC
  On Wednesday, July 29 2015, Pedro Alves wrote:

> Hi Sergio,
>
> This unfortunately caused regressions in the testsuite:
>
> Running /home/pedro/gdb/mygit/build/../src/gdb/testsuite/gdb.python/py-objfile.exp ...
> FAIL: gdb.python/py-objfile.exp: Get no-debug objfile file
> FAIL: gdb.python/py-objfile.exp: Test owner of real objfile.
> FAIL: gdb.python/py-objfile.exp: Add separate debug file file
> FAIL: gdb.python/py-objfile.exp: Test owner of separate debug file
> FAIL: gdb.python/py-objfile.exp: Test user-name of owner of separate debug file
> FAIL: gdb.python/py-objfile.exp: print main with debug info
> FAIL: gdb.python/py-objfile.exp: print lookup_objfile of separate debug file
>
>> -gdb_py_test_silent_cmd "python objfile = gdb.objfiles()\[0\]" \
>> +gdb_py_test_silent_cmd "python objfile = gdb.s()\[0\]" \
>
> Looks like a typo snuck in here.
>
> Breakpoint 1, 0x0000000000400594 in main ()
> (gdb) python objfile = gdb.s()[0]
> Traceback (most recent call last):
>   File "<string>", line 1, in <module>
> AttributeError: 'module' object has no attribute 's'
> Error while executing Python code.
> (gdb) FAIL: gdb.python/py-objfile.exp: Get no-debug objfile file

Ops, thanks for the report.  I confess I have no idea how this happened,
but I pushed a fix.

Sorry about that,
  

Comments

Pedro Alves July 29, 2015, 2:34 p.m. UTC | #1
On 07/29/2015 03:20 PM, Sergio Durigan Junior wrote:

> Ops, thanks for the report.  I confess I have no idea how this happened,
> but I pushed a fix.
> 
> Sorry about that,
> 

It happens, no worries.  Thanks for fixing.

Thanks,
Pedro Alves
  

Patch

diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index ee0af2a..1f9bf98 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,8 @@ 
+2015-07-29  Sergio Durigan Junior  <sergiodj@redhat.com>
+
+	* gdb.python/py-objfile.exp: Fix typo that snuck in from my last
+	commit.
+
 2015-07-29  Patrick Palka  <patrick@parcs.ath.cx>
 
 	* gdb.base/batch-preserve-term-settings.exp
diff --git a/gdb/testsuite/gdb.python/py-objfile.exp b/gdb/testsuite/gdb.python/py-objfile.exp
index 7dd094c..6e6dfe7 100644
--- a/gdb/testsuite/gdb.python/py-objfile.exp
+++ b/gdb/testsuite/gdb.python/py-objfile.exp
@@ -106,7 +106,7 @@  if ![runto_main] {
     return 0
 }
 
-gdb_py_test_silent_cmd "python objfile = gdb.s()\[0\]" \
+gdb_py_test_silent_cmd "python objfile = gdb.objfiles()\[0\]" \
     "Get no-debug objfile file" 1
 
 gdb_test "python print (objfile.owner)" "None" \