This is the mail archive of the gdb-patches@sourceware.org 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]

[PATCH] Add testcases for set&show backtrace and copying


Add testcases to gdb.base/setshow.exp as follows:
    *set&show backtrace limit
    *set&show backtrace past-entry
    *set&show backtrace past-main
    *show copying
---
 gdb/testsuite/gdb.base/setshow.exp | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)

diff --git a/gdb/testsuite/gdb.base/setshow.exp b/gdb/testsuite/gdb.base/setshow.exp
index d8295e2..502d008 100644
--- a/gdb/testsuite/gdb.base/setshow.exp
+++ b/gdb/testsuite/gdb.base/setshow.exp
@@ -227,6 +227,26 @@ gdb_test_no_output "set listsize 100" "set listsize 100"
 #test show listsize 100
 gdb_test "show listsize" "Number of source lines gdb will list by default is 100..*" "show listsize (100)" 
 
+#test set backtrace limit 3
+gdb_test_no_output "set backtrace limit 3"
+#test show backtrace limit
+gdb_test "show backtrace limit" \
+"An upper bound on the number of backtrace levels is 3\."
+#test set backtrace past-entry on
+gdb_test_no_output "set backtrace past-entry on"
+#test show backtrace past-entry
+gdb_test "show backtrace past-entry" \
+"Whether backtraces should continue past the entry point of a program is on\."
+#test set backtrace past-main on
+gdb_test_no_output "set backtrace past-main on"
+#test show backtrace past-main
+gdb_test "show backtrace past-main" \
+"Whether backtraces should continue past \"main\" is on\."
+send_gdb "set backtrace limit 0\n"
+send_gdb "set backtrace past-entry off\n"
+send_gdb "set backtrace past-main off\n"
+#test show copying
+gdb_test "show copying" ".*GNU GENERAL PUBLIC LICENSE.*"
 if ![board_info target exists gdb_prompt] {
     #test set prompt (FooBarBaz) 
     set newprompt "\\(FooBarBaz\\)"
-- 
1.8.3.1


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