From: Sandra Loosemore <sandra@codesourcery.com>
To: <gdb-patches@sourceware.org>
Subject: [patch] avoid remote-host failures in gdb.linespec/linespec.exp
Date: Thu, 04 Apr 2013 08:13:00 -0000 [thread overview]
Message-ID: <515CB97A.7010703@codesourcery.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 809 bytes --]
This patch gets rid of a couple test fails in linespec.exp that we've
observed from remote-host i686-mingw32 testing of Canadian cross
toolchains for multiple targets. As I observed in my notes on a
previous patch
http://sourceware.org/ml/gdb-patches/2013-04/msg00053.html
in this configuration the test harness copies the source files to the
working directory on the remote host and compiles them there, without a
directory prefix. So, tests that depend on a directory prefix being
present (in this case, to disambiguate files that otherwise have the
same name) can't be expected to work.
OK to commit?
-Sandra
2013-04-03 Sandra Loosemore <sandra@codesourcery.com>
gdb/testsuite/
* gdb.linespec/linespec.exp (test_class): Make dir/file:line tests
conditional for non-remote hosts only.
[-- Attachment #2: linespec.patch --]
[-- Type: text/x-patch, Size: 1372 bytes --]
Index: gdb/testsuite/gdb.linespec/linespec.exp
===================================================================
RCS file: /cvs/src/src/gdb/testsuite/gdb.linespec/linespec.exp,v
retrieving revision 1.6
diff -u -p -r1.6 linespec.exp
--- gdb/testsuite/gdb.linespec/linespec.exp 1 Jan 2013 06:41:24 -0000 1.6
+++ gdb/testsuite/gdb.linespec/linespec.exp 3 Apr 2013 23:11:38 -0000
@@ -43,13 +43,19 @@ if {$l1 != $l2} {
error "somebody incompatibly modified the source files needed by linespec.exp"
}
-gdb_test "break one/thefile.cc:$l1" \
- "Breakpoint $decimal at $hex: file .*thefile.cc, line $l1." \
- "single-location break using dir/file:line"
-
-gdb_test "clear one/thefile.cc:$l1" \
- "Deleted breakpoint $decimal *" \
- "clear breakpoint using dir/file:line"
+# Copying files to a remote host loses the directory prefix during
+# compilation.
+if { [is_remote host] } {
+ untested "breakpoints using dir/file:line"
+} else {
+ gdb_test "break one/thefile.cc:$l1" \
+ "Breakpoint $decimal at $hex: file .*thefile.cc, line $l1." \
+ "single-location break using dir/file:line"
+
+ gdb_test "clear one/thefile.cc:$l1" \
+ "Deleted breakpoint $decimal *" \
+ "clear breakpoint using dir/file:line"
+}
gdb_test "break thefile.cc:$l1" \
"Breakpoint $decimal at $hex: thefile.cc:$l1. \[(\]2 locations\[)\]" \
next reply other threads:[~2013-04-03 23:21 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-04 8:13 Sandra Loosemore [this message]
2013-04-04 16:09 ` Pedro Alves
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=515CB97A.7010703@codesourcery.com \
--to=sandra@codesourcery.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox