Relax Rails dependency to allow 5.1

This commit is contained in:
Grzesiek Kolodziejczyk 2017-05-18 11:39:18 +02:00
parent 25d8adaf8b
commit 8aeb9a6c70
8 changed files with 127 additions and 100 deletions

View File

@ -5,6 +5,7 @@ env:
- "RAILS_VERSION=3.2.22" - "RAILS_VERSION=3.2.22"
- "RAILS_VERSION=4.2.0" - "RAILS_VERSION=4.2.0"
- "RAILS_VERSION=5.0.0" - "RAILS_VERSION=5.0.0"
- "RAILS_VERSION=5.1.1"
cache: bundler cache: bundler
install: bundle update install: bundle update
before_script: before_script:

View File

@ -2,7 +2,7 @@ source "https://rubygems.org"
# Allow the rails version to come from an ENV setting so Travis can test multiple versions. # Allow the rails version to come from an ENV setting so Travis can test multiple versions.
# See http://www.schneems.com/post/50991826838/testing-against-multiple-rails-versions/ # See http://www.schneems.com/post/50991826838/testing-against-multiple-rails-versions/
rails_version = ENV['RAILS_VERSION'] || '3.2.22' rails_version = ENV['RAILS_VERSION'] || '5.1.1'
gem 'rails', "#{rails_version}" gem 'rails', "#{rails_version}"

View File

@ -1,57 +1,67 @@
PATH PATH
remote: ./rswag-api remote: rswag-api
specs: specs:
rswag-api (1.2.0) rswag-api (1.2.0)
rails (>= 3.1, < 5.1) rails (>= 3.1, < 5.2)
PATH PATH
remote: ./rswag-specs remote: rswag-specs
specs: specs:
rswag-specs (1.2.0) rswag-specs (1.2.0)
json (~> 1.8) json (~> 1.8)
json-schema (~> 2.2) json-schema (~> 2.2)
rails (>= 3.1, < 5.1) rails (>= 3.1, < 5.2)
rspec-rails (>= 2.14, < 4) rspec-rails (>= 2.14, < 4)
PATH PATH
remote: ./rswag-ui remote: rswag-ui
specs: specs:
rswag-ui (1.2.0) rswag-ui (1.2.0)
rails (>= 3.1, < 5.1) rails (>= 3.1, < 5.2)
GEM GEM
remote: https://rubygems.org/ remote: https://rubygems.org/
specs: specs:
actionmailer (3.2.22) actioncable (5.1.1)
actionpack (= 3.2.22) actionpack (= 5.1.1)
mail (~> 2.5.4) nio4r (~> 2.0)
actionpack (3.2.22) websocket-driver (~> 0.6.1)
activemodel (= 3.2.22) actionmailer (5.1.1)
activesupport (= 3.2.22) actionpack (= 5.1.1)
builder (~> 3.0.0) actionview (= 5.1.1)
erubis (~> 2.7.0) activejob (= 5.1.1)
journey (~> 1.0.4) mail (~> 2.5, >= 2.5.4)
rack (~> 1.4.5) rails-dom-testing (~> 2.0)
rack-cache (~> 1.2) actionpack (5.1.1)
rack-test (~> 0.6.1) actionview (= 5.1.1)
sprockets (~> 2.2.1) activesupport (= 5.1.1)
activemodel (3.2.22) rack (~> 2.0)
activesupport (= 3.2.22) rack-test (~> 0.6.3)
builder (~> 3.0.0) rails-dom-testing (~> 2.0)
activerecord (3.2.22) rails-html-sanitizer (~> 1.0, >= 1.0.2)
activemodel (= 3.2.22) actionview (5.1.1)
activesupport (= 3.2.22) activesupport (= 5.1.1)
arel (~> 3.0.2) builder (~> 3.1)
tzinfo (~> 0.3.29) erubi (~> 1.4)
activeresource (3.2.22) rails-dom-testing (~> 2.0)
activemodel (= 3.2.22) rails-html-sanitizer (~> 1.0, >= 1.0.3)
activesupport (= 3.2.22) activejob (5.1.1)
activesupport (3.2.22) activesupport (= 5.1.1)
i18n (~> 0.6, >= 0.6.4) globalid (>= 0.3.6)
multi_json (~> 1.0) activemodel (5.1.1)
activesupport (= 5.1.1)
activerecord (5.1.1)
activemodel (= 5.1.1)
activesupport (= 5.1.1)
arel (~> 8.0)
activesupport (5.1.1)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (~> 0.7)
minitest (~> 5.1)
tzinfo (~> 1.1)
addressable (2.4.0) addressable (2.4.0)
arel (3.0.3) arel (8.0.0)
builder (3.0.4) builder (3.2.3)
capybara (2.10.1) capybara (2.10.1)
addressable addressable
mime-types (>= 1.16) mime-types (>= 1.16)
@ -62,55 +72,65 @@ GEM
capybara-webkit (1.1.0) capybara-webkit (1.1.0)
capybara (~> 2.0, >= 2.0.2) capybara (~> 2.0, >= 2.0.2)
json json
concurrent-ruby (1.0.5)
diff-lcs (1.2.5) diff-lcs (1.2.5)
erubis (2.7.0) erubi (1.6.0)
execjs (2.7.0) execjs (2.7.0)
generator_spec (0.9.3) generator_spec (0.9.3)
activesupport (>= 3.0.0) activesupport (>= 3.0.0)
railties (>= 3.0.0) railties (>= 3.0.0)
hike (1.2.3) globalid (0.4.0)
i18n (0.7.0) activesupport (>= 4.2.0)
journey (1.0.4) i18n (0.8.1)
json (1.8.3) json (1.8.6)
json-schema (2.7.0) json-schema (2.8.0)
addressable (>= 2.4) addressable (>= 2.4)
libv8 (3.16.14.15) libv8 (3.16.14.15)
mail (2.5.4) loofah (2.0.3)
mime-types (~> 1.16) nokogiri (>= 1.5.9)
treetop (~> 1.4.8) mail (2.6.5)
mime-types (1.25.1) mime-types (>= 1.16, < 4)
method_source (0.8.2)
mime-types (3.1)
mime-types-data (~> 3.2015)
mime-types-data (3.2016.0521)
mini_portile2 (2.1.0) mini_portile2 (2.1.0)
multi_json (1.12.1) minitest (5.10.2)
nio4r (2.0.0)
nokogiri (1.6.8.1) nokogiri (1.6.8.1)
mini_portile2 (~> 2.1.0) mini_portile2 (~> 2.1.0)
polyglot (0.3.5)
power_assert (0.3.1) power_assert (0.3.1)
rack (1.4.7) rack (2.0.3)
rack-cache (1.6.1)
rack (>= 0.4)
rack-ssl (1.3.4)
rack
rack-test (0.6.3) rack-test (0.6.3)
rack (>= 1.0) rack (>= 1.0)
rails (3.2.22) rails (5.1.1)
actionmailer (= 3.2.22) actioncable (= 5.1.1)
actionpack (= 3.2.22) actionmailer (= 5.1.1)
activerecord (= 3.2.22) actionpack (= 5.1.1)
activeresource (= 3.2.22) actionview (= 5.1.1)
activesupport (= 3.2.22) activejob (= 5.1.1)
bundler (~> 1.0) activemodel (= 5.1.1)
railties (= 3.2.22) activerecord (= 5.1.1)
railties (3.2.22) activesupport (= 5.1.1)
actionpack (= 3.2.22) bundler (>= 1.3.0, < 2.0)
activesupport (= 3.2.22) railties (= 5.1.1)
rack-ssl (~> 1.3.2) sprockets-rails (>= 2.0.0)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.0.3)
loofah (~> 2.0)
railties (5.1.1)
actionpack (= 5.1.1)
activesupport (= 5.1.1)
method_source
rake (>= 0.8.7) rake (>= 0.8.7)
rdoc (~> 3.4) thor (>= 0.18.1, < 2.0)
thor (>= 0.14.6, < 2.0) rake (12.0.0)
rake (11.3.0)
rdoc (3.12.2)
json (~> 1.4)
ref (2.0.0) ref (2.0.0)
responders (2.4.0)
actionpack (>= 4.2.0, < 5.3)
railties (>= 4.2.0, < 5.3)
rspec-core (3.5.4) rspec-core (3.5.4)
rspec-support (~> 3.5.0) rspec-support (~> 3.5.0)
rspec-expectations (3.5.0) rspec-expectations (3.5.0)
@ -128,30 +148,28 @@ GEM
rspec-mocks (~> 3.5.0) rspec-mocks (~> 3.5.0)
rspec-support (~> 3.5.0) rspec-support (~> 3.5.0)
rspec-support (3.5.0) rspec-support (3.5.0)
sprockets (2.2.3) sprockets (3.7.1)
hike (~> 1.2) concurrent-ruby (~> 1.0)
multi_json (~> 1.0) rack (> 1, < 3)
rack (~> 1.0) sprockets-rails (3.2.0)
tilt (~> 1.1, != 1.3.0) actionpack (>= 4.0)
activesupport (>= 4.0)
sprockets (>= 3.0.0)
sqlite3 (1.3.12) sqlite3 (1.3.12)
strong_parameters (0.2.3)
actionpack (~> 3.0)
activemodel (~> 3.0)
activesupport (~> 3.0)
railties (~> 3.0)
test-unit (3.2.1) test-unit (3.2.1)
power_assert power_assert
therubyracer (0.12.2) therubyracer (0.12.2)
libv8 (~> 3.16.14.0) libv8 (~> 3.16.14.0)
ref ref
thor (0.19.1) thor (0.19.4)
tilt (1.4.1) thread_safe (0.3.6)
treetop (1.4.15) tzinfo (1.2.3)
polyglot thread_safe (~> 0.1)
polyglot (>= 0.3.1)
tzinfo (0.3.51)
uglifier (3.0.2) uglifier (3.0.2)
execjs (>= 0.3.0, < 3) execjs (>= 0.3.0, < 3)
websocket-driver (0.6.5)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.2)
xpath (2.0.0) xpath (2.0.0)
nokogiri (~> 1.3) nokogiri (~> 1.3)
@ -162,13 +180,16 @@ DEPENDENCIES
capybara capybara
capybara-webkit capybara-webkit
generator_spec generator_spec
rails (= 3.2.22) rails (= 5.1.1)
responders
rspec-rails rspec-rails
rswag-api! rswag-api!
rswag-specs! rswag-specs!
rswag-ui! rswag-ui!
sqlite3 sqlite3
strong_parameters
test-unit test-unit
therubyracer therubyracer
uglifier uglifier
BUNDLED WITH
1.14.6

View File

@ -16,5 +16,5 @@ Gem::Specification.new do |s|
s.files = Dir["{lib}/**/*"] + ["MIT-LICENSE", "Rakefile" ] s.files = Dir["{lib}/**/*"] + ["MIT-LICENSE", "Rakefile" ]
s.add_dependency "rails", ">= 3.1", "< 5.1" s.add_dependency "rails", ">= 3.1", "< 5.2"
end end

View File

@ -16,7 +16,7 @@ Gem::Specification.new do |s|
s.files = Dir["{lib}/**/*"] + ["MIT-LICENSE", "Rakefile" ] s.files = Dir["{lib}/**/*"] + ["MIT-LICENSE", "Rakefile" ]
s.add_dependency "rails", ">= 3.1", "< 5.1" s.add_dependency "rails", ">= 3.1", "< 5.2"
s.add_dependency 'json', '~> 1.8' s.add_dependency 'json', '~> 1.8'
s.add_dependency 'json-schema', '~> 2.2' s.add_dependency 'json-schema', '~> 2.2'
s.add_dependency 'rspec-rails', '>= 2.14', '< 4' s.add_dependency 'rspec-rails', '>= 2.14', '< 4'

View File

@ -16,5 +16,5 @@ Gem::Specification.new do |s|
s.files = Dir["{app,config,lib,vendor}/**/*"] + ["MIT-LICENSE", "Rakefile" ] s.files = Dir["{app,config,lib,vendor}/**/*"] + ["MIT-LICENSE", "Rakefile" ]
s.add_dependency "rails", ">= 3.1", "< 5.1" s.add_dependency "rails", ">= 3.1", "< 5.2"
end end

View File

@ -1,4 +1,10 @@
class CreateBlogs < ActiveRecord::Migration migration_class = if Gem::Version.new(Rails.version) >= Gem::Version.new("5.0")
ActiveRecord::Migration[4.2]
else
ActiveRecord::Migration
end
class CreateBlogs < migration_class
def change def change
create_table :blogs do |t| create_table :blogs do |t|
t.string :title t.string :title

View File

@ -1,4 +1,3 @@
# encoding: UTF-8
# This file is auto-generated from the current state of the database. Instead # This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to # of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition. # incrementally modify your database, and then regenerate this schema definition.
@ -9,15 +8,15 @@
# from scratch. The latter is a flawed and unsustainable approach (the more migrations # from scratch. The latter is a flawed and unsustainable approach (the more migrations
# you'll amass, the slower it'll run and the greater likelihood for issues). # you'll amass, the slower it'll run and the greater likelihood for issues).
# #
# It's strongly recommended to check this file into your version control system. # It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(:version => 20160218212104) do ActiveRecord::Schema.define(version: 20160218212104) do
create_table "blogs", :force => true do |t| create_table "blogs", force: :cascade do |t|
t.string "title" t.string "title"
t.text "content" t.text "content"
t.datetime "created_at", :null => false t.datetime "created_at"
t.datetime "updated_at", :null => false t.datetime "updated_at"
end end
end end