mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
3030bc90c9
Conflicts: actionpack/lib/action_controller/base.rb actionpack/lib/action_dispatch/http/mime_type.rb actionpack/lib/action_dispatch/http/request.rb actionpack/lib/action_view/base.rb actionpack/lib/action_view/paths.rb actionpack/test/controller/session/cookie_store_test.rb actionpack/test/dispatch/rack_test.rb actionpack/test/dispatch/request_test.rb
43 lines
1.1 KiB
Ruby
43 lines
1.1 KiB
Ruby
$:.unshift(File.dirname(__FILE__) + '/../lib')
|
|
$:.unshift(File.dirname(__FILE__) + '/../../activesupport/lib')
|
|
$:.unshift(File.dirname(__FILE__) + '/fixtures/helpers')
|
|
$:.unshift(File.dirname(__FILE__) + '/fixtures/alternate_helpers')
|
|
|
|
require 'rubygems'
|
|
require 'yaml'
|
|
require 'stringio'
|
|
require 'test/unit'
|
|
|
|
gem 'mocha', '>= 0.9.3'
|
|
require 'mocha'
|
|
|
|
begin
|
|
require 'ruby-debug'
|
|
Debugger.settings[:autoeval] = true
|
|
Debugger.start
|
|
rescue LoadError
|
|
# Debugging disabled. `gem install ruby-debug` to enable.
|
|
end
|
|
|
|
require 'action_controller'
|
|
require 'action_controller/testing/process'
|
|
require 'action_view/test_case'
|
|
|
|
# Show backtraces for deprecated behavior for quicker cleanup.
|
|
ActiveSupport::Deprecation.debug = true
|
|
|
|
ActionController::Base.logger = nil
|
|
ActionController::Routing::Routes.reload rescue nil
|
|
|
|
ActionController::Base.session_store = nil
|
|
|
|
# Register danish language for testing
|
|
I18n.backend.store_translations 'da', {}
|
|
ORIGINAL_LOCALES = I18n.available_locales
|
|
|
|
FIXTURE_LOAD_PATH = File.join(File.dirname(__FILE__), 'fixtures')
|
|
ActionController::Base.view_paths = FIXTURE_LOAD_PATH
|
|
|
|
def uses_mocha(test_name)
|
|
yield
|
|
end
|