aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite/gdb.mi/mi-basics.exp
diff options
context:
space:
mode:
authorBob Rossi <bob@brasko.net>2005-08-04 01:52:31 +0000
committerBob Rossi <bob@brasko.net>2005-08-04 01:52:31 +0000
commitecd3fd0f9d94eb0d6675090a4d9c6ce904817f20 (patch)
tree9c284564f3e2823ccd3606561b8ba3867d665f38 /gdb/testsuite/gdb.mi/mi-basics.exp
parent1e035701d67ed8a8bc72ec9e393f2d984090a60c (diff)
downloadgdb-ecd3fd0f9d94eb0d6675090a4d9c6ce904817f20.zip
gdb-ecd3fd0f9d94eb0d6675090a4d9c6ce904817f20.tar.gz
gdb-ecd3fd0f9d94eb0d6675090a4d9c6ce904817f20.tar.bz2
2005-08-02 Bob Rossi <bob@brasko.net>
* gdb.mi/mi-basics.exp: Tell mi_gdb_start to use a PTY for inferior. (test_setshow_inferior_tty): Add global mi_inferior_tty_name to scope. Change tests to inferior-tty-set/show. * gdb.mi/mi-console.exp: Tell mi_gdb_start to use a PTY for inferior. (47-exec-next): Use mi_gdb_test to get GDB and Inferior output. * gdb.mi/mi-syn-frame.exp: Tell mi_gdb_start to use a PTY for inferior. Use mi_gdb_test to get GDB and Inferior output. * lib/mi-support.exp (mi_inferior_spawn_id): Add inferior PTY descriptor. (mi_inferior_tty_name): Add inferior PTY file name. (mi_gdb_start): Add INFERIOR_PTY parameter. (mi_gdb_test): Add IPATTERN parameter.
Diffstat (limited to 'gdb/testsuite/gdb.mi/mi-basics.exp')
-rw-r--r--gdb/testsuite/gdb.mi/mi-basics.exp17
1 files changed, 13 insertions, 4 deletions
diff --git a/gdb/testsuite/gdb.mi/mi-basics.exp b/gdb/testsuite/gdb.mi/mi-basics.exp
index 0d2b06e..7e576a7 100644
--- a/gdb/testsuite/gdb.mi/mi-basics.exp
+++ b/gdb/testsuite/gdb.mi/mi-basics.exp
@@ -33,7 +33,7 @@ load_lib mi-support.exp
set MIFLAGS "-i=mi"
gdb_exit
-if [mi_gdb_start] {
+if [mi_gdb_start separate-inferior-tty] {
continue
}
@@ -238,6 +238,7 @@ proc test_path_specification {} {
proc test_setshow_inferior_tty {} {
global mi_gdb_prompt
+ global mi_inferior_tty_name
# Test that the commands,
# -inferior-tty-set
@@ -245,8 +246,8 @@ proc test_setshow_inferior_tty {} {
# are setting/getting the same data in GDB.
mi_gdb_test "301-inferior-tty-show" \
- "301\\\^done" \
- "initial tty is empty"
+ "301\\\^done,inferior_tty_terminal=\"$mi_inferior_tty_name\"" \
+ "initial tty is mi_inferior_tty_name"
mi_gdb_test "302-inferior-tty-set /dev/pts/1" \
"302\\\^done" \
@@ -262,7 +263,15 @@ proc test_setshow_inferior_tty {} {
mi_gdb_test "305-inferior-tty-show" \
"305\\\^done" \
- "final tty is empty"
+ "make sure tty is empty"
+
+ mi_gdb_test "306-inferior-tty-set $mi_inferior_tty_name" \
+ "306\\\^done" \
+ "set tty to mi_inferior_tty_name (the way it was)"
+
+ mi_gdb_test "307-inferior-tty-show" \
+ "307\\\^done,inferior_tty_terminal=\"$mi_inferior_tty_name\"" \
+ "verify tty is correct"
}
if [test_mi_interpreter_selection] {