From 220940bc8a6bc458cf2157415a482669d7c122b5 Mon Sep 17 00:00:00 2001 From: Jun Aruga Date: Mon, 27 Mar 2017 20:36:15 +0200 Subject: [PATCH] Improve test environment * Add Rakefile, Gemfile, .travis.yml. * Add a list of offcially supported Ruby to .travis.yml. * Add ruby-head to Travis as allow_failures. allow_failures is because it's good to know new version Ruby's issue as faster before the release. * fast_finish is to get the Travis result as faster without waiting the result of the "allow_failures" items. See https://blog.travis-ci.com/2013-11-27-fast-finishing-builds/ --- .travis.yml | 19 +++++++++++++++++++ Gemfile | 7 +++++++ Rakefile | 10 ++++++++++ 3 files changed, 36 insertions(+) create mode 100644 .travis.yml create mode 100644 Gemfile create mode 100644 Rakefile diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..b53d6fa --- /dev/null +++ b/.travis.yml @@ -0,0 +1,19 @@ +language: ruby + +sudo: false + +before_install: + - gem install bundler + +rvm: + - 2.0.0 + - 2.1.10 + - 2.2.6 + - 2.3.3 + - 2.4.1 + - ruby-head + +matrix: + allow_failures: + - rvm: ruby-head + fast_finish: true diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000..751e588 --- /dev/null +++ b/Gemfile @@ -0,0 +1,7 @@ +source "https://rubygems.org" + +gemspec + +gem 'rake', '~> 12.0.0' +gem 'test-unit', '~> 3.2.3' +gem 'minitest', '~> 5.10.1' diff --git a/Rakefile b/Rakefile new file mode 100644 index 0000000..aa2d41e --- /dev/null +++ b/Rakefile @@ -0,0 +1,10 @@ +require 'rake/testtask' + +Rake::TestTask.new(:test) do |t| + t.libs << "test" + t.test_files = FileList["test/**/*_test.rb"] + t.warning = true + t.verbose = true +end + +task :default => :test