diff options
author | Andrew Burgess <aburgess@redhat.com> | 2023-02-17 14:56:39 +0000 |
---|---|---|
committer | Andrew Burgess <aburgess@redhat.com> | 2023-02-28 10:56:28 +0000 |
commit | 1ccc4abbb3dda91c94c54d3aaaa417f0d7740a3f (patch) | |
tree | 48bc949870c9189faede9b122b6eae741fa4a4f3 /gdb/testsuite/gdb.mi/mi-watch.exp | |
parent | c8dfa492106ff57f3e1dd6731d5ba5b754f05616 (diff) | |
download | gdb-1ccc4abbb3dda91c94c54d3aaaa417f0d7740a3f.zip gdb-1ccc4abbb3dda91c94c54d3aaaa417f0d7740a3f.tar.gz gdb-1ccc4abbb3dda91c94c54d3aaaa417f0d7740a3f.tar.bz2 |
gdb/testsuite: extend the use of mi_clean_restart
The mi_clean_restart proc calls the mi_gdb_start proc passing no
arguments.
In this commit I add an extra (optional) argument to the
mi_clean_restart proc, and pass this through to mi_gdb_start.
The benefit of this is that we can now use mi_clean_restart when we
also want to pass the 'separate-mi-tty' or 'separate-inferior-tty'
flags to mi_gdb_start, and avoids having to otherwise duplicate the
contents of mi_clean_restart in different tests.
I've updated the obvious places where this new functionality can be
used, and I'm seeing no test regressions.
Reviewed-By: Pedro Alves <pedro@palves.net>
Diffstat (limited to 'gdb/testsuite/gdb.mi/mi-watch.exp')
-rw-r--r-- | gdb/testsuite/gdb.mi/mi-watch.exp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/gdb/testsuite/gdb.mi/mi-watch.exp b/gdb/testsuite/gdb.mi/mi-watch.exp index 5303a41..aaac761 100644 --- a/gdb/testsuite/gdb.mi/mi-watch.exp +++ b/gdb/testsuite/gdb.mi/mi-watch.exp @@ -150,14 +150,12 @@ proc test_watchpoint_all {mi_mode type} { return } - mi_gdb_exit - if {$mi_mode == "separate"} { set start_ops "separate-mi-tty" } else { set start_ops "" } - if [mi_gdb_start $start_ops] { + if [mi_clean_restart ${binfile} $start_ops] { return } @@ -170,10 +168,6 @@ proc test_watchpoint_all {mi_mode type} { "567\\^done" \ "hw watchpoints toggle" - mi_delete_breakpoints - mi_gdb_reinitialize_dir $srcdir/$subdir - mi_gdb_load ${binfile} - mi_runto callee4 test_watchpoint_creation_and_listing #test_rwatch_creation_and_listing |