Skip to content

Commit

Permalink
Update Travis CI build matrix
Browse files Browse the repository at this point in the history
- Drop iOS 7.0.3 runtime
- Use Xcode 6.4 for testing the iOS 7.1 runtime
- Use Xcode 7 for testing the iOS 8.4 and 9.0 runtimes
- Run the UI specs with the Debug configuration so symbolication works properly
  • Loading branch information
tjarratt authored and Tim Jarratt committed Feb 2, 2016
1 parent 3d0d8e3 commit 8ce8aca
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 19 deletions.
28 changes: 16 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,27 @@
language: objective-c
osx_image: xcode7

env:
matrix:
- CEDAR_SDK_VERSION="8.1" CEDAR_SDK_RUNTIME_VERSION="7.0.3" TASK="rake ci"
- CEDAR_SDK_VERSION="8.1" CEDAR_SDK_RUNTIME_VERSION="7.1" TASK="rake ci"
- CEDAR_SDK_VERSION="8.1" CEDAR_SDK_RUNTIME_VERSION="8.1" TASK="rake ci"
matrix:
include:
- osx_image: xcode6.4
env: CEDAR_SDK_VERSION="8.4" CEDAR_SDK_RUNTIME_VERSION="7.1" TASK="rake ci"
- env: CEDAR_SDK_VERSION="9.0" CEDAR_SDK_RUNTIME_VERSION="8.4" TASK="rake ci"
- env: CEDAR_SDK_VERSION="9.0" CEDAR_SDK_RUNTIME_VERSION="9.0" TASK="rake ci"

# Analyze takes too long -- vary on runtime SDK
- CEDAR_SDK_VERSION="8.1" CEDAR_SDK_RUNTIME_VERSION="8.1" TASK="rake suites:specs:analyze"
- CEDAR_SDK_VERSION="8.1" CEDAR_SDK_RUNTIME_VERSION="8.1" TASK="rake suites:uispecs:analyze"
- CEDAR_SDK_VERSION="8.1" CEDAR_SDK_RUNTIME_VERSION="8.1" TASK="rake suites:focused_specs:analyze"
# Analyze takes too long -- vary on runtime SDK
- env: CEDAR_SDK_VERSION="9.0" TASK="rake suites:specs:analyze"
- env: CEDAR_SDK_VERSION="9.0" TASK="rake suites:uispecs:analyze"
- env: CEDAR_SDK_VERSION="9.0" TASK="rake suites:focused_specs:analyze"

- TASK="./install.sh"
- TASK="./installCodeSnippetsAndTemplates"
- env: TASK="./install.sh"
- env: TASK="./installCodeSnippetsAndTemplates"

before_install: brew update
before_install: brew update; brew update
install:
- bundle install
- brew install ios-sim
- ios-sim showsdks
- ios-sim showdevicetypes

script:
# run a printer task to keep travis from terminating static analysis
Expand Down
7 changes: 4 additions & 3 deletions scripts/rake/helpers/xcode.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ def self.developer_dir
`xcode-select -print-path`.strip
end

def self.build_dir(effective_platform_name = "")
File.join(BUILD_DIR, CONFIGURATION + effective_platform_name)
def self.build_dir(effective_platform_name = "", configuration = CONFIGURATION)
File.join(BUILD_DIR, configuration + effective_platform_name)
end

def self.sdk_dir_for_version(version)
Expand Down Expand Up @@ -41,9 +41,10 @@ def self.build(options = nil)
args += " -target #{options[:target].inspect}" if options[:target]
args += " -sdk #{options[:sdk].inspect}" if options[:sdk]
args += " -scheme #{options[:scheme].inspect}" if options[:scheme]
args += " -configuration #{options[:configuration] || CONFIGURATION}"

Shell.fold "build.#{options[:scheme] || options[:target]}" do
Shell.run(%Q(xcodebuild -project #{PROJECT_NAME}.xcodeproj -configuration #{CONFIGURATION} SYMROOT=#{BUILD_DIR.inspect} clean build #{args}), logfile)
Shell.run(%Q(xcodebuild -project #{PROJECT_NAME}.xcodeproj SYMROOT=#{BUILD_DIR.inspect} clean build #{args}), logfile)
end
end

Expand Down
12 changes: 8 additions & 4 deletions scripts/rake/tasks/spec_suites.rb
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

desc "Build UI specs"
task :build do
Xcode.build(target: UI_SPECS_TARGET_NAME, sdk: "iphonesimulator#{SDK_VERSION}", args: 'ARCHS=i386', logfile: "uispecs.build.log")
Xcode.build(target: UI_SPECS_TARGET_NAME, sdk: "iphonesimulator#{SDK_VERSION}", args: 'ARCHS=i386', configuration: "Debug", logfile: "uispecs.build.log")
end

desc "Run UI specs"
Expand All @@ -52,7 +52,7 @@
}

Shell.with_env(env_vars) do
Simulator.launch(Xcode.build_dir("-iphonesimulator"), UI_SPECS_TARGET_NAME, Xcode.build_dir("-uispecs.run.log"))
Simulator.launch(Xcode.build_dir("-iphonesimulator", "Debug"), UI_SPECS_TARGET_NAME, Xcode.build_dir("-uispecs.run.log"))
end
end
end
Expand Down Expand Up @@ -123,7 +123,11 @@

desc "Build iOS dynamic framework specs"
task :build do
Xcode.build(target: IOS_DYNAMIC_FRAMEWORK_SPECS_TARGET_NAME, sdk: "iphonesimulator#{SDK_VERSION}", args: 'ARCHS=i386 '+Xcode.swift_build_settings, logfile: "frameworks.ios.dynamic.specs.build.log")
Xcode.build(target: IOS_DYNAMIC_FRAMEWORK_SPECS_TARGET_NAME,
sdk: "iphonesimulator#{SDK_VERSION}",
args: 'ARCHS=i386 '+Xcode.swift_build_settings,
configuration: "Debug",
logfile: "frameworks.ios.dynamic.specs.build.log")
end

desc "Runs iOS dynamic framework specs"
Expand All @@ -134,7 +138,7 @@
}

Shell.with_env(env_vars) do
Simulator.launch(Xcode.build_dir("-iphonesimulator"), IOS_DYNAMIC_FRAMEWORK_SPECS_TARGET_NAME, Xcode.build_dir("-frameworks.ios.dynamic.specs.run.log"))
Simulator.launch(Xcode.build_dir("-iphonesimulator", "Debug"), IOS_DYNAMIC_FRAMEWORK_SPECS_TARGET_NAME, Xcode.build_dir("-frameworks.ios.dynamic.specs.run.log"))
end
end
end
Expand Down

0 comments on commit 8ce8aca

Please sign in to comment.