Skip to content

Commit

Permalink
Fix Travis testing. Add some tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mats-claassen committed Sep 9, 2016
1 parent 812da61 commit 0997252
Show file tree
Hide file tree
Showing 12 changed files with 284 additions and 47 deletions.
6 changes: 3 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ before_install:
- brew update
- brew outdated carthage || brew upgrade carthage
- if brew outdated | grep -qx xctool; then brew upgrade xctool; fi
- carthage update --platform iOS
- pod install --project-directory=TokenRow/Example
- gem install xcpretty --no-rdoc --no-ri --no-document --quiet

script:
- xctool clean build -project TokenRow.xcodeproj -scheme TokenRow -sdk iphonesimulator
- xctool test -project TokenRow.xcodeproj -scheme TokenRow -sdk iphonesimulator
- xctool clean build -workspace TokenRow/Example/Example.xcworkspace -scheme Example -sdk iphonesimulator
- set -o pipefail && xcodebuild test -workspace TokenRow/Example/Example.xcworkspace -scheme Example -sdk iphonesimulator9.3 ONLY_ACTIVE_ARCH=NO | xcpretty
2 changes: 1 addition & 1 deletion TokenRow.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|
s.name = "TokenRow"
s.version = "1.0.0"
s.summary = "A row that allows the user to select options into a token view."
s.summary = "An Eureka row that allows the user to select options into a token view."
s.homepage = "https://github.com/EurekaCommunity/TokenRow"
s.license = { type: 'MIT', file: 'LICENSE' }
s.author = { "Xmartlabs SRL" => "[email protected]" }
Expand Down
169 changes: 168 additions & 1 deletion TokenRow/Example/Example.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
28F828D01C4B714D00330CF4 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28F828CF1C4B714D00330CF4 /* AppDelegate.swift */; };
28F828D21C4B714D00330CF4 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28F828D11C4B714D00330CF4 /* ViewController.swift */; };
28F828D71C4B714D00330CF4 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 28F828D61C4B714D00330CF4 /* Assets.xcassets */; };
8E655004036B88C52E2FDC8E /* Pods_TokenRowTests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 0F00C0D45BC6CBD8472EA660 /* Pods_TokenRowTests.framework */; };
8F7B2E3D1D82E2C500D5AD90 /* TokenRowTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 8F7B2E3C1D82E2C500D5AD90 /* TokenRowTests.swift */; };
8FDA507B1D7F191800AF6514 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 8FDA50771D7F191800AF6514 /* Main.storyboard */; };
8FDA507C1D7F191800AF6514 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 8FDA50791D7F191800AF6514 /* LaunchScreen.storyboard */; };
8FDA50831D7F39F800AF6514 /* ExampleUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 28F828E61C4B714D00330CF4 /* ExampleUITests.swift */; };
Expand All @@ -26,6 +28,13 @@
remoteGlobalIDString = 28F828CB1C4B714D00330CF4;
remoteInfo = Example;
};
8F7B2E3F1D82E2C500D5AD90 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 28F828C41C4B714D00330CF4 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 28F828CB1C4B714D00330CF4;
remoteInfo = Example;
};
/* End PBXContainerItemProxy section */

/* Begin PBXCopyFilesBuildPhase section */
Expand All @@ -42,6 +51,7 @@
/* End PBXCopyFilesBuildPhase section */

/* Begin PBXFileReference section */
0F00C0D45BC6CBD8472EA660 /* Pods_TokenRowTests.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_TokenRowTests.framework; sourceTree = BUILT_PRODUCTS_DIR; };
287D0A711C4B7877004566D6 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = ExampleUITests/Info.plist; sourceTree = SOURCE_ROOT; };
28F828CC1C4B714D00330CF4 /* Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Example.app; sourceTree = BUILT_PRODUCTS_DIR; };
28F828CF1C4B714D00330CF4 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
Expand All @@ -51,12 +61,17 @@
28F828E01C4B714D00330CF4 /* ExampleUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = ExampleUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
28F828E61C4B714D00330CF4 /* ExampleUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ExampleUITests.swift; sourceTree = "<group>"; };
8BED93B457ED01E4D96853FE /* Pods_Example.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_Example.framework; sourceTree = BUILT_PRODUCTS_DIR; };
8F7B2E3A1D82E2C500D5AD90 /* TokenRowTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = TokenRowTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
8F7B2E3C1D82E2C500D5AD90 /* TokenRowTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = TokenRowTests.swift; sourceTree = "<group>"; };
8F7B2E3E1D82E2C500D5AD90 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
8FDA50781D7F191800AF6514 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
8FDA507A1D7F191800AF6514 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; };
8FDACD871D81D6A7004FEA1D /* User.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = User.swift; sourceTree = "<group>"; };
8FDACD891D81D9C8004FEA1D /* Alamofire.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Alamofire.swift; sourceTree = "<group>"; };
95E39C43A4E429314B1C3D63 /* Pods-Example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example.release.xcconfig"; path = "Pods/Target Support Files/Pods-Example/Pods-Example.release.xcconfig"; sourceTree = "<group>"; };
A58DE564DA68C5AC77D89095 /* Pods-TokenRowTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-TokenRowTests.release.xcconfig"; path = "Pods/Target Support Files/Pods-TokenRowTests/Pods-TokenRowTests.release.xcconfig"; sourceTree = "<group>"; };
B19E3C5587C8B604A9173418 /* Pods-Example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Example.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Example/Pods-Example.debug.xcconfig"; sourceTree = "<group>"; };
F3317486620E38E7A4823BCF /* Pods-TokenRowTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-TokenRowTests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-TokenRowTests/Pods-TokenRowTests.debug.xcconfig"; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand All @@ -75,6 +90,14 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
8F7B2E371D82E2C500D5AD90 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
8E655004036B88C52E2FDC8E /* Pods_TokenRowTests.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
Expand All @@ -83,6 +106,8 @@
children = (
B19E3C5587C8B604A9173418 /* Pods-Example.debug.xcconfig */,
95E39C43A4E429314B1C3D63 /* Pods-Example.release.xcconfig */,
F3317486620E38E7A4823BCF /* Pods-TokenRowTests.debug.xcconfig */,
A58DE564DA68C5AC77D89095 /* Pods-TokenRowTests.release.xcconfig */,
);
name = Pods;
sourceTree = "<group>";
Expand All @@ -92,6 +117,7 @@
children = (
28F828CE1C4B714D00330CF4 /* Example */,
28F828E31C4B714D00330CF4 /* ExampleUITests */,
8F7B2E3B1D82E2C500D5AD90 /* TokenRowTests */,
28F828CD1C4B714D00330CF4 /* Products */,
2639BAE4A4AEE426D71C1F02 /* Pods */,
C7AE64D42B2B235DA7A9CD60 /* Frameworks */,
Expand All @@ -103,6 +129,7 @@
children = (
28F828CC1C4B714D00330CF4 /* Example.app */,
28F828E01C4B714D00330CF4 /* ExampleUITests.xctest */,
8F7B2E3A1D82E2C500D5AD90 /* TokenRowTests.xctest */,
);
name = Products;
sourceTree = "<group>";
Expand Down Expand Up @@ -131,10 +158,20 @@
path = ExampleUITests;
sourceTree = "<group>";
};
8F7B2E3B1D82E2C500D5AD90 /* TokenRowTests */ = {
isa = PBXGroup;
children = (
8F7B2E3C1D82E2C500D5AD90 /* TokenRowTests.swift */,
8F7B2E3E1D82E2C500D5AD90 /* Info.plist */,
);
path = TokenRowTests;
sourceTree = "<group>";
};
C7AE64D42B2B235DA7A9CD60 /* Frameworks */ = {
isa = PBXGroup;
children = (
8BED93B457ED01E4D96853FE /* Pods_Example.framework */,
0F00C0D45BC6CBD8472EA660 /* Pods_TokenRowTests.framework */,
);
name = Frameworks;
sourceTree = "<group>";
Expand Down Expand Up @@ -181,13 +218,34 @@
productReference = 28F828E01C4B714D00330CF4 /* ExampleUITests.xctest */;
productType = "com.apple.product-type.bundle.ui-testing";
};
8F7B2E391D82E2C500D5AD90 /* TokenRowTests */ = {
isa = PBXNativeTarget;
buildConfigurationList = 8F7B2E411D82E2C500D5AD90 /* Build configuration list for PBXNativeTarget "TokenRowTests" */;
buildPhases = (
9D01DBBB5723FF157F4C53EB /* 📦 Check Pods Manifest.lock */,
8F7B2E361D82E2C500D5AD90 /* Sources */,
8F7B2E371D82E2C500D5AD90 /* Frameworks */,
8F7B2E381D82E2C500D5AD90 /* Resources */,
6BB818B4241595B40EB6DAF7 /* 📦 Embed Pods Frameworks */,
79A974E4A67C8A878196FB57 /* 📦 Copy Pods Resources */,
);
buildRules = (
);
dependencies = (
8F7B2E401D82E2C500D5AD90 /* PBXTargetDependency */,
);
name = TokenRowTests;
productName = TokenRowTests;
productReference = 8F7B2E3A1D82E2C500D5AD90 /* TokenRowTests.xctest */;
productType = "com.apple.product-type.bundle.unit-test";
};
/* End PBXNativeTarget section */

/* Begin PBXProject section */
28F828C41C4B714D00330CF4 /* Project object */ = {
isa = PBXProject;
attributes = {
LastSwiftUpdateCheck = 0720;
LastSwiftUpdateCheck = 0730;
LastUpgradeCheck = 0720;
TargetAttributes = {
28F828CB1C4B714D00330CF4 = {
Expand All @@ -197,6 +255,10 @@
CreatedOnToolsVersion = 7.2;
TestTargetID = 28F828CB1C4B714D00330CF4;
};
8F7B2E391D82E2C500D5AD90 = {
CreatedOnToolsVersion = 7.3.1;
TestTargetID = 28F828CB1C4B714D00330CF4;
};
};
};
buildConfigurationList = 28F828C71C4B714D00330CF4 /* Build configuration list for PBXProject "Example" */;
Expand All @@ -214,6 +276,7 @@
targets = (
28F828CB1C4B714D00330CF4 /* Example */,
28F828DF1C4B714D00330CF4 /* ExampleUITests */,
8F7B2E391D82E2C500D5AD90 /* TokenRowTests */,
);
};
/* End PBXProject section */
Expand All @@ -236,9 +299,31 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
8F7B2E381D82E2C500D5AD90 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */

/* Begin PBXShellScriptBuildPhase section */
6BB818B4241595B40EB6DAF7 /* 📦 Embed Pods Frameworks */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "📦 Embed Pods Frameworks";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-TokenRowTests/Pods-TokenRowTests-frameworks.sh\"\n";
showEnvVarsInLog = 0;
};
6FEE7A2956C9764B58D94F5D /* 📦 Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
Expand All @@ -254,6 +339,36 @@
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
showEnvVarsInLog = 0;
};
79A974E4A67C8A878196FB57 /* 📦 Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "📦 Copy Pods Resources";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-TokenRowTests/Pods-TokenRowTests-resources.sh\"\n";
showEnvVarsInLog = 0;
};
9D01DBBB5723FF157F4C53EB /* 📦 Check Pods Manifest.lock */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "📦 Check Pods Manifest.lock";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "diff \"${PODS_ROOT}/../Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [[ $? != 0 ]] ; then\n cat << EOM\nerror: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\nEOM\n exit 1\nfi\n";
showEnvVarsInLog = 0;
};
E8354FD93BFCEE73C23850C7 /* 📦 Embed Pods Frameworks */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
Expand Down Expand Up @@ -306,6 +421,14 @@
);
runOnlyForDeploymentPostprocessing = 0;
};
8F7B2E361D82E2C500D5AD90 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
8F7B2E3D1D82E2C500D5AD90 /* TokenRowTests.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */

/* Begin PBXTargetDependency section */
Expand All @@ -314,6 +437,11 @@
target = 28F828CB1C4B714D00330CF4 /* Example */;
targetProxy = 28F828E11C4B714D00330CF4 /* PBXContainerItemProxy */;
};
8F7B2E401D82E2C500D5AD90 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 28F828CB1C4B714D00330CF4 /* Example */;
targetProxy = 8F7B2E3F1D82E2C500D5AD90 /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */

/* Begin PBXVariantGroup section */
Expand Down Expand Up @@ -470,6 +598,36 @@
};
name = Release;
};
8F7B2E421D82E2C500D5AD90 /* Debug */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = F3317486620E38E7A4823BCF /* Pods-TokenRowTests.debug.xcconfig */;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
CLANG_ANALYZER_NONNULL = YES;
INFOPLIST_FILE = TokenRowTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.3;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.TokenRowTests;
PRODUCT_NAME = "$(TARGET_NAME)";
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example.app/Example";
};
name = Debug;
};
8F7B2E431D82E2C500D5AD90 /* Release */ = {
isa = XCBuildConfiguration;
baseConfigurationReference = A58DE564DA68C5AC77D89095 /* Pods-TokenRowTests.release.xcconfig */;
buildSettings = {
BUNDLE_LOADER = "$(TEST_HOST)";
CLANG_ANALYZER_NONNULL = YES;
INFOPLIST_FILE = TokenRowTests/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 9.3;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.xmartlabs.TokenRowTests;
PRODUCT_NAME = "$(TARGET_NAME)";
TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Example.app/Example";
};
name = Release;
};
/* End XCBuildConfiguration section */

/* Begin XCConfigurationList section */
Expand Down Expand Up @@ -500,6 +658,15 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
8F7B2E411D82E2C500D5AD90 /* Build configuration list for PBXNativeTarget "TokenRowTests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
8F7B2E421D82E2C500D5AD90 /* Debug */,
8F7B2E431D82E2C500D5AD90 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 28F828C41C4B714D00330CF4 /* Project object */;
Expand Down
11 changes: 9 additions & 2 deletions TokenRow/Example/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,17 @@ source 'https://github.com/CocoaPods/Specs.git'

use_frameworks!

target 'Example' do
def pods
pod 'Alamofire', '~> 3.5'
pod 'AlamofireImage'
pod 'CLTokenInputView'
pod 'CLTokenInputView', '~> 2.0'
pod 'TokenRow', :path => '../../'
end

target 'Example' do
pods
end

target 'TokenRowTests' do
pods
end
6 changes: 3 additions & 3 deletions TokenRow/Example/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ PODS:
DEPENDENCIES:
- Alamofire (~> 3.5)
- AlamofireImage
- CLTokenInputView
- CLTokenInputView (~> 2.0)
- TokenRow (from `../../`)

EXTERNAL SOURCES:
Expand All @@ -23,8 +23,8 @@ SPEC CHECKSUMS:
AlamofireImage: 2d34936e5201270bb17a316a786e90e83b4a249d
CLTokenInputView: 9dc1ffb7c9d2d81787e69a63c75bd97b0b2d1e76
Eureka: 2020d9faeef7b7e9adeb9e3d8af779e5931c1897
TokenRow: c509a85ee6472209d9ad4756f45d01a3f7e2b22b
TokenRow: f856265d3812d70738ab8c924d00cae47556c7e6

PODFILE CHECKSUM: 46da28a7d43e28afa3c5ffeac213dc79b5a1b7d7
PODFILE CHECKSUM: 37c70237638a6796cca4d618cbb80b955770dd6a

COCOAPODS: 1.0.0
File renamed without changes.
Loading

0 comments on commit 0997252

Please sign in to comment.