-
Notifications
You must be signed in to change notification settings - Fork 227
/
PhotoDataTestCase.h
38 lines (27 loc) · 1023 Bytes
/
PhotoDataTestCase.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
//
// PhotoDataTestCase.h
// objc.io example project (issue #1)
//
#import <SenTestingKit/SenTestingKit.h>
#import <OCMock/OCMock.h>
// This little block can probably go away with the next version of developer tools:
#ifndef NS_REQUIRES_SUPER
# if __has_attribute(objc_requires_super)
# define NS_REQUIRES_SUPER __attribute((objc_requires_super))
# else
# define NS_REQUIRES_SUPER
# endif
#endif
/// Base class for tests
@interface PhotoDataTestCase : SenTestCase
- (void)setUp NS_REQUIRES_SUPER;
- (void)tearDown NS_REQUIRES_SUPER;
/// Returns the URL for a resource that's been added to the test target.
- (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)extension;
/// Calls +[OCMockObject mockForClass:] and adds the mock and call -verify on it during -tearDown
- (id)autoVerifiedMockForClass:(Class)aClass;
/// C.f. -autoVerifiedMockForClass:
- (id)autoVerifiedPartialMockForObject:(id)object;
/// Calls -verify on the mock during -tearDown
- (void)verifyDuringTearDown:(id)mock;
@end