From 6cbb8d684f66378d11df9c4cf446484c7ac67968 Mon Sep 17 00:00:00 2001 From: Johnny Chen Date: Thu, 21 Jul 2011 23:02:00 +0000 Subject: Add test scenario of SBValue APIs for the 'days_of_week' global variable. llvm-svn: 135716 --- lldb/test/python_api/value/TestValueAPI.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lldb/test/python_api/value/TestValueAPI.py') diff --git a/lldb/test/python_api/value/TestValueAPI.py b/lldb/test/python_api/value/TestValueAPI.py index ee0fdcbed47..1453af67854 100644 --- a/lldb/test/python_api/value/TestValueAPI.py +++ b/lldb/test/python_api/value/TestValueAPI.py @@ -59,6 +59,13 @@ class ValueAPITestCase(TestBase): self.assertTrue(thread != None, "There should be a thread stopped due to breakpoint condition") frame0 = thread.GetFrameAtIndex(0) + # Get global variable 'days_of_week'. + list = target.FindGlobalVariables('days_of_week', 1) + days_of_week = list.GetValueAtIndex(0) + self.assertTrue(days_of_week, VALID_VARIABLE) + self.assertTrue(days_of_week.GetNumChildren() == 7, VALID_VARIABLE) + self.DebugSBValue(days_of_week) + # Get variable 'str_ptr'. value = frame0.FindVariable('str_ptr') self.assertTrue(value, VALID_VARIABLE) -- cgit v1.2.3