From: Tom de Vries Date: Tue, 20 Oct 2020 08:20:24 +0000 (+0200) Subject: [gdb/testsuite] Use $gdb_test_file_name in gdb.dwarf2 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0cd2ad78f15e746bde8eb7d4c1b6bb5cb6c174cc;p=binutils-gdb.git [gdb/testsuite] Use $gdb_test_file_name in gdb.dwarf2 In f.i. gdb.dwarf2/dw2-line-number-zero.exp we find: ... verbose "Skipping dw2-line-number-zero test." ... Make the skip messages use the gdb_test_file_name variable, to reduce the amount of changes that needs to be made when coping a test-case. Tested on x86_64-linux. gdb/testsuite/ChangeLog: 2020-10-20 Tom de Vries * gdb.dwarf2/dw2-error.exp: Use $gdb_test_file_name. * gdb.dwarf2/dw2-line-number-zero.exp: Same. * gdb.dwarf2/dw2-main-no-line-number.exp: Same. * gdb.dwarf2/dw2-ranges-base.exp: Same. * gdb.dwarf2/dw2-ranges.exp: Same. * gdb.dwarf2/dw2-vendor-extended-opcode.exp: Same. * gdb.dwarf2/var-access.exp: Same. --- diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 0a22f67864d..8772b809b7d 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,13 @@ +2020-10-20 Tom de Vries + + * gdb.dwarf2/dw2-error.exp: Use $gdb_test_file_name. + * gdb.dwarf2/dw2-line-number-zero.exp: Same. + * gdb.dwarf2/dw2-main-no-line-number.exp: Same. + * gdb.dwarf2/dw2-ranges-base.exp: Same. + * gdb.dwarf2/dw2-ranges.exp: Same. + * gdb.dwarf2/dw2-vendor-extended-opcode.exp: Same. + * gdb.dwarf2/var-access.exp: Same. + 2020-10-19 Tom Tromey PR tui/26719 diff --git a/gdb/testsuite/gdb.dwarf2/dw2-error.exp b/gdb/testsuite/gdb.dwarf2/dw2-error.exp index 53d6339dee7..e698752212a 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-error.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-error.exp @@ -23,7 +23,7 @@ if {![dwarf2_support]} { standard_testfile .S if { ![istarget "x86_64-*-*"] || ![is_lp64_target] } { - verbose "Skipping $testfile.exp" + verbose "Skipping $gdb_test_file_name." return } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp b/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp index 164397e81e7..1d9f01a1d54 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-line-number-zero.exp @@ -16,7 +16,7 @@ load_lib dwarf.exp # This test can only be run on targets which support DWARF-2 and use gas. if {![dwarf2_support]} { - verbose "Skipping dw2-line-number-zero test." + verbose "Skipping $gdb_test_file_name." return 0 } @@ -25,7 +25,7 @@ if [get_compiler_info] { return -1 } if !$gcc_compiled { - verbose "Skipping dw2-line-number-zero test." + verbose "Skipping $gdb_test_file_name." return 0 } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp b/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp index 1f62d0ccfc2..965cc437b1c 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-main-no-line-number.exp @@ -18,11 +18,9 @@ load_lib dwarf.exp -set testname [file rootname [file tail [info script]]] - # This test can only be run on targets which support DWARF-2 and use gas. if {![dwarf2_support]} { - verbose "Skipping $testname test." + verbose "Skipping $gdb_test_file_name." return 0 } @@ -31,7 +29,7 @@ if [get_compiler_info] { return -1 } if !$gcc_compiled { - verbose "Skipping $testname test." + verbose "Skipping $gdb_test_file_name." return 0 } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp b/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp index 0d363b1a443..3f03fa6f7ec 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ranges-base.exp @@ -19,7 +19,7 @@ load_lib dwarf.exp # This test can only be run on targets which support DWARF-2 and use gas. if {![dwarf2_support]} { - verbose "Skipping DW_AT_ranges test." + verbose "Skipping $gdb_test_file_name." return 0 } @@ -28,7 +28,7 @@ if [get_compiler_info] { return -1 } if !$gcc_compiled { - verbose "Skipping DW_AT_ranges test." + verbose "Skipping $gdb_test_file_name." return 0 } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-ranges.exp b/gdb/testsuite/gdb.dwarf2/dw2-ranges.exp index adddc93ff4c..c15b0607ed3 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-ranges.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-ranges.exp @@ -19,7 +19,7 @@ load_lib dwarf.exp # This test can only be run on targets which support DWARF-2 and use gas. if {![dwarf2_support]} { - verbose "Skipping DW_AT_ranges test." + verbose "Skipping $gdb_test_file_name." return 0 } @@ -28,7 +28,7 @@ if [get_compiler_info] { return -1 } if !$gcc_compiled { - verbose "Skipping DW_AT_ranges test." + verbose "Skipping $gdb_test_file_name." return 0 } diff --git a/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp b/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp index 08f0e29b7e2..d2861d7f751 100644 --- a/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp +++ b/gdb/testsuite/gdb.dwarf2/dw2-vendor-extended-opcode.exp @@ -16,7 +16,7 @@ load_lib dwarf.exp # This test can only be run on targets which support DWARF-2 and use gas. if {![dwarf2_support]} { - verbose "Skipping dw2-vendor-extended-opcode test." + verbose "Skipping $gdb_test_file_name." return 0 } @@ -25,7 +25,7 @@ if [get_compiler_info] { return -1 } if !$gcc_compiled { - verbose "Skipping dw2-vendor-extended-opcode test." + verbose "Skipping $gdb_test_file_name." return 0 } diff --git a/gdb/testsuite/gdb.dwarf2/var-access.exp b/gdb/testsuite/gdb.dwarf2/var-access.exp index a669b4c971a..c0d21ba96b8 100644 --- a/gdb/testsuite/gdb.dwarf2/var-access.exp +++ b/gdb/testsuite/gdb.dwarf2/var-access.exp @@ -40,7 +40,7 @@ if { [is_aarch64_target] } { } elseif { [is_amd64_regs_target] } { set regname {rax rdx} } else { - verbose "Skipping tests for accessing DWARF-described variables." + verbose "Skipping $gdb_test_file_name." return }