Modified main.m and TestObjCMethods.py to unbreak the test/foundation directory.

llvm-svn: 121046
This commit is contained in:
Johnny Chen 2010-12-06 22:09:04 +00:00
parent ccdf435a96
commit 73b7b93d42
2 changed files with 13 additions and 0 deletions

View File

@ -68,6 +68,12 @@ class FoundationTestCase(TestBase):
self.runCmd("process continue")
# Second stop is still +[NSString stringWithFormat:].
self.expect("thread backtrace", "Stop at +[NSString stringWithFormat:]",
substrs = ["Foundation`+[NSString stringWithFormat:]"])
self.runCmd("process continue")
# Followed by a.out`-[MyString initWithNSString:].
self.expect("thread backtrace", "Stop at a.out`-[MyString initWithNSString:]",
substrs = ["a.out`-[MyString initWithNSString:]"])
@ -80,6 +86,12 @@ class FoundationTestCase(TestBase):
self.runCmd("process continue")
# Followed by the same -[MyString description].
self.expect("thread backtrace", "Stop at -[MyString description]",
substrs = ["a.out`-[MyString description]"])
self.runCmd("process continue")
# Followed by -[NSAutoreleasePool release].
self.expect("thread backtrace", "Stop at -[NSAutoreleasePool release]",
substrs = ["Foundation`-[NSAutoreleasePool release]"])

View File

@ -88,6 +88,7 @@ Test_MyString (const char *program)
NSString *str = [NSString stringWithFormat:@"Hello from '%s'", program];
MyString *my = [[MyString alloc] initWithNSString:str];
NSLog(@"MyString instance: %@", [my description]);
// Set break point at this line. Test 'expression -o -- my'.
my.descriptionPauses = YES;
NSLog(@"MyString instance: %@", [my description]);
}