From patchwork Mon Oct 26 04:16:31 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fei Jie X-Patchwork-Id: 9375 Received: (qmail 76250 invoked by alias); 26 Oct 2015 04:17:01 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 76241 invoked by uid 89); 26 Oct 2015 04:17:01 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=2.2 required=5.0 tests=AWL, BAYES_40, KAM_LAZY_DOMAIN_SECURITY, RP_MATCHES_RCVD autolearn=no version=3.3.2 X-HELO: heian.cn.fujitsu.com Received: from cn.fujitsu.com (HELO heian.cn.fujitsu.com) (59.151.112.132) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 26 Oct 2015 04:17:00 +0000 Received: from bogon (HELO edo.cn.fujitsu.com) ([10.167.33.5]) by heian.cn.fujitsu.com with ESMTP; 26 Oct 2015 12:19:11 +0800 Received: from G08CNEXCHPEKD02.g08.fujitsu.local (localhost.localdomain [127.0.0.1]) by edo.cn.fujitsu.com (8.14.3/8.13.1) with ESMTP id t9Q4GM9c013032 for ; Mon, 26 Oct 2015 12:16:22 +0800 Received: from localhost.localdomain (10.167.226.91) by G08CNEXCHPEKD02.g08.fujitsu.local (10.167.33.89) with Microsoft SMTP Server (TLS) id 14.3.181.6; Mon, 26 Oct 2015 12:16:54 +0800 From: Fei Jie To: Subject: [PATCH] Add testcases for set&show backtrace and copying Date: Mon, 26 Oct 2015 12:16:31 +0800 Message-ID: <1445832991-27779-1-git-send-email-feij.fnst@cn.fujitsu.com> MIME-Version: 1.0 X-IsSubscribed: yes 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\\)"