batch-preserve-term-settings.exp: use send_quit_command some more
authorPatrick Palka <patrick@parcs.ath.cx>
Wed, 29 Jul 2015 16:44:21 +0000 (12:44 -0400)
committerPatrick Palka <patrick@parcs.ath.cx>
Wed, 29 Jul 2015 21:00:40 +0000 (17:00 -0400)
Just a slight cleanup.  Committed as obvious.

gdb/testsuite/ChangeLog:

* gdb.base/batch-preserve-term-settings.exp
(test_terminal_settings_preserved_after_cli_exit): Use
send_quit_command.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.base/batch-preserve-term-settings.exp

index 3722e287f160df6f71e8f4d6089054fb7acbfb55..171784e697fa133edd238cb7ccc29179edd70b0e 100644 (file)
@@ -1,3 +1,9 @@
+2015-07-29  Patrick Palka  <patrick@parcs.ath.cx>
+
+       * gdb.base/batch-preserve-term-settings.exp
+       (test_terminal_settings_preserved_after_cli_exit): Use
+       send_quit_command.
+
 2015-07-29  Pedro Alves  <palves@redhat.com>
            Don Breazeal  <donb@codesourcery.com>
 
index a4c87967626a4302ac094f0f3b5c421c7d5a1216..90f40576ddd1c8c26948d8698b350e73af2f00bd 100644 (file)
@@ -251,23 +251,7 @@ proc test_terminal_settings_preserved_after_cli_exit { cmds } {
        }
     }
 
-    set test "quit gdb"
-    send_gdb "quit\n"
-    gdb_expect {
-       -re "(y or n)" {
-           send_gdb "y\n"
-           exp_continue
-       }
-       -re ".*$shell_prompt_re$" {
-           pass $test
-       }
-       timeout {
-           fail "$test (timeout)"
-       }
-       eof {
-           fail "$test (eof)"
-       }
-    }
+    send_quit_command "quit gdb"
 
     set test "terminal settings preserved"
     if $stty_supported {