1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00

Use bundled env for tests only

This commit is contained in:
Jeremy Kemper 2009-10-19 19:00:48 -07:00
parent c9cd10c4fa
commit 2767036392
3 changed files with 13 additions and 14 deletions

View file

@ -3,8 +3,6 @@ sibling = "#{File.dirname(__FILE__)}/.."
gem "activesupport", "3.0.pre", :vendored_at => "#{sibling}/activesupport"
gem "activemodel", "3.0.pre", :vendored_at => "#{sibling}/activemodel"
gem "arel", :git => "git://github.com/rails/arel.git", :branch => 'master'
gem "arel", :git => "git://github.com/rails/arel.git"
only :test do
gem "mocha"
end

View file

@ -21,16 +21,11 @@
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#++
bundled = "#{File.dirname(__FILE__)}/../vendor/gems/environment"
if File.exist?("#{bundled}.rb")
require bundled
else
activesupport_path = "#{File.dirname(__FILE__)}/../../activesupport/lib"
$:.unshift(activesupport_path) if File.directory?(activesupport_path)
activemodel_path = "#{File.dirname(__FILE__)}/../../activemodel/lib"
$:.unshift(activemodel_path) if File.directory?(activemodel_path)
end
require 'active_support'
require 'active_model'

View file

@ -1,5 +1,11 @@
$:.unshift(File.dirname(__FILE__) + '/../../lib')
bundled = "#{File.dirname(__FILE__)}/../../vendor/gems/environment"
if File.exist?("#{bundled}.rb")
require bundled
else
$:.unshift(File.dirname(__FILE__) + '/../../../activesupport/lib')
end
require 'config'