]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
gdb/testsuite: improve corefile-no-threads.py script
authorAndrew Burgess <aburgess@redhat.com>
Wed, 11 Mar 2026 11:56:10 +0000 (11:56 +0000)
committerAndrew Burgess <aburgess@redhat.com>
Fri, 1 May 2026 18:56:55 +0000 (19:56 +0100)
commitf681a0b4290dbcd6818765cd2c615dfb9db9d7ef
tree0acf47da0bbe4f6b68fed982b31f620ec3846bb2
parenta218fdeb64ca42d795648687c1197b167bee88b3
gdb/testsuite: improve corefile-no-threads.py script

Extend the Python script gdb.base/corefile-no-threads.py so that core
file note types can be specified by name, e.g. NT_PRSTATUS, rather
than having to use their hex value.

I've only added a few names for now.  The existing test only needs
NT_PRSTATUS, but I plan to reuse this script for a new test, in which
case I'll also need NT_FILE.  Additional names can be added in the
future as needed.

I then updated the gdb.base/corefile-no-threads.exp script to make use
of this functionality, and I improved the test pattern so that it
actually checks that a note was updated.

There should be no change in what is tested after this commit.

Reviewed-By: Keith Seitz <keiths@redhat.com>
gdb/testsuite/gdb.base/corefile-no-threads.exp
gdb/testsuite/gdb.base/corefile-no-threads.py