aboutsummaryrefslogtreecommitdiff
path: root/gdb/testsuite
diff options
context:
space:
mode:
authorFred Fish <fnf@specifix.com>2002-05-01 15:39:32 +0000
committerFred Fish <fnf@specifix.com>2002-05-01 15:39:32 +0000
commita6befae84def7b445a76e360deba6dde20e03052 (patch)
tree63cc7daf1a377400f87fb1999f90cd04715a9036 /gdb/testsuite
parentd8731e7dad5a4451c4214cc99fe76ca0e2c4d9ff (diff)
downloadgdb-a6befae84def7b445a76e360deba6dde20e03052.zip
gdb-a6befae84def7b445a76e360deba6dde20e03052.tar.gz
gdb-a6befae84def7b445a76e360deba6dde20e03052.tar.bz2
2002-05-01 Fred Fish <fnf@redhat.com>
* gdb.base/completion.exp: Handle completions of "./Make" for more than one completion possibility, as is the case when we build and test in the source tree.
Diffstat (limited to 'gdb/testsuite')
-rw-r--r--gdb/testsuite/ChangeLog6
-rw-r--r--gdb/testsuite/gdb.base/completion.exp10
2 files changed, 14 insertions, 2 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 2e8ec61..1936f2e 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,9 @@
+2002-05-01 Fred Fish <fnf@redhat.com>
+
+ * gdb.base/completion.exp: Handle completions of "./Make" for
+ more than one completion possibility, as is the case when we
+ build and test in the source tree.
+
2002-04-29 Anthony Green <green@redhat.com>
* gdb.java/jmisc1.exp: New file.
diff --git a/gdb/testsuite/gdb.base/completion.exp b/gdb/testsuite/gdb.base/completion.exp
index d8d5baf..f8f4568 100644
--- a/gdb/testsuite/gdb.base/completion.exp
+++ b/gdb/testsuite/gdb.base/completion.exp
@@ -1,4 +1,4 @@
-# Copyright 1998, 1999 Free Software Foundation, Inc.
+# Copyright 1998, 1999, 2002 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
@@ -631,12 +631,18 @@ gdb_expect {
#
# So, we avoid long lines. We `cd' to ${objdir} first, and then do
# the completion relative to the current directory.
+#
+# Note that if we are building in the source tree, then there will be
+# more than one completion for ./Make, so we need to handle that also.
+# A better long term solution might be to create a temporary directory,
+# populate it with a set of known names, and use that directory to
+# test completions.
gdb_test "cd ${objdir}" "Working directory ${objdir}.*" "cd to \${objdir}"
send_gdb "file ./Make\t"
sleep 1
gdb_expect {
- -re "file ./Makefile.*$"\
+ -re "^file ./Make(\\\x07|)file.*$"\
{ send_gdb "\n"
gdb_expect {
-re "\r\nA program is being debugged already\\. Kill it\\? \\(y or n\\) $"\