Adds cocoapods for libraries.

Adds OCMockito and OCHamcrest libs.
This commit is contained in:
2020-09-05 22:06:51 -07:00
parent f688898d96
commit bab5a55c3b
364 changed files with 17147 additions and 1 deletions

View File

@@ -0,0 +1,47 @@
// OCHamcrest by Jon Reid, https://qualitycoding.org/
// Copyright 2019 hamcrest.org. See LICENSE.txt
// Contribution by Justin Shacklette
#import <OCHamcrest/HCDiagnosingMatcher.h>
NS_ASSUME_NONNULL_BEGIN
/*!
* @abstract Matches objects whose "property" (or simple method) satisfies a nested matcher.
*/
@interface HCHasProperty : HCDiagnosingMatcher
- (instancetype)initWithProperty:(NSString *)propertyName value:(id <HCMatcher>)valueMatcher NS_DESIGNATED_INITIALIZER;
- (instancetype)init NS_UNAVAILABLE;
@end
FOUNDATION_EXPORT id HC_hasProperty(NSString *propertyName, _Nullable id valueMatcher);
#ifndef HC_DISABLE_SHORT_SYNTAX
/*!
* @abstract Creates a matcher that matches when the examined object has an instance method with the
* specified name whose return value satisfies the specified matcher.
* @param propertyName The name of an instance method without arguments that returns an object.
* @param valueMatcher The matcher to satisfy for the return value, or an expected value for
* <em>equalTo</em> matching.
* @discussion Note: While this matcher factory is called "hasProperty", it applies to the return
* values of any instance methods without arguments, not just properties.
*
* <b>Examples</b><br />
* <pre>assertThat(person, hasProperty(\@"firstName", equalTo(\@"Joe")))</pre>
* <pre>assertThat(person, hasProperty(\@"firstName", \@"Joe"))</pre>
*
* <b>Name Clash</b><br />
* In the event of a name clash, <code>#define HC_DISABLE_SHORT_SYNTAX</code> and use the synonym
* HC_hasProperty instead.
*/
static inline id hasProperty(NSString *propertyName, _Nullable id valueMatcher)
{
return HC_hasProperty(propertyName, valueMatcher);
}
#endif
NS_ASSUME_NONNULL_END