+2015-12-14 Sandra Loosemore <sandra@codesourcery.com>
+
+ * gdb.base/completion.exp: Skip tests that interrupt GDB with
+ ctrl-C if nointerrupts target property is set.
+ * gdb.base/double-prompt-target-event-error.exp: Likewise.
+ * gdb.base/paginate-after-ctrl-c-running.exp: Likewise.
+ * gdb.base/paginate-bg-execution.exp: Likewise.
+ * gdb.base/paginate-execution-startup.exp: Likewise.
+ * gdb.base/random-signal.exp: Likewise.
+ * gdb.base/range-stepping.exp: Likewise.
+ * gdb.cp/annota2.exp: Likewise.
+ * gdb.cp/annota3.exp: Likewise.
+ * gdb.gdb/selftest.exp: Likewise.
+ * gdb.threads/continue-pending-status.exp: Likewise.
+ * gdb.threads/leader-exit.exp: Likewise.
+ * gdb.threads/manythreads.exp: Likewise.
+ * gdb.threads/pthreads.exp: Likewise.
+ * gdb.threads/schedlock.exp: Likewise.
+ * gdb.threads/sigthread.exp: Likewise.
+
2015-12-11 Don Breazeal <donb@codesourcery.com>
* gdb.base/execl-update-breakpoints.exp (main): Enable for target
gdb_test_no_output "set max-completions unlimited"
-if {![skip_tui_tests]} {
+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" {
}
}
}
-if {![skip_tui_tests]} {
+if {![skip_tui_tests] && ![target_info exists gdb,nointerrupts]} {
with_test_prefix "focus command" {
set test "test completion"
send_gdb "focus \t\t"
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping double-prompt-target-event-error.exp because of nointerrupts."
+ return
+}
+
standard_testfile
if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug] == -1} {
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping paginate-after-ctrl-c-running.exp because of nointerrupts."
+ return
+}
+
standard_testfile
if {[build_executable "failed to prepare" $testfile $srcfile debug] == -1} {
}
test_bg_execution_pagination_return
-test_bg_execution_pagination_cancel "ctrl-c"
+if ![target_info exists gdb,nointerrupts] {
+ test_bg_execution_pagination_cancel "ctrl-c"
+}
test_bg_execution_pagination_cancel "quit"
if {[probe_can_run_cmdline] > 0} {
test_fg_execution_pagination_return
- test_fg_execution_pagination_cancel "ctrl-c"
+ if ![target_info exists gdb,nointerrupts] {
+ test_fg_execution_pagination_cancel "ctrl-c"
+ }
test_fg_execution_pagination_cancel "quit"
}
continue
}
+# This test requires sending ^C to interrupt the running target.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping random-signal.exp because of nointerrupts."
+ return
+}
+
standard_testfile
if {[prepare_for_testing $testfile.exp $testfile $srcfile debug]} {
# Check that range stepping works well even when it is interrupted by
# ctrl-c.
-with_test_prefix "interrupt" {
- gdb_test_no_output "set debug remote 1"
-
- send_gdb "next\n"
- sleep 1
- send_gdb "\003"
-
- # GDB should send one vCont;r and receive one stop reply for
- # SIGINT:
- # --> vCont;rSTART,END (range step)
- # <-- T02 (SIGINT)
-
- set vcont_r_counter 0
-
- set test "send ctrl-c to GDB"
- gdb_test_multiple "" $test {
- -re "vCont;r\[^\r\n\]*\.\.\." {
- incr vcont_r_counter
- exp_continue
+if ![target_info exists gdb,nointerrupts] {
+ with_test_prefix "interrupt" {
+ gdb_test_no_output "set debug remote 1"
+
+ send_gdb "next\n"
+ sleep 1
+ send_gdb "\003"
+
+ # GDB should send one vCont;r and receive one stop reply for
+ # SIGINT:
+ # --> vCont;rSTART,END (range step)
+ # <-- T02 (SIGINT)
+
+ set vcont_r_counter 0
+
+ set test "send ctrl-c to GDB"
+ gdb_test_multiple "" $test {
+ -re "vCont;r\[^\r\n\]*\.\.\." {
+ incr vcont_r_counter
+ exp_continue
+ }
+ -re "Program received signal SIGINT.*$gdb_prompt $" {
+ pass $test
+ }
}
- -re "Program received signal SIGINT.*$gdb_prompt $" {
- pass $test
+ gdb_test_no_output "set debug remote 0"
+
+ # Check the number of 'vCont;r' packets.
+ if { $vcont_r_counter == 1 } {
+ pass "${test}: 1 vCont;r"
+ } else {
+ fail "${test}: 1 vCont;r"
}
- }
- gdb_test_no_output "set debug remote 0"
- # Check the number of 'vCont;r' packets.
- if { $vcont_r_counter == 1 } {
- pass "${test}: 1 vCont;r"
- } else {
- fail "${test}: 1 vCont;r"
+ # Break the loop earlier and continue range stepping.
+ gdb_test "set variable c = 0"
+ exec_cmd_expect_vCont_count "next" 1
}
-
- # Break the loop earlier and continue range stepping.
- gdb_test "set variable c = 0"
- exec_cmd_expect_vCont_count "next" 1
}
# Check that range stepping doesn't break software watchpoints. With
# test:
# annotate-quit
#
-send_gdb "\003"
-gdb_expect {
- -re "\r\n\032\032error-begin\r\nQuit\r\n\r\n\032\032quit\r\n$gdb_prompt$" \
+if ![target_info exists gdb,nointerrupts] {
+ send_gdb "\003"
+ gdb_expect {
+ -re "\r\n\032\032error-begin\r\nQuit\r\n\r\n\032\032quit\r\n$gdb_prompt$" \
{ pass "annotate-quit" }
- -re ".*$gdb_prompt$" { fail "annotate-quit" }
- timeout { fail "annotate-quit (timeout)" }
+ -re ".*$gdb_prompt$" { fail "annotate-quit" }
+ timeout { fail "annotate-quit (timeout)" }
+ }
}
#
# test:
# annotate-quit
#
-send_gdb "\003"
-gdb_expect_list "annotate-quit" "$gdb_prompt$" {
- "\r\n\032\032error-begin\r\n"
- "Quit\r\n"
- "\r\n\032\032quit\r\n"
+if ![target_info exists gdb,nointerrupts] {
+ send_gdb "\003"
+ gdb_expect_list "annotate-quit" "$gdb_prompt$" {
+ "\r\n\032\032error-begin\r\n"
+ "Quit\r\n"
+ "\r\n\032\032quit\r\n"
+ }
}
#
}
# kill the xgdb process
- set description "send ^C to child process"
- send_gdb "\003"
- gdb_expect {
- -re "Program received signal SIGINT.*$gdb_prompt $" {
- pass "$description"
- }
- -re ".*$gdb_prompt $" {
- fail "$description"
- }
- timeout {
- fail "$description (timeout)"
+ if ![target_info exists gdb,nointerrupts] {
+ set description "send ^C to child process"
+ send_gdb "\003"
+ gdb_expect {
+ -re "Program received signal SIGINT.*$gdb_prompt $" {
+ pass "$description"
+ }
+ -re ".*$gdb_prompt $" {
+ fail "$description"
+ }
+ timeout {
+ fail "$description (timeout)"
+ }
}
}
# thread, then switching to a thread that has a status pending and
# continuing.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping continue-pending-status.exp because of nointerrupts."
+ return
+}
+
standard_testfile
if [prepare_for_testing "failed to prepare" $testfile $srcfile {debug pthreads}] {
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping leader-exit.exp because of nointerrupts."
+ return
+}
+
# Exit of the thread group leader should not break GDB.
standard_testfile
# This file was written by Jeff Johnston. (jjohnstn@redhat.com)
+# This test requires sending ^C to interrupt the running target.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping manythreads.exp because of nointerrupts."
+ return
+}
standard_testfile
# This file was written by Fred Fish. (fnf@cygnus.com)
+# This test requires sending ^C to interrupt the running target.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping pthreads.exp because of nointerrupts."
+ return
+}
standard_testfile
#
# This test covers the various forms of "set scheduler-locking".
+# This test requires sending ^C to interrupt the running target.
+
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping schedlock.exp because of nointerrupts."
+ return
+}
standard_testfile
}
}
+# This test requires sending ^C to interrupt the running target.
+if [target_info exists gdb,nointerrupts] {
+ verbose "Skipping sigthread.exp because of nointerrupts."
+ return
+}
+
# For this to work we must be sure to consume the "Continuing."
# message first, or GDB's signal handler may not be in place.
after 500 {send_gdb "\003"}