add travis
This commit is contained in:
parent
fe94b0f646
commit
c7a8bb5f33
4 changed files with 29 additions and 2 deletions
18
.travis.yml
Normal file
18
.travis.yml
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
language: ruby
|
||||
|
||||
rvm:
|
||||
- 2.2
|
||||
- 2.1
|
||||
|
||||
sudo: false
|
||||
cache:
|
||||
bundler: true
|
||||
|
||||
branches:
|
||||
only:
|
||||
- 'master'
|
||||
|
||||
before_install: gem install bundler
|
||||
bundler_args: "--deployment --without development --jobs=3 --retry=3"
|
||||
|
||||
script: "./script/ci/travis.sh"
|
||||
3
Rakefile
3
Rakefile
|
|
@ -21,7 +21,6 @@ load "rails/tasks/statistics.rake"
|
|||
|
||||
Bundler::GemHelper.install_tasks
|
||||
|
||||
require "rspec/core/rake_task"
|
||||
RSpec::Core::RakeTask.new(:spec)
|
||||
Rails.application.load_tasks
|
||||
|
||||
task default: :spec
|
||||
|
|
|
|||
6
lib/tasks/tests.rake
Normal file
6
lib/tasks/tests.rake
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
namespace :ci do
|
||||
namespace :travis do
|
||||
desc "Run specs"
|
||||
task run: %w(spec)
|
||||
end
|
||||
end
|
||||
4
script/ci/travis.sh
Executable file
4
script/ci/travis.sh
Executable file
|
|
@ -0,0 +1,4 @@
|
|||
#!/bin/sh
|
||||
|
||||
command="bundle exec rake --trace ci:travis:run"
|
||||
exec $command
|
||||
Loading…
Reference in a new issue