summaryrefslogtreecommitdiffstats
path: root/third_party/ocmock
diff options
context:
space:
mode:
authorkushi.p@gmail.com <kushi.p@gmail.com@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-07 19:36:18 +0000
committerkushi.p@gmail.com <kushi.p@gmail.com@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-07 19:36:18 +0000
commit5d8e991fa3a6838a7fb79d52c081bded0b1de891 (patch)
treeb24e9e4e63b5057745cfae60c6390bb4eec0a26f /third_party/ocmock
parentb7e45c0bf261e570692d25203db304650ad95333 (diff)
downloadchromium_src-5d8e991fa3a6838a7fb79d52c081bded0b1de891.zip
chromium_src-5d8e991fa3a6838a7fb79d52c081bded0b1de891.tar.gz
chromium_src-5d8e991fa3a6838a7fb79d52c081bded0b1de891.tar.bz2
Roll OCMOCK forward to 8b8793cf29a5bac0541421ea06c7dff071afb25e
BUG=113894 TEST=unit_tests Review URL: http://codereview.chromium.org/9616059 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125428 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'third_party/ocmock')
-rw-r--r--third_party/ocmock/License.txt2
-rw-r--r--third_party/ocmock/OCMock/NSInvocation+OCMAdditions.m6
-rw-r--r--third_party/ocmock/OCMock/OCMArg.m3
-rw-r--r--third_party/ocmock/OCMock/OCProtocolMockObject.m7
-rw-r--r--third_party/ocmock/README.chromium2
5 files changed, 9 insertions, 11 deletions
diff --git a/third_party/ocmock/License.txt b/third_party/ocmock/License.txt
index 2caf9d0..512ad8e 100644
--- a/third_party/ocmock/License.txt
+++ b/third_party/ocmock/License.txt
@@ -1,5 +1,5 @@
- Copyright (c) 2004-2011 by Mulle Kybernetik. All rights reserved.
+ Copyright (c) 2004-2012 by Mulle Kybernetik. All rights reserved.
Permission to use, copy, modify and distribute this software and its documentation
is hereby granted, provided that both the copyright notice and this permission
diff --git a/third_party/ocmock/OCMock/NSInvocation+OCMAdditions.m b/third_party/ocmock/OCMock/NSInvocation+OCMAdditions.m
index 2595523..4157958 100644
--- a/third_party/ocmock/OCMock/NSInvocation+OCMAdditions.m
+++ b/third_party/ocmock/OCMock/NSInvocation+OCMAdditions.m
@@ -257,7 +257,7 @@
long longValue;
[self getArgument:&longValue atIndex:anInt];
- return [NSString stringWithFormat:@"%d", longValue];
+ return [NSString stringWithFormat:@"%ld", longValue];
}
- (NSString *)unsignedLongDescriptionAtIndex:(int)anInt
@@ -265,7 +265,7 @@
unsigned long longValue;
[self getArgument:&longValue atIndex:anInt];
- return [NSString stringWithFormat:@"%u", longValue];
+ return [NSString stringWithFormat:@"%lu", longValue];
}
- (NSString *)longLongDescriptionAtIndex:(int)anInt
@@ -323,7 +323,7 @@
memset(buffer, 0x0, 128);
[self getArgument:&buffer atIndex:anInt];
- return [NSString stringWithFormat:@"\"%S\"", buffer];
+ return [NSString stringWithFormat:@"\"%s\"", buffer];
}
- (NSString *)selectorDescriptionAtIndex:(int)anInt
diff --git a/third_party/ocmock/OCMock/OCMArg.m b/third_party/ocmock/OCMock/OCMArg.m
index 6cf198f..a73e3df 100644
--- a/third_party/ocmock/OCMock/OCMArg.m
+++ b/third_party/ocmock/OCMock/OCMArg.m
@@ -3,6 +3,7 @@
// Copyright (c) 2009-2010 by Mulle Kybernetik. See License file for details.
//---------------------------------------------------------------------------------------
+#import <objc/runtime.h>
#import <OCMock/OCMArg.h>
#import <OCMock/OCMConstraint.h>
#import "OCMPassByRefSetter.h"
@@ -64,7 +65,7 @@
void *pointer = [value pointerValue];
if(pointer == (void *)0x01234567)
return [OCMArg any];
- if((pointer != NULL) && (((id)pointer)->isa == [OCMPassByRefSetter class]))
+ if((pointer != NULL) && (object_getClass((id)pointer) == [OCMPassByRefSetter class]))
return (id)pointer;
}
return value;
diff --git a/third_party/ocmock/OCMock/OCProtocolMockObject.m b/third_party/ocmock/OCMock/OCProtocolMockObject.m
index fa4130b..19e25e8 100644
--- a/third_party/ocmock/OCMock/OCProtocolMockObject.m
+++ b/third_party/ocmock/OCMock/OCProtocolMockObject.m
@@ -7,7 +7,6 @@
#import "NSMethodSignature+OCMAdditions.h"
#import "OCProtocolMockObject.h"
-
@implementation OCProtocolMockObject
#pragma mark Initialisers, description, accessors, etc.
@@ -21,11 +20,10 @@
- (NSString *)description
{
- return [NSString stringWithFormat:@"OCMockObject[%s]", [mockedProtocol name]];
+ const char* name = protocol_getName(mockedProtocol);
+ return [NSString stringWithFormat:@"OCMockObject[%s]", name];
}
-
-
#pragma mark Proxy API
- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector
@@ -52,5 +50,4 @@
return ([self methodSignatureForSelector:selector] != nil);
}
-
@end
diff --git a/third_party/ocmock/README.chromium b/third_party/ocmock/README.chromium
index f586f4f..6d3f1b3 100644
--- a/third_party/ocmock/README.chromium
+++ b/third_party/ocmock/README.chromium
@@ -1,7 +1,7 @@
Name: ocmock
URL: https://github.com/erikdoe/ocmock
Version: unknown
-Revision: dbdb233ae84498077f7e946abb49731968333f0b
+Revision: 8b8793cf29a5bac0541421ea06c7dff071afb25e
License: BSD with advertising clause
License File: License.txt
Security Critical: no