This repository has been archived by the owner on Jan 25, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into router_v2
Conflicts: router/Gemfile.lock router/Rakefile router/spec/Rakefile router/spec/functional/router_spec.rb router/spec/functional/spec_helper.rb Change-Id: I5c91bf1bab78855b05350948dfdfd4e13557432e
- Loading branch information
Showing
2 changed files
with
12 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,67 +1,19 @@ | ||
require 'rake' | ||
require 'ci/reporter/rake/rspec' | ||
require 'rspec/core/rake_task' | ||
|
||
desc "Run specs" | ||
task "spec" => ["bundler:install:test", "test:spec"] | ||
|
||
desc "Run specs in CI mode" | ||
# FIXME - Router specs currently fail on some platforms if they | ||
# share a bundle directory with the rest of the core. | ||
# Some kind of tricky interaction around the --without flag? | ||
task "ci" do | ||
sh("BUNDLE_PATH=$HOME/.vcap_router_gems bundle install --without production") | ||
Dir.chdir("spec") do | ||
sh("BUNDLE_PATH=$HOME/.vcap_router_gems bundle exec rake spec") | ||
end | ||
namespace :ci do | ||
desc "Run specs producing results for CI" | ||
task "spec" => ["ci:setup:rspec", "^spec"] | ||
end | ||
|
||
desc "Run specs producing results for CI" | ||
task "ci-report" => ["ci:spec"] | ||
|
||
desc "Run specs using RCov" | ||
task "spec:rcov" => ["bundler:install:test", "test:spec:rcov"] | ||
|
||
desc "Synonym for spec" | ||
task :test => :spec | ||
desc "Synonym for spec" | ||
task :tests => :spec | ||
|
||
namespace "bundler" do | ||
desc "Install gems" | ||
task "install" do | ||
sh("bundle install") | ||
end | ||
|
||
desc "Install gems for test" | ||
task "install:test" do | ||
sh("bundle install --without development production") | ||
end | ||
reports_dir = File.expand_path(File.join(File.dirname(__FILE__), "spec_reports")) | ||
|
||
desc "Install gems for production" | ||
task "install:production" do | ||
sh("bundle install --without development test") | ||
end | ||
|
||
desc "Install gems for development" | ||
task "install:development" do | ||
sh("bundle install --without test production") | ||
end | ||
task "test" do |t| | ||
sh("cd spec && rake test") | ||
end | ||
|
||
namespace "test" do | ||
task "spec" do |t| | ||
sh("cd spec && rake spec") | ||
end | ||
|
||
task "test" do |t| | ||
sh("cd spec && rake test") | ||
end | ||
|
||
task "spec:rcov" do |t| | ||
sh("cd spec && rake spec:rcov") | ||
end | ||
task "spec" do |t| | ||
sh("cd spec && rake spec") | ||
end | ||
|
||
namespace :ci do | ||
task "spec" => ["ci:setup:rspec", "^spec"] | ||
end | ||
ENV['CI_REPORTS'] = reports_dir |