-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #69 in MOBILE-SDK/app_mobile-sdk-ios from 20161123…
…,1307--dreeder--RELEASE--for_ANSDK_v2.13.2 to master * commit 'bbcb072a24bb99ec93ba9f9fa34ee5bea1b6a2d0': Release notes and updated ANGlobal.h for v2.13.2. Upgrade KIF to v3.5.1 (from v2.0). v2.0 was too old to support iOS 10 in which Apple has changed the implementation of the accessibility inspector -- kif-framework/KIF#876 .
- Loading branch information
Showing
434 changed files
with
23,281 additions
and
159 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
KIF--v3.5.1 |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
language: objective-c | ||
matrix: | ||
include: | ||
- osx_image: xcode6.4 | ||
env: 'SIMULATOR="name=iPad Air,OS=8.1"' | ||
- osx_image: xcode7.3 | ||
env: 'SIMULATOR="name=iPhone 6s,OS=9.3"' | ||
- osx_image: xcode6.4 | ||
env: 'SIMULATOR="name=iPhone 4s,OS=8.4"' | ||
|
||
before_install: | ||
- xcrun simctl list | ||
- brew update || brew update | ||
install: | ||
- if [ -z "$(brew ls --versions coreutils)" ] ; then brew install coreutils ; fi | ||
- gem install xcpretty --no-rdoc --no-ri --no-document --quiet | ||
script: | ||
- ./scripts/ci.sh "${SIMULATOR}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// CAAnimation+KIFAdditions.h | ||
// Pods | ||
// | ||
// Created by Justin Martin on 6/6/16. | ||
// | ||
|
||
#import <QuartzCore/QuartzCore.h> | ||
|
||
|
||
@interface CAAnimation (KIFAdditions) | ||
|
||
- (double)KIF_completionTime; | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// | ||
// CAAnimation+KIFAdditions.m | ||
// Pods | ||
// | ||
// Created by Justin Martin on 6/6/16. | ||
// | ||
|
||
#import "CAAnimation+KIFAdditions.h" | ||
|
||
|
||
@implementation CAAnimation (KIFAdditions) | ||
|
||
- (double)KIF_completionTime; | ||
{ | ||
if (self.repeatDuration > 0) { | ||
return self.beginTime + self.repeatDuration; | ||
} else if (self.repeatCount == HUGE_VALF) { | ||
return HUGE_VALF; | ||
} else if (self.repeatCount > 0) { | ||
return self.beginTime + (self.repeatCount * self.duration); | ||
} else { | ||
return self.beginTime + self.duration; | ||
} | ||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// | ||
// CALayer-KIFAdditions.h | ||
// Pods | ||
// | ||
// Created by Radu Ciobanu on 28/01/2016. | ||
// Licensed to Square, Inc. under one or more contributor license agreements. | ||
// See the LICENSE file distributed with this work for the terms under | ||
// which Square, Inc. licenses this file to you. | ||
// | ||
|
||
#import <QuartzCore/QuartzCore.h> | ||
|
||
@interface CALayer (KIFAdditions) | ||
|
||
/** | ||
* @method hasAnimations | ||
* @abstract Traverses self's hierarchy of layers and checks whether any | ||
* visible sublayers or self have ongoing anymations. | ||
* @return YES if an animated layer has been found, NO otherwise. | ||
*/ | ||
- (BOOL)hasAnimations; | ||
|
||
/*! | ||
@method performBlockOnDescendentLayers: | ||
@abstract Calls a block on the layer itself and on all its descendent layers. | ||
@param block The block that will be called on the layers. Stop the traversation | ||
of the layers by assigning YES to the stop-parameter of the block. | ||
*/ | ||
- (void)performBlockOnDescendentLayers:(void (^)(CALayer *layer, BOOL *stop))block; | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
// | ||
// CALayer-KIFAdditions.m | ||
// Pods | ||
// | ||
// Created by Radu Ciobanu on 28/01/2016. | ||
// Licensed to Square, Inc. under one or more contributor license agreements. | ||
// See the LICENSE file distributed with this work for the terms under | ||
// which Square, Inc. licenses this file to you. | ||
// | ||
|
||
#import "CALayer-KIFAdditions.h" | ||
#import "CAAnimation+KIFAdditions.h" | ||
|
||
|
||
@implementation CALayer (KIFAdditions) | ||
|
||
- (float)KIF_absoluteSpeed | ||
{ | ||
__block float speed = 1.0f; | ||
[self performBlockOnAncestorLayers:^(CALayer *layer) { | ||
speed = speed * layer.speed; | ||
}]; | ||
return speed; | ||
} | ||
|
||
- (BOOL)hasAnimations | ||
{ | ||
__block BOOL result = NO; | ||
[self performBlockOnDescendentLayers:^(CALayer *layer, BOOL *stop) { | ||
// explicitly exclude _UIParallaxMotionEffect as it is used in alertviews, and we don't want every alertview to be paused) | ||
BOOL hasAnimation = layer.animationKeys.count != 0 && ![layer.animationKeys isEqualToArray:@[@"_UIParallaxMotionEffect"]]; | ||
if (hasAnimation && !layer.hidden) { | ||
double currentTime = CACurrentMediaTime() * [layer KIF_absoluteSpeed]; | ||
|
||
[layer.animationKeys enumerateObjectsUsingBlock:^(NSString *animationKey, NSUInteger idx, BOOL *innerStop) { | ||
CAAnimation *animation = [layer animationForKey:animationKey]; | ||
double beginTime = [animation beginTime]; | ||
double completionTime = [animation KIF_completionTime]; | ||
|
||
// Ignore infinitely repeating animations | ||
if (currentTime >= beginTime && completionTime != HUGE_VALF && currentTime < completionTime) { | ||
result = YES; | ||
*innerStop = YES; | ||
*stop = YES; | ||
} | ||
}]; | ||
} | ||
}]; | ||
return result; | ||
} | ||
|
||
- (void)performBlockOnDescendentLayers:(void (^)(CALayer *layer, BOOL *stop))block | ||
{ | ||
BOOL stop = NO; | ||
[self performBlockOnDescendentLayers:block stop:&stop]; | ||
} | ||
|
||
- (void)performBlockOnDescendentLayers:(void (^)(CALayer *, BOOL *))block stop:(BOOL *)stop | ||
{ | ||
block(self, stop); | ||
if (*stop) { | ||
return; | ||
} | ||
|
||
for (CALayer *layer in self.sublayers) { | ||
[layer performBlockOnDescendentLayers:block stop:stop]; | ||
if (*stop) { | ||
return; | ||
} | ||
} | ||
} | ||
|
||
- (void)performBlockOnAncestorLayers:(void (^)(CALayer *))block; | ||
{ | ||
block(self); | ||
|
||
if (self.superlayer != nil) { | ||
[self.superlayer performBlockOnAncestorLayers:block]; | ||
} | ||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// | ||
// CGGeometry-KIFAdditions.h | ||
// KIF | ||
// | ||
// Created by Eric Firestone on 5/22/11. | ||
// Licensed to Square, Inc. under one or more contributor license agreements. | ||
// See the LICENSE file distributed with this work for the terms under | ||
// which Square, Inc. licenses this file to you. | ||
|
||
#import <CoreGraphics/CGGeometry.h> | ||
|
||
CG_INLINE CGPoint CGPointCenteredInRect(CGRect bounds) { | ||
return CGPointMake(bounds.origin.x + bounds.size.width * 0.5f, bounds.origin.y + bounds.size.height * 0.5f); | ||
} | ||
|
||
CG_INLINE CGPoint CGPointMidPoint(CGPoint point1, CGPoint point2) { | ||
return CGPointMake((point1.x + point2.x) / 2.0f, (point1.y + point2.y) / 2.0f); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
// | ||
// CGGeometry-KIFAdditions.m | ||
// KIF | ||
// | ||
// Created by Eric Firestone on 5/22/11. | ||
// Licensed to Square, Inc. under one or more contributor license agreements. | ||
// See the LICENSE file distributed with this work for the terms under | ||
// which Square, Inc. licenses this file to you. | ||
|
||
#import "CGGeometry-KIFAdditions.h" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// | ||
// LoadableCategory.h | ||
// KIF | ||
// | ||
// Created by Karl Stenerud on 7/16/11. | ||
// Licensed to Square, Inc. under one or more contributor license agreements. | ||
// See the LICENSE file distributed with this work for the terms under | ||
// which Square, Inc. licenses this file to you. | ||
|
||
/** Make all categories in the current file loadable without using -load-all. | ||
* | ||
* Normally, compilers will skip linking files that contain only categories. | ||
* Adding a call to this macro adds a dummy class, which causes the linker | ||
* to add the file. | ||
* | ||
* @param UNIQUE_NAME A globally unique name. | ||
*/ | ||
#define MAKE_CATEGORIES_LOADABLE(UNIQUE_NAME) @interface FORCELOAD_##UNIQUE_NAME : NSObject @end @implementation FORCELOAD_##UNIQUE_NAME @end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
// | ||
// NSBundle+KIFAdditions.h | ||
// KIF | ||
// | ||
// Created by Brian Nickel on 7/27/13. | ||
// | ||
// | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
@interface NSBundle (KIFAdditions) | ||
|
||
+ (NSBundle *)KIFTestBundle; | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
// | ||
// NSBundle+KIFAdditions.m | ||
// KIF | ||
// | ||
// Created by Brian Nickel on 7/27/13. | ||
// | ||
// | ||
|
||
#import "NSBundle-KIFAdditions.h" | ||
#import "KIFTestCase.h" | ||
#import "LoadableCategory.h" | ||
|
||
MAKE_CATEGORIES_LOADABLE(NSBundle_KIFAdditions) | ||
|
||
@implementation NSBundle (KIFAdditions) | ||
|
||
+ (NSBundle *)KIFTestBundle | ||
{ | ||
static NSBundle *bundle; | ||
static dispatch_once_t onceToken; | ||
dispatch_once(&onceToken, ^{ | ||
bundle = [self bundleForClass:[KIFTestCase class]]; | ||
}); | ||
return bundle; | ||
} | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
// | ||
// NSError+KIFAdditions.h | ||
// KIF | ||
// | ||
// Created by Brian Nickel on 7/27/13. | ||
// | ||
// | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
@interface NSError (KIFAdditions) | ||
|
||
+ (instancetype)KIFErrorWithUnderlyingError:(NSError *)underlyingError format:(NSString *)format, ... NS_FORMAT_FUNCTION(2,3); | ||
+ (instancetype)KIFErrorWithFormat:(NSString *)format, ... NS_FORMAT_FUNCTION(1,2); | ||
|
||
@end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
// | ||
// NSError+KIFAdditions.m | ||
// KIF | ||
// | ||
// Created by Brian Nickel on 7/27/13. | ||
// | ||
// | ||
|
||
#import "NSError-KIFAdditions.h" | ||
#import "LoadableCategory.h" | ||
#import "KIFTestActor.h" | ||
|
||
MAKE_CATEGORIES_LOADABLE(NSError_KIFAdditions) | ||
|
||
@implementation NSError (KIFAdditions) | ||
|
||
+ (instancetype)KIFErrorWithFormat:(NSString *)format, ... | ||
{ | ||
va_list args; | ||
va_start(args, format); | ||
NSString *description = [[NSString alloc] initWithFormat:format arguments:args]; | ||
va_end(args); | ||
|
||
return [self errorWithDomain:@"KIFTest" code:KIFTestStepResultFailure userInfo:@{NSLocalizedDescriptionKey: description}]; | ||
} | ||
|
||
+ (instancetype)KIFErrorWithUnderlyingError:(NSError *)underlyingError format:(NSString *)format, ... | ||
{ | ||
va_list args; | ||
va_start(args, format); | ||
NSString *description = [[NSString alloc] initWithFormat:format arguments:args]; | ||
va_end(args); | ||
|
||
NSDictionary *userInfo = [[NSDictionary alloc] initWithObjectsAndKeys:description, NSLocalizedDescriptionKey, underlyingError, NSUnderlyingErrorKey, nil]; | ||
|
||
return [self errorWithDomain:@"KIFTest" code:KIFTestStepResultFailure userInfo:userInfo]; | ||
} | ||
|
||
@end |
Oops, something went wrong.