aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.travis.yml7
-rw-r--r--Library/Homebrew/cask/Gemfile2
-rw-r--r--Library/Homebrew/cask/Gemfile.lock17
-rw-r--r--Library/Homebrew/cask/README.md3
-rw-r--r--Library/Homebrew/cask/Rakefile9
-rw-r--r--Library/Homebrew/dev-cmd/test-bot.rb57
-rw-r--r--Library/Homebrew/test/Gemfile2
-rw-r--r--Library/Homebrew/test/Gemfile.lock17
8 files changed, 58 insertions, 56 deletions
diff --git a/.travis.yml b/.travis.yml
index 4a3da039e..ecfad5326 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -2,13 +2,6 @@ language: ruby
rvm: 2.0.0
os: linux
-matrix:
- include:
- - os: osx
- env: OSX=10.11
- osx_image: xcode7.3
- rvm: system
-
before_install:
- export HOMEBREW_DEVELOPER=1
- export PATH="bin:$PATH"
diff --git a/Library/Homebrew/cask/Gemfile b/Library/Homebrew/cask/Gemfile
index c164a3f67..af1c8d3bc 100644
--- a/Library/Homebrew/cask/Gemfile
+++ b/Library/Homebrew/cask/Gemfile
@@ -12,7 +12,7 @@ group :development do
end
group :test do
- gem "coveralls", require: false
+ gem "codecov", require: false
gem "minitest", "5.4.1"
gem "minitest-reporters"
gem "mocha", "1.1.0", require: false
diff --git a/Library/Homebrew/cask/Gemfile.lock b/Library/Homebrew/cask/Gemfile.lock
index b65784444..c9c2b5cca 100644
--- a/Library/Homebrew/cask/Gemfile.lock
+++ b/Library/Homebrew/cask/Gemfile.lock
@@ -5,13 +5,11 @@ GEM
ast (2.3.0)
builder (3.2.2)
byebug (9.0.5)
+ codecov (0.1.5)
+ json
+ simplecov
+ url
coderay (1.1.1)
- coveralls (0.8.15)
- json (>= 1.8, < 3)
- simplecov (~> 0.12.0)
- term-ansicolor (~> 1.3)
- thor (~> 0.19.1)
- tins (>= 1.6.0, < 2)
diff-lcs (1.2.5)
docile (1.1.5)
json (2.0.2)
@@ -71,17 +69,14 @@ GEM
simplecov-html (~> 0.10.0)
simplecov-html (0.10.0)
slop (3.6.0)
- term-ansicolor (1.3.2)
- tins (~> 1.0)
- thor (0.19.1)
- tins (1.12.0)
unicode-display_width (1.1.0)
+ url (0.3.2)
PLATFORMS
ruby
DEPENDENCIES
- coveralls
+ codecov
minitest (= 5.4.1)
minitest-reporters
mocha (= 1.1.0)
diff --git a/Library/Homebrew/cask/README.md b/Library/Homebrew/cask/README.md
index 35fe201a5..1d0dc5882 100644
--- a/Library/Homebrew/cask/README.md
+++ b/Library/Homebrew/cask/README.md
@@ -8,9 +8,6 @@ We do this by providing a friendly Homebrew-style CLI workflow for the administr
It’s implemented as a `homebrew` [external command](https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/External-Commands.md) called `cask`.
-[![Build Status](https://img.shields.io/travis/caskroom/homebrew-cask/master.svg)](https://travis-ci.org/caskroom/homebrew-cask)
-[![Code Climate](https://img.shields.io/codeclimate/github/caskroom/homebrew-cask.svg)](https://codeclimate.com/github/caskroom/homebrew-cask)
-[![Coverage Status](https://img.shields.io/coveralls/caskroom/homebrew-cask.svg)](https://coveralls.io/r/caskroom/homebrew-cask)
[![Join the chat at https://gitter.im/caskroom/homebrew-cask](https://img.shields.io/badge/gitter-join%20chat-blue.svg)](https://gitter.im/caskroom/homebrew-cask)
## Let’s try it!
diff --git a/Library/Homebrew/cask/Rakefile b/Library/Homebrew/cask/Rakefile
index 7a276b347..25deee407 100644
--- a/Library/Homebrew/cask/Rakefile
+++ b/Library/Homebrew/cask/Rakefile
@@ -23,10 +23,11 @@ namespace :test do
Rake::Task[:test].invoke
- if ENV["TRAVIS"]
- require "coveralls/rake/task"
- Coveralls::RakeTask.new
- Rake::Task['coveralls:push'].invoke
+ if ENV["CODECOV_TOKEN"]
+ require "simplecov"
+ require "codecov"
+ formatter = SimpleCov::Formatter::Codecov.new
+ formatter.format(SimpleCov::ResultMerger.merged_result)
end
end
end
diff --git a/Library/Homebrew/dev-cmd/test-bot.rb b/Library/Homebrew/dev-cmd/test-bot.rb
index ed803d7fc..1a2095068 100644
--- a/Library/Homebrew/dev-cmd/test-bot.rb
+++ b/Library/Homebrew/dev-cmd/test-bot.rb
@@ -59,8 +59,7 @@
#:
#: If `--no-pull` is passed, don't use `brew pull` when possible.
#:
-#: If `--coverage` is passed, generate coverage report and send it to
-#: Coveralls.
+#: If `--coverage` is passed, generate and uplaod a coverage report.
#:
#: If `--test-default-formula` is passed, use a default testing formula
#: when not building a tap and no other formulae are specified.
@@ -72,6 +71,9 @@
#:
#: If `--ci-testing` is passed, use the Homebrew testing CI options.
#:
+#: If `--ci-auto` is passed, automatically pick one of the Homebrew CI
+#: options based on the environment.
+#:
#: If `--ci-upload` is passed, use the Homebrew CI bottle upload
#: options.
#:
@@ -709,18 +711,24 @@ module Homebrew
return if @skip_homebrew
if !@tap && (@formulae.empty? || @test_default_formula)
- tests_args = ["--official-cmd-taps"]
- tests_args_no_compat = []
- tests_args_no_compat << "--coverage" if ARGV.include?("--coverage")
- test "brew", "tests", *tests_args
- test "brew", "tests", "--generic", *tests_args
- test "brew", "tests", "--no-compat", *tests_args_no_compat
+ coverage_args = []
+ if ARGV.include?("--coverage")
+ if ENV["JENKINS_HOME"]
+ if OS.mac? && MacOS.version == :el_capitan
+ coverage_args << "--coverage"
+ end
+ else
+ coverage_args << "--coverage"
+ end
+ end
+
+ test "brew", "tests", "--no-compat"
+ test "brew", "tests", "--generic"
+ test "brew", "tests", "--official-cmd-taps", *coverage_args
test "brew", "readall", "--syntax"
if OS.mac?
run_as_not_developer { test "brew", "tap", "caskroom/cask" }
- tests_args_cask = []
- tests_args_cask << "--coverage" if ARGV.include?("--coverage")
- test "brew", "cask-tests", *tests_args_cask
+ test "brew", "cask-tests", *coverage_args
end
# TODO: try to fix this on Linux at some stage.
@@ -1003,16 +1011,29 @@ module Homebrew
ENV["HOMEBREW_FAIL_LOG_LINES"] = "150"
ENV["HOMEBREW_EXPERIMENTAL_FILTER_FLAGS_ON_DEPS"] = "1"
- if ENV["TRAVIS"]
+ travis = !ENV["TRAVIS"].nil?
+ if travis
ARGV << "--verbose"
- ARGV << "--ci-master" if ENV["TRAVIS_PULL_REQUEST"] == "false"
ENV["HOMEBREW_VERBOSE_USING_DOTS"] = "1"
+ end
+
+ # Only report coverage if build runs on macOS and this is indeed Homebrew,
+ # as we don't want this to be averaged with inferior Linux test coverage.
+ if OS.mac? && (ENV["COVERALLS_REPO_TOKEN"] || ENV["CODECOV_TOKEN"])
+ ARGV << "--coverage"
+ end
- # Only report coverage if build runs on macOS and this is indeed Homebrew,
- # as we don't want this to be averaged with inferior Linux test coverage.
- repo = ENV["TRAVIS_REPO_SLUG"]
- if repo && repo.start_with?("Homebrew/") && ENV["OSX"]
- ARGV << "--coverage"
+ travis_pr = ENV["TRAVIS_PULL_REQUEST"] && ENV["TRAVIS_PULL_REQUEST"] != "false"
+ jenkins_pr = !ENV["ghprbPullLink"].nil?
+ jenkins_branch = !ENV["GIT_COMMIT"].nil?
+
+ if ARGV.include?("--ci-auto")
+ if travis_pr || jenkins_pr
+ ARGV << "--ci-pr"
+ elsif travis || jenkins_branch
+ ARGV << "--ci-master"
+ else
+ ARGV << "--ci-testing"
end
end
diff --git a/Library/Homebrew/test/Gemfile b/Library/Homebrew/test/Gemfile
index df6429f50..c7c146233 100644
--- a/Library/Homebrew/test/Gemfile
+++ b/Library/Homebrew/test/Gemfile
@@ -13,5 +13,5 @@ group :coverage do
:git => "https://github.com/colszowka/simplecov.git",
:branch => "master", # commit 257e26394c464c4ab388631b4eff1aa98c37d3f1
:require => false
- gem "coveralls", "0.8.14", :require => false
+ gem "codecov", require: false
end
diff --git a/Library/Homebrew/test/Gemfile.lock b/Library/Homebrew/test/Gemfile.lock
index 2e78f050b..ceb11128d 100644
--- a/Library/Homebrew/test/Gemfile.lock
+++ b/Library/Homebrew/test/Gemfile.lock
@@ -11,12 +11,10 @@ GIT
GEM
remote: https://rubygems.org/
specs:
- coveralls (0.8.14)
- json (>= 1.8, < 3)
- simplecov (~> 0.12.0)
- term-ansicolor (~> 1.3)
- thor (~> 0.19.1)
- tins (~> 1.6.0)
+ codecov (0.1.5)
+ json
+ simplecov
+ url
docile (1.1.5)
json (1.8.3)
metaclass (0.0.4)
@@ -25,16 +23,13 @@ GEM
metaclass (~> 0.0.1)
rake (10.5.0)
simplecov-html (0.10.0)
- term-ansicolor (1.3.2)
- tins (~> 1.0)
- thor (0.19.1)
- tins (1.6.0)
+ url (0.3.2)
PLATFORMS
ruby
DEPENDENCIES
- coveralls (= 0.8.14)
+ codecov
minitest (~> 5.3)
mocha (~> 1.1)
rake (~> 10.3)