diff options
author | Joel Brobecker <brobecker@gnat.com> | 2011-01-31 03:11:40 +0000 |
---|---|---|
committer | Joel Brobecker <brobecker@gnat.com> | 2011-01-31 03:11:40 +0000 |
commit | 6b0c4c1f054ea7b759e683dc4c87abc569930cd5 (patch) | |
tree | 9554aea037cd7016c1f5ae0b04485694ac753fc6 /gdb/testsuite | |
parent | f4b54baf38b2b0db738de390f8061961bbedd386 (diff) | |
download | gdb-6b0c4c1f054ea7b759e683dc4c87abc569930cd5.zip gdb-6b0c4c1f054ea7b759e683dc4c87abc569930cd5.tar.gz gdb-6b0c4c1f054ea7b759e683dc4c87abc569930cd5.tar.bz2 |
fix typo during interactive_mode check in gdb_has_a_terminal
Discovered by Pierre Muller.
gdb/ChangeLog:
* inflow.c (gdb_has_a_terminal): Fix typo in interactive_mode
value test.
gdb/testsuite/ChangeLog:
* gdb.base/interact.exp: Add extra tests that verify that
the value of the interactive-mode setting does not change
after the script is sourced.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r-- | gdb/testsuite/ChangeLog | 6 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/interact.exp | 21 |
2 files changed, 24 insertions, 3 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 1b63bff..d05b6e6 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2011-01-31 Joel Brobecker <brobecker@adacore.com> + + * gdb.base/interact.exp: Add extra tests that verify that + the value of the interactive-mode setting does not change + after the script is sourced. + 2011-01-29 Jan Kratochvil <jan.kratochvil@redhat.com> * gdb.cp/noparam.exp: New file. diff --git a/gdb/testsuite/gdb.base/interact.exp b/gdb/testsuite/gdb.base/interact.exp index 1f15fd8..59caf1b 100644 --- a/gdb/testsuite/gdb.base/interact.exp +++ b/gdb/testsuite/gdb.base/interact.exp @@ -28,21 +28,36 @@ set script_output "\\$\[0-9\]+ = 1\[\r\n\]+\\$\[0-9\]+ = 2.*" gdb_exit gdb_start -# Test sourcing of the script with interactive mode `auto' +# Test sourcing of the script with interactive mode `auto'. +# Verify that evaluating the script does not cause an unexpected +# change of the interactive-mode setting. gdb_test_no_output "set interactive-mode auto" gdb_test "source zzz-gdbscript" "$script_output" \ "source script with interactive-mode auto" gdb_test "print 3" "= 3" "sanity check with interactive-mode auto" +gdb_test "show interactive-mode" \ + "Debugger's interactive mode is auto \\(currently .*\\)\\." \ + "show interactive-mode (auto)" -# Test sourcing of the script with interactive mode `on' +# Test sourcing of the script with interactive mode `on'. +# Verify that evaluating the script does not cause an unexpected +# change of the interactive-mode setting. gdb_test_no_output "set interactive-mode on" gdb_test "source zzz-gdbscript" "$script_output" \ "source script with interactive-mode on" gdb_test "print 4" "= 4" "sanity check with interactive-mode on" +gdb_test "show interactive-mode" \ + "Debugger's interactive mode is on\\." \ + "show interactive-mode (on)" -# Test sourcing of the script with interactive mode `of' +# Test sourcing of the script with interactive mode `off'. +# Verify that evaluating the script does not cause an unexpected +# change of the interactive-mode setting. gdb_test_no_output "set interactive-mode off" gdb_test "source zzz-gdbscript" "$script_output" \ "source script with interactive-mode off" gdb_test "print 5" "= 5" "sanity check with interactive-mode off" +gdb_test "show interactive-mode" \ + "Debugger's interactive mode is off\\." \ + "show interactive-mode (off)" |