-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor project and add support for SPM #250
Changes from all commits
cf28a56
ab26efe
be03128
29164ea
5e3aa96
df16c8e
07a75ef
1da2833
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,17 +23,21 @@ jobs: | |
xcode: << parameters.xcode >> | ||
steps: | ||
- checkout | ||
- run: make build | ||
- store_artifacts: | ||
path: build/mapbox-events-ios-static.zip | ||
- run: | ||
name: Test SPM | ||
command: | | ||
# xcodebuild will try to use the Package manifest if it cannot find a project | ||
mkdir temp && mv MapboxMobileEvents.xcodeproj temp | ||
xcodebuild -scheme MapboxMobileEvents test -destination "platform=iOS Simulator,name=iPhone 11,OS=latest" | ||
mv temp/MapboxMobileEvents.xcodeproj . && rm -rf temp | ||
- run: | ||
name: Install dependencies | ||
command: | | ||
if [ "<< parameters.xcode >>" = "12.0.0" ]; then export XCODE_XCCONFIG_FILE=~/project/xcode-12-fix.xcconfig; fi | ||
carthage bootstrap --platform ios --cache-builds --configuration Debug --no-use-binaries --verbose | ||
- run: | ||
name: Test | ||
command: xcodebuild -project MapboxMobileEventsTests.xcodeproj -scheme MMETestHost build test -destination 'platform=iOS Simulator,name=iPhone 11,OS=latest' GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES | ||
command: xcodebuild -project MapboxMobileEvents.xcodeproj -scheme MMETestHost build test -destination 'platform=iOS Simulator,name=iPhone 11,OS=latest' GCC_INSTRUMENT_PROGRAM_FLOW_ARCS=YES GCC_GENERATE_TEST_COVERAGE_FILES=YES | ||
- run: | ||
name: Test CocoaPods | ||
command: Tests/Integration/test_cocoapods.sh | ||
|
@@ -42,3 +46,10 @@ jobs: | |
command: | | ||
if [ "<< parameters.xcode >>" = "12.0.0" ]; then export XCODE_XCCONFIG_FILE=~/project/xcode-12-fix.xcconfig; fi | ||
Tests/Integration/test_carthage.sh | ||
- when: | ||
condition: | ||
equal: [ "11.7.0", << parameters.xcode >> ] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is there any problem with XCode 12 code coverage? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not that I know of but since Xcode 12 is still in beta and we run the same tests as with Xcode 11, I figured merging multiple reports would be excessive at this point. |
||
steps: | ||
- run: | ||
name: Codecov | ||
command: bash <(curl https://codecov.io/bash) -Z -t $CODECOV_TOKEN |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -69,3 +69,5 @@ fastlane/test_output | |
test_output/ | ||
docs/ | ||
.DS_Store | ||
|
||
.swiftpm |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
#import "MMETestDelegate.h" | ||
#import <UIKit/UIKit.h> | ||
|
||
// MARK: - | ||
|
||
|
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,7 @@ Pod::Spec.new do |s| | |
|
||
# ――― Platform Specifics ――――――――――――――――――――――――――――――――――――――――――――――――――――――― # | ||
|
||
s.ios.deployment_target = "8.0" | ||
s.ios.deployment_target = "9.0" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I wonder if we should have bump of minimum deployment target in the separate PR/commit? |
||
|
||
|
||
# ――― Source Location ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # | ||
|
@@ -30,9 +30,9 @@ Pod::Spec.new do |s| | |
|
||
# ――― Source Code ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # | ||
|
||
s.source_files = ["MapboxMobileEvents/**/*.{h,m}"] | ||
s.resources = "MapboxMobileEvents/Resources/*" | ||
s.exclude_files = "MapboxMobileEvents/MMENamespacedDependencies.h" | ||
s.source_files = ["Sources/MapboxMobileEvents/**/*.{h,m}"] | ||
s.resources = "Sources/MapboxMobileEvents/Resources/*" | ||
s.exclude_files = "Sources/MapboxMobileEvents/MMENamespacedDependencies.h" | ||
|
||
# ――― Project Settings ――――――――――――――――――――――――――――――――――――――――――――――――――――――――― # | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it make sense to specify the platform value through the build parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, as a follow-up because then it should also propagate to CocoaPods and Carthage tests.