Changes to get specs to green. Remove Ruby version related dotfiles to allow use of multiple Ruby versions

This commit is contained in:
Peter M. Goldstein 2013-12-27 10:50:10 -08:00
parent c0c7885466
commit 83a9e99925
5 changed files with 8 additions and 8 deletions

3
.gitignore vendored
View file

@ -9,4 +9,7 @@ examples/db/*.db
examples/config/database.yml
db/config.yml
db/test.sqlite3
.rbenv-version
.rvmrc
.ruby-version
.vagrant

View file

@ -1 +0,0 @@
1.9.2-p290

1
.rvmrc
View file

@ -1 +0,0 @@
rvm 1.9.3

View file

@ -2,6 +2,7 @@ language: ruby
rvm:
- 1.9.3
- 2.0.0
- 2.1.0
# TODO: make this work with the regular rake command
script: "bundle exec rake spec"
gemfile:
@ -11,7 +12,5 @@ before_script:
- psql -c 'create database database_cleaner_test;' -U postgres
- cp db/sample.config.yml db/config.yml
services:
- redis-server
- mongodb
matrix:
allow_failures:
- rvm: 2.0.0

View file

@ -58,7 +58,7 @@ module DatabaseCleaner
connection.should_receive(:open_transactions).and_return(1)
connection.stub(:respond_to?).with(:decrement_open_transactions).and_return(true)
connection.stub(:respond_to?).with(:rollback_transaction_records).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction_records, true).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction).and_return(false)
connection.stub(:rollback_db_transaction)
@ -75,7 +75,7 @@ module DatabaseCleaner
it "should decrement connection via ActiveRecord::Base if connection won't" do
connection.should_receive(:open_transactions).and_return(1)
connection.stub(:respond_to?).with(:decrement_open_transactions).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction_records).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction_records, true).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction).and_return(false)
connection.stub(:rollback_db_transaction)
@ -112,7 +112,7 @@ module DatabaseCleaner
it "should decrement connection via ActiveRecord::Base if connection won't" do
connection.should_receive(:open_transactions).and_return(1)
connection.stub(:respond_to?).with(:rollback_transaction_records).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction_records, true).and_return(false)
connection.stub(:respond_to?).with(:rollback_transaction).and_return(true)
connection.stub(:rollback_transaction)