Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(451)

Side by Side Diff: third_party/ocmock/OCMock/OCMockObject.h

Issue 2626723004: Update OCMock to 3e193f3c2d4ea4ada63df54c8ce98e7ea4cf768f (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/ocmock/OCMock/OCMock-Prefix.pch ('k') | third_party/ocmock/OCMock/OCMockObject.m » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //------------------------------------------------------------------------------ --------- 1 /*
2 // $Id$ 2 * Copyright (c) 2004-2015 Erik Doernenburg and contributors
3 // Copyright (c) 2004-2008 by Mulle Kybernetik. See License file for details. 3 *
4 //------------------------------------------------------------------------------ --------- 4 * Licensed under the Apache License, Version 2.0 (the "License"); you may
5 * not use these files except in compliance with the License. You may obtain
6 * a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13 * License for the specific language governing permissions and limitations
14 * under the License.
15 */
5 16
6 #import <Foundation/Foundation.h> 17 #import <Foundation/Foundation.h>
7 18
19 @class OCMLocation;
20 @class OCMInvocationStub;
21 @class OCMStubRecorder;
22 @class OCMInvocationMatcher;
23 @class OCMInvocationExpectation;
24
25
8 @interface OCMockObject : NSProxy 26 @interface OCMockObject : NSProxy
9 { 27 {
10 BOOL isNice; 28 BOOL isNice;
11 BOOL expectationOrderMatters; 29 BOOL expectationOrderMatters;
12 » NSMutableArray» *recorders; 30 » NSMutableArray» *stubs;
13 NSMutableArray *expectations; 31 NSMutableArray *expectations;
14 NSMutableArray *rejections;
15 NSMutableArray *exceptions; 32 NSMutableArray *exceptions;
33 NSMutableArray *invocations;
16 } 34 }
17 35
18 + (id)mockForClass:(Class)aClass; 36 + (id)mockForClass:(Class)aClass;
19 + (id)mockForProtocol:(Protocol *)aProtocol; 37 + (id)mockForProtocol:(Protocol *)aProtocol;
20 + (id)partialMockForObject:(NSObject *)anObject; 38 + (id)partialMockForObject:(NSObject *)anObject;
21 39
22 + (id)niceMockForClass:(Class)aClass; 40 + (id)niceMockForClass:(Class)aClass;
23 + (id)niceMockForProtocol:(Protocol *)aProtocol; 41 + (id)niceMockForProtocol:(Protocol *)aProtocol;
24 42
25 + (id)observerMock; 43 + (id)observerMock;
26 44
27 - (id)init; 45 - (instancetype)init;
28 46
29 - (void)setExpectationOrderMatters:(BOOL)flag; 47 - (void)setExpectationOrderMatters:(BOOL)flag;
30 48
31 - (id)stub; 49 - (id)stub;
32 - (id)expect; 50 - (id)expect;
33 - (id)reject; 51 - (id)reject;
34 52
35 - (void)verify; 53 - (id)verify;
54 - (id)verifyAtLocation:(OCMLocation *)location;
55
56 - (void)verifyWithDelay:(NSTimeInterval)delay;
57 - (void)verifyWithDelay:(NSTimeInterval)delay atLocation:(OCMLocation *)location ;
58
59 - (void)stopMocking;
36 60
37 // internal use only 61 // internal use only
38 62
39 - (id)getNewRecorder; 63 - (void)addStub:(OCMInvocationStub *)aStub;
64 - (void)addExpectation:(OCMInvocationExpectation *)anExpectation;
65
40 - (BOOL)handleInvocation:(NSInvocation *)anInvocation; 66 - (BOOL)handleInvocation:(NSInvocation *)anInvocation;
41 - (void)handleUnRecordedInvocation:(NSInvocation *)anInvocation; 67 - (void)handleUnRecordedInvocation:(NSInvocation *)anInvocation;
68 - (BOOL)handleSelector:(SEL)sel;
69
70 - (void)verifyInvocation:(OCMInvocationMatcher *)matcher;
71 - (void)verifyInvocation:(OCMInvocationMatcher *)matcher atLocation:(OCMLocation *)location;
42 72
43 @end 73 @end
74
OLDNEW
« no previous file with comments | « third_party/ocmock/OCMock/OCMock-Prefix.pch ('k') | third_party/ocmock/OCMock/OCMockObject.m » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698