aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.dwarf2/implref-struct.exp
diff options
context:
space:
mode:
authorTom de Vries <tdevries@suse.de>2020-05-12 09:47:15 +0200
committerTom de Vries <tdevries@suse.de>2020-05-12 09:47:15 +0200
commit111b33f0b8d4872296bb0173bb82b0c5ddb9785d (patch)
tree3c0990e16c598f860efdb56bf7d72e63260f63ad /gdb/testsuite/gdb.dwarf2/implref-struct.exp
parentebf470809eba7c34713a2ea95e73e794582bcbd4 (diff)
downloadbinutils-111b33f0b8d4872296bb0173bb82b0c5ddb9785d.zip
binutils-111b33f0b8d4872296bb0173bb82b0c5ddb9785d.tar.gz
binutils-111b33f0b8d4872296bb0173bb82b0c5ddb9785d.tar.bz2
[gdb/testsuite] Fix duplicate test-names in gdb.dwarf2
We currently have these duplicate test-names in gdb.dwarf2: ... $ grep ^DUPLICATE: gdb.sum DUPLICATE: gdb.dwarf2/comp-unit-lang.exp: show language DUPLICATE: gdb.dwarf2/data-loc.exp: get integer valueof "sizeof (int)" DUPLICATE: gdb.dwarf2/data-loc.exp: get integer valueof "sizeof (void *)" DUPLICATE: gdb.dwarf2/data-loc.exp: get integer valueof "sizeof (int)" DUPLICATE: gdb.dwarf2/data-loc.exp: get integer valueof "sizeof (int)" DUPLICATE: gdb.dwarf2/data-loc.exp: ptype foo.array_type DUPLICATE: gdb.dwarf2/varval.exp: get integer valueof "sizeof (int)" DUPLICATE: gdb.dwarf2/varval.exp: get integer valueof "sizeof (void *)" DUPLICATE: gdb.dwarf2/implref-struct.exp: print-object=off: \ set print object off DUPLICATE: gdb.dwarf2/implref-struct.exp: print-object=on: \ set print object on DUPLICATE: gdb.dwarf2/dw2-bad-parameter-type.exp: ptype f ... Fix as appropriate. Tested on x86_64-linux. gdb/testsuite/ChangeLog: 2020-05-12 Tom de Vries <tdevries@suse.de> * gdb.dwarf2/comp-unit-lang.exp: Use with_test_prefix. * gdb.dwarf2/dw2-bad-parameter-type.exp: Same. * gdb.dwarf2/implref-struct.exp: Same. * gdb.dwarf2/varval.exp: Ensure get_sizeof is called once per type. * gdb.dwarf2/data-loc.exp: Same. Remove duplicate test.
Diffstat (limited to 'gdb/testsuite/gdb.dwarf2/implref-struct.exp')
-rw-r--r--gdb/testsuite/gdb.dwarf2/implref-struct.exp10
1 files changed, 6 insertions, 4 deletions
diff --git a/gdb/testsuite/gdb.dwarf2/implref-struct.exp b/gdb/testsuite/gdb.dwarf2/implref-struct.exp
index b7f1f16..b00408b 100644
--- a/gdb/testsuite/gdb.dwarf2/implref-struct.exp
+++ b/gdb/testsuite/gdb.dwarf2/implref-struct.exp
@@ -177,9 +177,11 @@ foreach_with_prefix print-object {"off" "on"} {
# Test assignment through the synthetic reference.
gdb_test_no_output "set (ref = s2)"
-foreach_with_prefix print-object {"off" "on"} {
- gdb_test_no_output "set print object ${print-object}"
+with_test_prefix "after assignment" {
+ foreach_with_prefix print-object {"off" "on"} {
+ gdb_test_no_output "set print object ${print-object}"
- gdb_test "print ref" " = \\(S &\\) @${address}: \\{${s2_members}\\}" "print ref after assignment"
- gdb_test "print s1" " = \\{${s2_members}\\}" "print s1 after assignment"
+ gdb_test "print ref" " = \\(S &\\) @${address}: \\{${s2_members}\\}" "print ref"
+ gdb_test "print s1" " = \\{${s2_members}\\}" "print s1"
+ }
}