diff options
Diffstat (limited to 'lldb/test/functionalities')
3 files changed, 24 insertions, 3 deletions
diff --git a/lldb/test/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py b/lldb/test/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py index ac370f70a18..fea3e669abd 100644 --- a/lldb/test/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py +++ b/lldb/test/functionalities/data-formatter/data-formatter-categories/TestDataFormatterCategories.py @@ -286,7 +286,7 @@ class DataFormatterTestCase(TestBase): substrs = ['ACircle', 'ARectangle', 'ACircle', - 'ARectangleStar']) + 'ARectangle']) # Check that abruptly deleting an enabled category does not crash us self.runCmd("type category delete RectangleCategory") diff --git a/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py b/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py index e17b6fc195b..31a64a439e8 100644 --- a/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py +++ b/lldb/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py @@ -164,7 +164,7 @@ class DataFormatterTestCase(TestBase): 'inline = ', 'explicit = ', 'content = ', - 'a very much boring task to write a string this way!!\\xe4\\x8c\\xb3']) + 'a very much boring task to write a string this way!!\\xcf\\x83']) self.expect('frame variable str10 -P 1 -Y', substrs = ['mutable =', @@ -215,7 +215,7 @@ class DataFormatterTestCase(TestBase): self.expect('frame variable str8', substrs = ['hasVeryLongExtensionThisTime']) self.expect('frame variable str9', - substrs = ['a very much boring task to write a string this way!!\\xe4\\x8c\\xb3']) + substrs = ['a very much boring task to write a string this way!!\\xcf\\x83']) self.expect('frame variable str10', substrs = ['This is a Unicode string \\xcf\\x83 number 4 right here']) self.expect('frame variable str11', @@ -224,6 +224,25 @@ class DataFormatterTestCase(TestBase): substrs = ['a.out']) self.expect('frame variable str12', substrs = ['Process Name: a.out Process Id:']) + self.expect('frame variable dyn_test', matching=False, + substrs = ['Process Name: a.out Process Id:']) + self.expect('frame variable dyn_test -d run-target', + substrs = ['(id, dynamic type:', + 'Process Name: a.out Process Id:']) + + + # check that we can format stuff out of the expression parser + self.expect('expression ((id)@"Hello")', matching=False, + substrs = ['Hello']) + + self.expect('expression -d true -- ((id)@"Hello")', + substrs = ['Hello']) + + self.expect('expr -d true -- label1', + substrs = ['Process Name']) + + self.expect('expr -d true -- @"Hello"', + substrs = ['Hello']) if __name__ == '__main__': import atexit diff --git a/lldb/test/functionalities/data-formatter/data-formatter-objc/main.m b/lldb/test/functionalities/data-formatter/data-formatter-objc/main.m index 132d70b5382..326e49d5b3d 100644 --- a/lldb/test/functionalities/data-formatter/data-formatter-objc/main.m +++ b/lldb/test/functionalities/data-formatter/data-formatter-objc/main.m @@ -117,6 +117,8 @@ int main (int argc, const char * argv[]) NSString *processID = [NSString stringWithFormat:@"%d", [[NSProcessInfo processInfo] processIdentifier]]; NSString *str12 = [NSString stringWithFormat:@"%@ %@ %@ %@", label1, processName, label2, processID]; + id dyn_test = str12; + // Set break point at this line. [pool drain]; return 0; |