Permalink
Browse files

Replace Appraisal with BUNDLE_GEMFILE

  • Loading branch information...
1 parent 015d0de commit f1e849d57a8c8efe2ade93ba4b3042d263c63adb @nathany nathany committed Feb 28, 2014
View
@@ -8,4 +8,5 @@ doc/*
benchmarks/*
.specification
.rvmrc
-gemfiles/*.gemfile.lock
+test/gemfiles/Gemfile*.lock
+.bundle
View
@@ -1,3 +1,4 @@
+language: ruby
rvm:
- 1.8.7
- 1.9.3
@@ -7,12 +8,20 @@ rvm:
- jruby
gemfile:
- - gemfiles/rails3.gemfile
- - gemfiles/rails4.gemfile
+ - test/gemfiles/Gemfile.rails-3.2.x
+ - test/gemfiles/Gemfile.rails-4.0.x
+ - test/gemfiles/Gemfile.rails-4.1.x
matrix:
exclude:
- rvm: 1.8.7
- gemfile: gemfiles/rails4.gemfile
+ gemfile: test/gemfiles/Gemfile.rails-4.0.x
- rvm: ree
- gemfile: gemfiles/rails4.gemfile
+ gemfile: test/gemfiles/Gemfile.rails-4.0.x
+ - rvm: 1.8.7
+ gemfile: test/gemfiles/Gemfile.rails-4.1.x
+ - rvm: ree
+ gemfile: test/gemfiles/Gemfile.rails-4.1.x
+ allow_failures:
+ - gemfile: test/gemfiles/Gemfile.rails-4.1.x
+ fast_finish: true
View
@@ -1,9 +0,0 @@
-appraise "rails3" do
- gem "activerecord", "3.2.17"
- gem "activesupport", "3.2.17"
-end
-
-appraise "rails4" do
- gem "activerecord", "4.0.3"
- gem "activesupport", "4.0.3"
-end
View
@@ -0,0 +1,10 @@
+
+### Testing
+
+Tests can be ran against different versions of Rails like so:
+
+```
+BUNDLE_GEMFILE=test/gemfiles/Gemfile.rails-3.2.x bundle install
+BUNDLE_GEMFILE=test/gemfiles/Gemfile.rails-3.2.x bundle exec rake test
+```
+
View
@@ -23,9 +23,6 @@ GEM
multi_json (~> 1.3)
thread_safe (~> 0.1)
tzinfo (~> 0.3.37)
- appraisal (0.5.2)
- bundler
- rake
arel (4.0.2)
atomic (1.1.15)
bcrypt (3.1.7)
@@ -53,7 +50,6 @@ PLATFORMS
ruby
DEPENDENCIES
- appraisal
authlogic!
bcrypt-ruby
i18n
View
@@ -3,8 +3,6 @@ require 'bundler'
Bundler.setup
-require 'appraisal'
-
require 'rake/testtask'
Rake::TestTask.new(:test) do |test|
test.libs << 'test'
View
@@ -19,7 +19,6 @@ Gem::Specification.new do |s|
s.add_development_dependency 'sqlite3'
s.add_development_dependency 'timecop'
s.add_development_dependency 'i18n'
- s.add_development_dependency 'appraisal'
s.files = `git ls-files`.split("\n")
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
@@ -1,57 +0,0 @@
-PATH
- remote: ../
- specs:
- authlogic (3.3.0)
- activerecord (>= 3.2)
- activesupport (>= 3.2)
-
-GEM
- remote: https://rubygems.org/
- specs:
- activemodel (3.2.17)
- activesupport (= 3.2.17)
- builder (~> 3.0.0)
- activerecord (3.2.17)
- activemodel (= 3.2.17)
- activesupport (= 3.2.17)
- arel (~> 3.0.2)
- tzinfo (~> 0.3.29)
- activesupport (3.2.17)
- i18n (~> 0.6, >= 0.6.4)
- multi_json (~> 1.0)
- appraisal (0.5.2)
- bundler
- rake
- arel (3.0.3)
- bcrypt (3.1.7)
- bcrypt-ruby (3.1.5)
- bcrypt (>= 3.1.3)
- builder (3.0.4)
- ffi (1.9.3)
- ffi-compiler (0.1.3)
- ffi (>= 1.0.0)
- rake
- i18n (0.6.9)
- multi_json (1.8.4)
- rake (10.1.1)
- scrypt (1.2.0)
- ffi-compiler (>= 0.0.2)
- rake
- sqlite3 (1.3.9)
- timecop (0.7.1)
- tzinfo (0.3.38)
-
-PLATFORMS
- ruby
-
-DEPENDENCIES
- activerecord (= 3.2.17)
- activesupport (= 3.2.17)
- appraisal
- authlogic!
- bcrypt-ruby
- i18n
- rake
- scrypt
- sqlite3
- timecop
@@ -1,65 +0,0 @@
-PATH
- remote: ../
- specs:
- authlogic (3.3.0)
- activerecord (>= 3.2)
- activesupport (>= 3.2)
-
-GEM
- remote: https://rubygems.org/
- specs:
- activemodel (4.0.3)
- activesupport (= 4.0.3)
- builder (~> 3.1.0)
- activerecord (4.0.3)
- activemodel (= 4.0.3)
- activerecord-deprecated_finders (~> 1.0.2)
- activesupport (= 4.0.3)
- arel (~> 4.0.0)
- activerecord-deprecated_finders (1.0.3)
- activesupport (4.0.3)
- 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.2)
- atomic (1.1.15)
- bcrypt (3.1.7)
- bcrypt-ruby (3.1.5)
- bcrypt (>= 3.1.3)
- builder (3.1.4)
- ffi (1.9.3)
- ffi-compiler (0.1.3)
- ffi (>= 1.0.0)
- rake
- i18n (0.6.9)
- minitest (4.7.5)
- multi_json (1.8.4)
- rake (10.1.1)
- scrypt (1.2.0)
- ffi-compiler (>= 0.0.2)
- rake
- sqlite3 (1.3.9)
- thread_safe (0.2.0)
- atomic (>= 1.1.7, < 2)
- timecop (0.7.1)
- tzinfo (0.3.38)
-
-PLATFORMS
- ruby
-
-DEPENDENCIES
- activerecord (= 4.0.3)
- activesupport (= 4.0.3)
- appraisal
- authlogic!
- bcrypt-ruby
- i18n
- rake
- scrypt
- sqlite3
- timecop
View
@@ -56,7 +56,7 @@ module Authlogic
#
# setup :activate_authlogic
#
- # For those of you unfamiliar with TestUnit, the setup method bascially just executes a method before any test is ran.
+ # For those of you unfamiliar with TestUnit, the setup method basically just executes a method before any test is ran.
# It is essentially "setting up" your tests.
#
# Once you have done this, just log users in like usual:
@@ -69,7 +69,7 @@ module Authlogic
# === Integration tests
#
# Again, just like functional tests, you don't have to do anything. As soon as you make a request, Authlogic will be
- # conntected. If you want to activate Authlogic before making a request follow the same steps described in the
+ # connected. If you want to activate Authlogic before making a request follow the same steps described in the
# "functional tests" section above. It works in the same manner.
#
# === Unit tests
@@ -81,7 +81,7 @@ module Authlogic
# that looks like a controller, acts like a controller, but isn't a "real" controller. You are essentially connecting
# Authlogic to your "mock" controller, then you can test off of the mock controller to make sure everything is functioning
# properly.
- #
+ #
# I use a mock controller to test Authlogic myself. It's part of the Authlogic library that you can easily use. It's as simple
# as functional and integration tests. Just do the following:
#
@@ -108,14 +108,15 @@ class <<@request
Authlogic::Session::Base.controller = (@request && Authlogic::TestCase::RailsRequestAdapter.new(@request)) || controller
end
-
+
# The Authlogic::TestCase::MockController object passed to Authlogic to activate it. You can access this in your test.
# See the module description for an example.
def controller
@controller ||= Authlogic::TestCase::MockController.new
end
end
-
+
::Test::Unit::TestCase.send(:include, TestCase) if defined?(::Test::Unit::TestCase)
::MiniTest::Unit::TestCase.send(:include, TestCase) if defined?(::MiniTest::Unit::TestCase)
+ ::MiniTest::Test.send(:include, TestCase) if defined?(::MiniTest::Test)
end
@@ -1,8 +1,5 @@
-# This file was generated by Appraisal
-
source "https://rubygems.org"
+gemspec :path => "./../.."
gem "activerecord", "3.2.17"
gem "activesupport", "3.2.17"
-
-gemspec :path=>"../"
@@ -1,8 +1,5 @@
-# This file was generated by Appraisal
-
source "https://rubygems.org"
+gemspec :path => "./../.."
gem "activerecord", "4.0.3"
gem "activesupport", "4.0.3"
-
-gemspec :path=>"../"
@@ -0,0 +1,5 @@
+source "https://rubygems.org"
+gemspec :path => "./../.."
+
+gem "activerecord", "4.1.0.rc1"
+gem "activesupport", "4.1.0.rc1"
View
@@ -1,5 +1,5 @@
-require "test/unit"
require "rubygems"
+require "minitest/autorun"
require "active_record"
require "active_record/fixtures"
require "timecop"

0 comments on commit f1e849d

Please sign in to comment.