1
0
Fork 0
mirror of https://github.com/thoughtbot/shoulda-matchers.git synced 2022-11-09 12:01:38 -05:00

Add Appraisal for Rails 4.0.1

This commit is contained in:
Elliot Winkler 2013-12-01 17:57:03 -05:00
parent 41e4f03bd4
commit e3c64779de
8 changed files with 236 additions and 38 deletions

View file

@ -17,11 +17,15 @@ matrix:
- rvm: jruby-19mode
include:
- rvm: 1.9.3
gemfile: gemfiles/4.0.gemfile
gemfile: gemfiles/4.0.0.gemfile
- rvm: 1.9.3
gemfile: gemfiles/4.0.1.gemfile
- rvm: 2.0.0
gemfile: gemfiles/3.2.gemfile
- rvm: 2.0.0
gemfile: gemfiles/4.0.gemfile
gemfile: gemfiles/4.0.0.gemfile
- rvm: 2.0.0
gemfile: gemfiles/4.0.1.gemfile
- rvm: rbx-19mode
gemfile: gemfiles/3.2.gemfile
- rvm: jruby-19mode

View file

@ -1,3 +1,12 @@
rails_4_0 = proc do
gem 'jquery-rails'
gem 'activeresource', '4.0.0'
# Test suite makes heavy use of attr_accessible
gem 'protected_attributes'
end
#---
if RUBY_VERSION < '2.0'
appraise '3.0' do
gem 'rails', '~> 3.0.17'
@ -21,13 +30,16 @@ appraise '3.2' do
gem 'strong_parameters'
end
appraise '4.0' do
appraise '4.0.0' do
instance_eval(&rails_4_0)
gem 'rails', '4.0.0'
gem 'bcrypt-ruby', '~> 3.0.0' #FIXME: This should be ~> 3.1.0 for Rails 4.0
gem 'jquery-rails'
gem 'sass-rails', '~> 4.0.0'
gem 'activeresource', require: 'active_resource'
# Test suite makes heavy use of attr_accessible
gem 'protected_attributes'
gem 'sass-rails', '4.0.0'
gem 'bcrypt-ruby', '~> 3.0.0'
end
appraise '4.0.1' do
instance_eval(&rails_4_0)
gem 'rails', '4.0.1'
gem 'sass-rails', '4.0.1'
gem 'bcrypt-ruby', '~> 3.1.2'
end

View file

@ -154,7 +154,7 @@ module FileHelpers
end
def rails_4?
match = ORIGINAL_BUNDLE_VARS['BUNDLE_GEMFILE'].match(/(\d)\.\d\.gemfile$/)
match = ORIGINAL_BUNDLE_VARS['BUNDLE_GEMFILE'].match(/(\d)\.\d\.(\d\.)?gemfile$/)
match.captures[0] == '4'
end
end

View file

@ -9,11 +9,11 @@ gem "activerecord-jdbcsqlite3-adapter", :platform=>:jruby
gem "jdbc-sqlite3", :platform=>:jruby
gem "jruby-openssl", :platform=>:jruby
gem "therubyrhino", :platform=>:jruby
gem "rails", "4.0.0"
gem "bcrypt-ruby", "~> 3.0.0"
gem "jquery-rails"
gem "sass-rails", "~> 4.0.0"
gem "activeresource", :require=>"active_resource"
gem "activeresource", "4.0.0"
gem "protected_attributes"
gem "rails", "4.0.0"
gem "sass-rails", "4.0.0"
gem "bcrypt-ruby", "~> 3.0.0"
gemspec :path=>"../"

View file

@ -38,28 +38,28 @@ GEM
appraisal (0.5.2)
bundler
rake
arel (4.0.0)
arel (4.0.1)
aruba (0.5.3)
childprocess (>= 0.3.6)
cucumber (>= 1.1.1)
rspec-expectations (>= 2.7.0)
atomic (1.1.13)
atomic (1.1.14)
bcrypt-ruby (3.0.1)
bourne (1.5.0)
mocha (>= 0.13.2, < 0.15)
builder (3.1.4)
childprocess (0.3.9)
ffi (~> 1.0, >= 1.0.11)
cucumber (1.3.6)
cucumber (1.3.10)
builder (>= 2.1.2)
diff-lcs (>= 1.1.3)
gherkin (~> 2.12.0)
multi_json (~> 1.7.5)
gherkin (~> 2.12)
multi_json (>= 1.7.5, < 2.0)
multi_test (>= 0.0.2)
diff-lcs (1.2.4)
diff-lcs (1.2.5)
erubis (2.7.0)
ffi (1.9.0)
gherkin (2.12.1)
ffi (1.9.3)
gherkin (2.12.2)
multi_json (~> 1.3)
hike (1.2.3)
i18n (0.6.5)
@ -70,11 +70,11 @@ GEM
mime-types (~> 1.16)
treetop (~> 1.4.8)
metaclass (0.0.1)
mime-types (1.24)
mime-types (1.25.1)
minitest (4.7.5)
mocha (0.14.0)
metaclass (~> 0.0.1)
multi_json (1.7.9)
multi_json (1.8.2)
multi_test (0.0.2)
polyglot (0.3.3)
protected_attributes (1.0.3)
@ -98,10 +98,10 @@ GEM
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
rake (10.1.0)
rspec-core (2.14.5)
rspec-expectations (2.14.2)
rspec-core (2.14.7)
rspec-expectations (2.14.4)
diff-lcs (>= 1.1.3, < 2.0)
rspec-mocks (2.14.3)
rspec-mocks (2.14.4)
rspec-rails (2.14.0)
actionpack (>= 3.0)
activesupport (>= 3.0)
@ -109,30 +109,30 @@ GEM
rspec-core (~> 2.14.0)
rspec-expectations (~> 2.14.0)
rspec-mocks (~> 2.14.0)
sass (3.2.10)
sass (3.2.12)
sass-rails (4.0.0)
railties (>= 4.0.0.beta, < 5.0)
sass (>= 3.1.10)
sprockets-rails (~> 2.0.0)
shoulda-context (1.1.4)
sprockets (2.10.0)
shoulda-context (1.1.6)
sprockets (2.10.1)
hike (~> 1.2)
multi_json (~> 1.0)
rack (~> 1.0)
tilt (~> 1.1, != 1.3.0)
sprockets-rails (2.0.0)
sprockets-rails (2.0.1)
actionpack (>= 3.0)
activesupport (>= 3.0)
sprockets (~> 2.8)
sqlite3 (1.3.7)
sqlite3 (1.3.8)
thor (0.18.1)
thread_safe (0.1.2)
thread_safe (0.1.3)
atomic
tilt (1.4.1)
treetop (1.4.14)
treetop (1.4.15)
polyglot
polyglot (>= 0.3.1)
tzinfo (0.3.37)
tzinfo (0.3.38)
PLATFORMS
ruby
@ -140,7 +140,7 @@ PLATFORMS
DEPENDENCIES
activerecord-jdbc-adapter
activerecord-jdbcsqlite3-adapter
activeresource
activeresource (= 4.0.0)
appraisal (~> 0.4)
aruba
bcrypt-ruby (~> 3.0.0)
@ -154,7 +154,7 @@ DEPENDENCIES
rails (= 4.0.0)
rake (>= 0.9.2)
rspec-rails (>= 2.13.1, < 3)
sass-rails (~> 4.0.0)
sass-rails (= 4.0.0)
shoulda-context (~> 1.1.2)
shoulda-matchers!
sqlite3

19
gemfiles/4.0.1.gemfile Normal file
View file

@ -0,0 +1,19 @@
# This file was generated by Appraisal
source "https://rubygems.org"
gem "shoulda-context", "~> 1.1.2"
gem "sqlite3", :platform=>:ruby
gem "activerecord-jdbc-adapter", :platform=>:jruby
gem "activerecord-jdbcsqlite3-adapter", :platform=>:jruby
gem "jdbc-sqlite3", :platform=>:jruby
gem "jruby-openssl", :platform=>:jruby
gem "therubyrhino", :platform=>:jruby
gem "jquery-rails"
gem "activeresource", "4.0.0"
gem "protected_attributes"
gem "rails", "4.0.1"
gem "sass-rails", "4.0.1"
gem "bcrypt-ruby", "~> 3.1.2"
gemspec :path=>"../"

161
gemfiles/4.0.1.gemfile.lock Normal file
View file

@ -0,0 +1,161 @@
PATH
remote: ../
specs:
shoulda-matchers (2.4.0)
activesupport (>= 3.0.0)
GEM
remote: https://rubygems.org/
specs:
actionmailer (4.0.1)
actionpack (= 4.0.1)
mail (~> 2.5.4)
actionpack (4.0.1)
activesupport (= 4.0.1)
builder (~> 3.1.0)
erubis (~> 2.7.0)
rack (~> 1.5.2)
rack-test (~> 0.6.2)
activemodel (4.0.1)
activesupport (= 4.0.1)
builder (~> 3.1.0)
activerecord (4.0.1)
activemodel (= 4.0.1)
activerecord-deprecated_finders (~> 1.0.2)
activesupport (= 4.0.1)
arel (~> 4.0.0)
activerecord-deprecated_finders (1.0.3)
activeresource (4.0.0)
activemodel (~> 4.0)
activesupport (~> 4.0)
rails-observers (~> 0.1.1)
activesupport (4.0.1)
i18n (~> 0.6, >= 0.6.4)
minitest (~> 4.2)
multi_json (~> 1.3)
thread_safe (~> 0.1)
tzinfo (~> 0.3.37)
appraisal (0.5.2)
bundler
rake
arel (4.0.1)
aruba (0.5.3)
childprocess (>= 0.3.6)
cucumber (>= 1.1.1)
rspec-expectations (>= 2.7.0)
atomic (1.1.14)
bcrypt-ruby (3.1.2)
bourne (1.5.0)
mocha (>= 0.13.2, < 0.15)
builder (3.1.4)
childprocess (0.3.9)
ffi (~> 1.0, >= 1.0.11)
cucumber (1.3.10)
builder (>= 2.1.2)
diff-lcs (>= 1.1.3)
gherkin (~> 2.12)
multi_json (>= 1.7.5, < 2.0)
multi_test (>= 0.0.2)
diff-lcs (1.2.5)
erubis (2.7.0)
ffi (1.9.3)
gherkin (2.12.2)
multi_json (~> 1.3)
hike (1.2.3)
i18n (0.6.5)
jquery-rails (3.0.4)
railties (>= 3.0, < 5.0)
thor (>= 0.14, < 2.0)
mail (2.5.4)
mime-types (~> 1.16)
treetop (~> 1.4.8)
metaclass (0.0.1)
mime-types (1.25.1)
minitest (4.7.5)
mocha (0.14.0)
metaclass (~> 0.0.1)
multi_json (1.8.2)
multi_test (0.0.2)
polyglot (0.3.3)
protected_attributes (1.0.5)
activemodel (>= 4.0.1, < 5.0)
rack (1.5.2)
rack-test (0.6.2)
rack (>= 1.0)
rails (4.0.1)
actionmailer (= 4.0.1)
actionpack (= 4.0.1)
activerecord (= 4.0.1)
activesupport (= 4.0.1)
bundler (>= 1.3.0, < 2.0)
railties (= 4.0.1)
sprockets-rails (~> 2.0.0)
rails-observers (0.1.2)
activemodel (~> 4.0)
railties (4.0.1)
actionpack (= 4.0.1)
activesupport (= 4.0.1)
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
rake (10.1.0)
rspec-core (2.14.7)
rspec-expectations (2.14.4)
diff-lcs (>= 1.1.3, < 2.0)
rspec-mocks (2.14.4)
rspec-rails (2.14.0)
actionpack (>= 3.0)
activesupport (>= 3.0)
railties (>= 3.0)
rspec-core (~> 2.14.0)
rspec-expectations (~> 2.14.0)
rspec-mocks (~> 2.14.0)
sass (3.2.12)
sass-rails (4.0.1)
railties (>= 4.0.0, < 5.0)
sass (>= 3.1.10)
sprockets-rails (~> 2.0.0)
shoulda-context (1.1.6)
sprockets (2.10.1)
hike (~> 1.2)
multi_json (~> 1.0)
rack (~> 1.0)
tilt (~> 1.1, != 1.3.0)
sprockets-rails (2.0.1)
actionpack (>= 3.0)
activesupport (>= 3.0)
sprockets (~> 2.8)
sqlite3 (1.3.8)
thor (0.18.1)
thread_safe (0.1.3)
atomic
tilt (1.4.1)
treetop (1.4.15)
polyglot
polyglot (>= 0.3.1)
tzinfo (0.3.38)
PLATFORMS
ruby
DEPENDENCIES
activerecord-jdbc-adapter
activerecord-jdbcsqlite3-adapter
activeresource (= 4.0.0)
appraisal (~> 0.4)
aruba
bcrypt-ruby (~> 3.1.2)
bourne (~> 1.3)
bundler (~> 1.1)
cucumber (~> 1.1)
jdbc-sqlite3
jquery-rails
jruby-openssl
protected_attributes
rails (= 4.0.1)
rake (>= 0.9.2)
rspec-rails (>= 2.13.1, < 3)
sass-rails (= 4.0.1)
shoulda-context (~> 1.1.2)
shoulda-matchers!
sqlite3
therubyrhino

View file

@ -1,3 +1,5 @@
require 'active_resource'
module ActiveResourceBuilder
def self.included(example_group)
example_group.class_eval do