This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[RFA] Fix testsuite gdb.base/bang.exp to work with remote targets


When using a remote target, like SID, you have to "continue" after
a "gdb_load", not "run".  Add support for this case.

2004-02-02  Fred Fish  <fnf@redhat.com>

	* gdb.base/bang.exp: Handling continuing on remote targets after a
	load.

Index: gdb.base/bang.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.base/bang.exp,v
retrieving revision 1.1
diff -u -p -r1.1 bang.exp
--- gdb.base/bang.exp	24 Jun 2003 22:04:06 -0000	1.1
+++ gdb.base/bang.exp	2 Feb 2004 20:20:04 -0000
@@ -1,4 +1,4 @@
-# Copyright 2003 Free Software Foundation, Inc.
+# Copyright 2003, 2004 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
@@ -35,7 +35,10 @@ gdb_reinitialize_dir $srcdir/$subdir
 gdb_load ${binfile}
 
 # Verify that we can run the program and that it terminates normally.
-gdb_test "run" \
-         ".*Program exited normally\." \
-         "run program"
+# For remote targets we simply continue after loading.
 
+if [target_info exists use_gdb_stub] {
+  gdb_test "continue" ".*Program exited normally\." "run program"
+} else {
+  gdb_test "run"      ".*Program exited normally\." "run program"
+}



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]