From: Fei Jie <feij.fnst@cn.fujitsu.com>
To: <gdb-patches@sourceware.org>
Subject: [PATCH v3 4/4] Add testcases to break.exp
Date: Tue, 10 Nov 2015 07:57:00 -0000 [thread overview]
Message-ID: <1447142188-20759-5-git-send-email-feij.fnst@cn.fujitsu.com> (raw)
In-Reply-To: <1447142188-20759-1-git-send-email-feij.fnst@cn.fujitsu.com>
add testcases to break.exp as follows:
*break with non-existed condition
*break with out-ou-ranged address
*break at offset -1
gdb/testsuite/ChangeLog:
* gdb.base/break.exp: Add new testcases.
---
gdb/testsuite/gdb.base/break.exp | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/gdb/testsuite/gdb.base/break.exp b/gdb/testsuite/gdb.base/break.exp
index f879bc8..117a18f 100644
--- a/gdb/testsuite/gdb.base/break.exp
+++ b/gdb/testsuite/gdb.base/break.exp
@@ -334,6 +334,11 @@ gdb_test "enable" "" ""
gdb_test "disable 10" "No breakpoint number 10." \
"disable non-existent breakpoint 10"
+gdb_test "break main if donot_exist == 0" \
+ "No symbol \"donot_exist\" in current context\\."
+gdb_test "break \*0xfffffffffffffffff" \
+ "Numeric constant too large\\."
+
gdb_test_no_output "set \$baz = 1.234"
gdb_test "disable \$baz" \
"Convenience variable must have integer value.*" \
@@ -399,6 +404,10 @@ set bp_location10 [gdb_get_line_number "set breakpoint 10 here"]
gdb_test "break +1" \
"Breakpoint.*at.* file .*$srcfile, line $bp_location10\\." \
"breakpoint offset +1"
+# Test break at offset -1.
+gdb_test "break -1" \
+ "Note: breakpoint .* also set at.*Breakpoint.*at.* file .*$srcfile, line.*" \
+ "breakpoint offset -1"
# Check to see if breakpoint is hit when stepped onto
--
1.8.3.1
next prev parent reply other threads:[~2015-11-10 7:57 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-10 7:56 [PATCH v3 0/4] Add some testcases Fei Jie
2015-11-10 7:57 ` [PATCH v3 1/4] Add testcases to default.exp Fei Jie
2015-12-06 13:51 ` Joel Brobecker
2015-11-10 7:57 ` [PATCH v3 3/4] Add testcases to list.exp and dfp-test.exp Fei Jie
2015-12-06 14:08 ` Joel Brobecker
2015-11-10 7:57 ` [PATCH v3 2/4] Add testcases to display.exp Fei Jie
2015-12-06 14:00 ` Joel Brobecker
2015-11-10 7:57 ` Fei Jie [this message]
2015-12-06 14:10 ` [PATCH v3 4/4] Add testcases to break.exp Joel Brobecker
2015-11-10 8:02 ` [PATCH v3 0/4] Add some testcases fj
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=1447142188-20759-5-git-send-email-feij.fnst@cn.fujitsu.com \
--to=feij.fnst@cn.fujitsu.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).