diff --git a/.travis.yml b/.travis.yml index 2e3782d..26405ef 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,11 +1,8 @@ language: objective-c install: - - sudo easy_install cpp-coveralls - (cd Lib && bundle install --path=vendor/bundle --binstubs=vendor/bin) script: - - (cd Lib && bundle exec rake test:ios test:osx) -after_success: - - ./Lib/Script/coveralls.sh + - (cd Lib && bundle exec rake test:ios test:osx coverage:coveralls) branches: only: - master diff --git a/Lib/Gemfile.lock b/Lib/Gemfile.lock index 9cc155b..1dfbb1f 100644 --- a/Lib/Gemfile.lock +++ b/Lib/Gemfile.lock @@ -2,7 +2,7 @@ GEM remote: https://rubygems.org/ specs: rake (10.4.2) - xcjobs (0.0.5) + xcjobs (0.0.6) xcpretty (0.1.7) PLATFORMS diff --git a/Lib/Rakefile b/Lib/Rakefile index 110e0f4..8406cea 100644 --- a/Lib/Rakefile +++ b/Lib/Rakefile @@ -10,7 +10,7 @@ def destinations 'name=iPhone 5s,OS=7.1', 'name=iPhone 5s,OS=8.1', 'name=iPhone 6,OS=8.1', - 'name=iPhone 6 Plus,OS=8.1' + 'name=iPhone 6 Plus,OS=8.1', ] end @@ -54,9 +54,8 @@ XCJobs::Test.new('test:ios') do |t| destinations.each do |destination| t.add_destination(destination) end + t.coverage = true t.formatter = 'xcpretty -c' - t.add_build_setting('GCC_INSTRUMENT_PROGRAM_FLOW_ARCS', 'YES') - t.add_build_setting('GCC_GENERATE_TEST_COVERAGE_FILES', 'YES') end XCJobs::Test.new('test:osx') do |t| @@ -67,3 +66,8 @@ XCJobs::Test.new('test:osx') do |t| t.build_dir = 'build' t.formatter = 'xcpretty -c' end + +XCJobs::Coverage::Coveralls.new() do |t| + t.add_extension('.m') + t.add_exclude('Lib/UICKeyChainStoreTests') +end diff --git a/Lib/Script/create-coveralls-script.sh b/Lib/Script/create-coveralls-script.sh deleted file mode 100755 index 9bedb68..0000000 --- a/Lib/Script/create-coveralls-script.sh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/bash -e - -if [[ -z "${CI}" ]]; then - exit 0 -fi - -COVERALLS_SCRIPT_PATH="${SRCROOT}/Script/coveralls.sh" -cat > "${COVERALLS_SCRIPT_PATH}" <