mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
Massage setup for old tests on new base
This commit is contained in:
@@ -57,8 +57,7 @@ end
|
||||
|
||||
desc 'Old Controller Tests on New Base'
|
||||
Rake::TestTask.new(:test_new_base_on_old_tests) do |t|
|
||||
ENV['new_base'] = "true"
|
||||
t.libs << "test"
|
||||
t.libs << "test/new_base" << "test"
|
||||
# content_type mime_responds layout
|
||||
t.test_files = %w(
|
||||
addresses_render base benchmark caching capture dispatcher record_identifier
|
||||
|
||||
@@ -1,6 +1,3 @@
|
||||
if ENV["new_base"]
|
||||
require "abstract_unit2"
|
||||
else
|
||||
$:.unshift(File.dirname(__FILE__) + '/../lib')
|
||||
$:.unshift(File.dirname(__FILE__) + '/../../activesupport/lib')
|
||||
$:.unshift(File.dirname(__FILE__) + '/fixtures/helpers')
|
||||
@@ -41,4 +38,3 @@ ORIGINAL_LOCALES = I18n.available_locales.map {|locale| locale.to_s }.sort
|
||||
|
||||
FIXTURE_LOAD_PATH = File.join(File.dirname(__FILE__), 'fixtures')
|
||||
ActionController::Base.view_paths = FIXTURE_LOAD_PATH
|
||||
end
|
||||
@@ -1,7 +1,9 @@
|
||||
$:.unshift(File.dirname(__FILE__) + '/../../lib')
|
||||
$:.unshift(File.dirname(__FILE__) + '/../../../activesupport/lib')
|
||||
$:.unshift(File.dirname(__FILE__) + '/../lib')
|
||||
$:.unshift(File.dirname(__FILE__) + '/../../activesupport/lib')
|
||||
$:.unshift(File.dirname(__FILE__) + '/lib')
|
||||
|
||||
ENV['new_base'] = "true"
|
||||
$stderr.puts "Running old tests on new_base"
|
||||
|
||||
require 'test/unit'
|
||||
require 'active_support'
|
||||
@@ -16,7 +18,7 @@ require 'active_support/dependencies'
|
||||
|
||||
ActiveSupport::Dependencies.hook!
|
||||
|
||||
FIXTURE_LOAD_PATH = File.join(File.dirname(__FILE__), 'fixtures')
|
||||
FIXTURE_LOAD_PATH = File.join(File.dirname(__FILE__), '../fixtures')
|
||||
|
||||
module ActionController
|
||||
Base.session = {
|
||||
Reference in New Issue
Block a user