]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
[gdb/testsuite] Fix clean_restart <absolute filename> in gdb.tui
authorTom de Vries <tdevries@suse.de>
Tue, 2 Sep 2025 08:55:02 +0000 (10:55 +0200)
committerTom de Vries <tdevries@suse.de>
Tue, 2 Sep 2025 08:55:02 +0000 (10:55 +0200)
Fix clean_restart <absolute filename> in the test-cases in gdb.tui.

Tested on x86_64-linux.

gdb/testsuite/gdb.tui/compact-source.exp
gdb/testsuite/gdb.tui/main-2.exp
gdb/testsuite/gdb.tui/tui-disasm-long-lines.exp
gdb/testsuite/gdb.tui/tui-disasm-styling.exp
gdb/testsuite/gdb.tui/tui-focus.exp
gdb/testsuite/gdb.tui/tui-layout.exp

index b050159260c1b88150d7f5a4eda9acdc52fca864..33d8827164e886d5e4cdb1f5d8cf482097d4f4e7 100644 (file)
@@ -41,7 +41,7 @@ if {[build_executable "failed to prepare" ${testfile} ${srcfile}] == -1} {
     return -1
 }
 
-Term::clean_restart 24 80 $binfile
+Term::clean_restart 24 80 $testfile
 
 gdb_test_no_output "maint set tui-left-margin-verbose on"
 gdb_test_no_output "set tui compact-source on"
index 14a7cb1e5ac4e30ea0e24dd51bbc97b7f4876698..2bc6b8d978e4b7676e0b7bb4a080aa8d659c5200 100644 (file)
@@ -26,7 +26,7 @@ if { [build_executable "failed to prepare" $testfile $srcfile ] == -1} {
     return -1
 }
 
-Term::clean_restart 24 80 $binfile
+Term::clean_restart 24 80 $testfile
 
 if {![runto_main]} {
     perror "test suppressed"
index 35f990d8a204a055b8b6ba21ef3890d3c9962573..7a9841fd0c8d915b27d4e34612bcb85689082b7b 100644 (file)
@@ -35,7 +35,7 @@ if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "$binfile" \
     }
 }
 
-Term::clean_restart 24 80 $binfile
+Term::clean_restart 24 80 $testfile
 if {![Term::prepare_for_tui]} {
     unsupported "TUI not supported"
     return
index 43b8ecf5fb09ae09db4637e39c746fe566c90ea8..685974411dfbba1d83104056812447585ee6a41f 100644 (file)
@@ -37,7 +37,7 @@ proc check_asm_output { expect_styled testname } {
        $testname
 }
 
-Term::clean_restart 24 80 $binfile
+Term::clean_restart 24 80 $testfile
 if {![Term::enter_tui]} {
     unsupported "TUI not supported"
     return
index 26e5060636e444a908bee102829313099d09981a..50a331563cb8f20159c3a570112a6f2bccf8026b 100644 (file)
@@ -36,7 +36,7 @@ foreach spec {{src true} {cmd true} {status true} {regs false} \
     lassign $spec window valid_p
     with_test_prefix "window=$window" {
 
-       Term::clean_restart 24 80 $binfile
+       Term::clean_restart 24 80 $testfile
        if {![Term::prepare_for_tui]} {
            unsupported "TUI not supported"
            return
@@ -75,7 +75,7 @@ foreach spec {{src true} {cmd true} {status true} {regs false} \
 
 # Use the Python TUI API to exercise some of the ambiguous window name
 # handling parts of the 'focus' command.
-Term::clean_restart 24 80 $binfile
+Term::clean_restart 24 80 $testfile
 if {[allow_python_tests]} {
     # Create a very simple tui window.
     gdb_py_test_silent_cmd \
index 7bb0ea15fed15d83198d88303957dc210ec46758..f6048716a2c3c1b48370d9953c3225e8f876a7aa 100644 (file)
@@ -40,7 +40,7 @@ if {[prepare_for_testing "failed to prepare" ${testfile} ${srcfile}]} {
 # happens to be in after a call to clean_restart.
 
 proc test_layout_or_focus {layout_name terminal execution} {
-    global binfile gdb_prompt
+    global gdb_prompt
 
     set dumb_terminal [string equal $terminal "dumb"]
 
@@ -48,9 +48,9 @@ proc test_layout_or_focus {layout_name terminal execution} {
     save_vars { env(TERM) } {
        setenv TERM $terminal
        if {$dumb_terminal} {
-           clean_restart $binfile
+           clean_restart $::testfile
        } else {
-           Term::clean_restart 24 80 $binfile
+           Term::clean_restart 24 80 $::testfile
            if {![Term::prepare_for_tui]} {
                unsupported "TUI not supported"
                return