aboutsummaryrefslogtreecommitdiff
path: root/Foundation/GTMLoggerTest.m
diff options
context:
space:
mode:
authorGravatar thomasvl@gmail.com <thomasvl@gmail.com@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2008-09-10 21:04:47 +0000
committerGravatar thomasvl@gmail.com <thomasvl@gmail.com@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2008-09-10 21:04:47 +0000
commitbfaf8705cccb15c0c2a7704b17ba011ddba8242f (patch)
treeb48e104487ee5e29522da1bce6accafa007e29cf /Foundation/GTMLoggerTest.m
parent0f0f40db85a2c295a9b6dc1623cd76106a4448a5 (diff)
- Added GTMExceptionalInlines for dealing with cases where you get
warning: variable 'r' might be clobbered by 'longjmp' or 'vfork' when using certain Apple inlined functions in @synchronized/@try blocks. - Updated to Xcode 3.1 so the GTM and iPhone project have the same baseline. The code should work in other version of xcode, but the projects and xcconfig files now use 3.1 features. - Added GTMABAddressBook which is a cocoa wrapper for the 'C' AddressBook APIs on the iPhone. - Added several set environment variable statements to RunIPhoneUnitTest.sh to encourage bugs to come out of the woodwork.
Diffstat (limited to 'Foundation/GTMLoggerTest.m')
-rw-r--r--Foundation/GTMLoggerTest.m12
1 files changed, 10 insertions, 2 deletions
diff --git a/Foundation/GTMLoggerTest.m b/Foundation/GTMLoggerTest.m
index 9093c7a..043c73d 100644
--- a/Foundation/GTMLoggerTest.m
+++ b/Foundation/GTMLoggerTest.m
@@ -94,12 +94,20 @@
@"GTMLoggerUnitTest.log"] retain];
STAssertNotNil(path_, nil);
// Make sure we're cleaned up from the last run
+#if MAC_OS_X_VERSION_MIN_REQUIRED < 1050
[[NSFileManager defaultManager] removeFileAtPath:path_ handler:nil];
+#else
+ [[NSFileManager defaultManager] removeItemAtPath:path_ error:NULL];
+#endif
}
- (void)tearDown {
STAssertNotNil(path_, nil);
+#if MAC_OS_X_VERSION_MIN_REQUIRED < 1050
[[NSFileManager defaultManager] removeFileAtPath:path_ handler:nil];
+#else
+ [[NSFileManager defaultManager] removeItemAtPath:path_ error:NULL];
+#endif
[path_ release];
path_ = nil;
}
@@ -372,8 +380,8 @@
STAssertNotNil(fmtr, nil);
// E.g. 2008-01-04 09:16:26.906 otest[5567/0xa07d0f60] [lvl=1] (no func) test
- static NSString *const kFormatBasePattern =
- @"[0-9]{4}-[0-9]{2}-[0-9]{2} [0-9]{2}:[0-9]{2}:[0-9]{2}\\.[0-9]{3} otest\\[[0-9]+/0x[0-9a-f]+\\] \\[lvl=[0-3]\\] \\(no func\\) ";
+ NSString * kFormatBasePattern =
+ @"[0-9]{4}-[0-9]{2}-[0-9]{2} [0-9]{2}:[0-9]{2}:[0-9]{2}\\.[0-9]{3} ((otest)|(GTMiPhoneTest))\\[[0-9]+/0x[0-9a-f]+\\] \\[lvl=[0-3]\\] \\(no func\\) ";
NSString *msg = nil;
msg = [self stringFromFormatter:fmtr