diff options
author | Pedro Alves <palves@redhat.com> | 2017-03-08 00:14:58 +0000 |
---|---|---|
committer | Pedro Alves <palves@redhat.com> | 2017-03-08 00:14:58 +0000 |
commit | 1a4dd9ddae4ce51724b4e08c6304e7c64f8f916f (patch) | |
tree | 8383c4c42f8a301311dd8026e5094c79c52f71da /gdb/testsuite | |
parent | 7cbbff33a502dcba0264a1935840345274b8aee2 (diff) | |
download | gdb-1a4dd9ddae4ce51724b4e08c6304e7c64f8f916f.zip gdb-1a4dd9ddae4ce51724b4e08c6304e7c64f8f916f.tar.gz gdb-1a4dd9ddae4ce51724b4e08c6304e7c64f8f916f.tar.bz2 |
Move TUI completion tests to gdb.tui/completion.exp
gdb/testsuite/ChangeLog:
2017-03-08 Pedro Alves <palves@redhat.com>
* gdb.base/completion.exp: Move TUI completion tests to ...
* gdb.tui/completion.exp: ... this new file.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r-- | gdb/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/testsuite/gdb.base/completion.exp | 37 | ||||
-rw-r--r-- | gdb/testsuite/gdb.tui/completion.exp | 58 |
3 files changed, 63 insertions, 37 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index d385907..f986520 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,5 +1,10 @@ 2017-03-08 Pedro Alves <palves@redhat.com> + * gdb.base/completion.exp: Move TUI completion tests to ... + * gdb.tui/completion.exp: ... this new file. + +2017-03-08 Pedro Alves <palves@redhat.com> + * gdb.base/tui-disasm-long-lines.c, gdb.base/tui-disasm-long-lines.exp, gdb.base/tui-layout.c, gdb.base/tui-layout.exp: Move to ... diff --git a/gdb/testsuite/gdb.base/completion.exp b/gdb/testsuite/gdb.base/completion.exp index 4a3ee4b..6597ea7 100644 --- a/gdb/testsuite/gdb.base/completion.exp +++ b/gdb/testsuite/gdb.base/completion.exp @@ -940,40 +940,3 @@ gdb_test_multiple "" "$test" { pass "$test" } } - -gdb_test_no_output "set max-completions unlimited" - -if {![skip_tui_tests] && ![target_info exists gdb,nointerrupts]} { - set test "test completion of layout names" - send_gdb "layout\t\t\t" - gdb_test_multiple "" "$test" { - -re "asm *next *prev *regs *split *src *\r\n$gdb_prompt layout $" { - pass "$test" - } - } - send_gdb "\003" - set test "quit command input after testing layout completion" - gdb_test_multiple "" "$test" { - -re "$gdb_prompt $" { - pass "$test" - } - } -} -if {![skip_tui_tests] && ![target_info exists gdb,nointerrupts]} { - with_test_prefix "focus command" { - set test "test completion" - send_gdb "focus \t\t" - gdb_test_multiple "" "$test" { - -re "cmd *next *prev *src *\r\n$gdb_prompt focus $" { - pass "$test" - } - } - send_gdb "\003" - set test "quit command input after testing completion" - gdb_test_multiple "" "$test" { - -re "$gdb_prompt $" { - pass "$test" - } - } - } -} diff --git a/gdb/testsuite/gdb.tui/completion.exp b/gdb/testsuite/gdb.tui/completion.exp new file mode 100644 index 0000000..ac5d5f2 --- /dev/null +++ b/gdb/testsuite/gdb.tui/completion.exp @@ -0,0 +1,58 @@ +# Copyright 2015-2017 Free Software Foundation, Inc. + +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. + +gdb_exit +gdb_start + +if {[skip_tui_tests] || [target_info exists gdb,nointerrupts]} { + return +} + +gdb_test_no_output "set max-completions unlimited" + +with_test_prefix "completion of layout names" { + set test "tab completion" + send_gdb "layout\t\t\t" + gdb_test_multiple "" "$test" { + -re "asm *next *prev *regs *split *src *\r\n$gdb_prompt layout $" { + pass "$test" + } + } + send_gdb "\003" + set test "quit command input" + gdb_test_multiple "" "$test" { + -re "$gdb_prompt $" { + pass "$test" + } + } +} + +with_test_prefix "completion of focus command" { + set test "tab completion" + send_gdb "focus \t\t" + gdb_test_multiple "" "$test" { + -re "cmd *next *prev *src *\r\n$gdb_prompt focus $" { + pass "$test" + } + } + + send_gdb "\003" + set test "quit command input" + gdb_test_multiple "" "$test" { + -re "$gdb_prompt $" { + pass "$test" + } + } +} |