Sha256: 3afe7529318e7e56c1371c5621d60db66c99713e2ba3ad8253a65e1b78919cb1
Contents?: true
Size: 550 Bytes
Versions: 4
Compression:
Stored size: 550 Bytes
Contents
class MockApplication def self.env_config {} end def self.routes @routes ||= ActionDispatch::Routing::RouteSet.new end end MockApplication.routes.draw do resource :callback_tests end ::Rails.application = MockApplication ActionController::Base.send :include, RailsLocaleDetection::ControllerMethods ActionController::Base.send :include, Rails.application.routes.url_helpers class CallbackTestsController < ActionController::Base def user_locale :fr end def show render :text => current_locale end end
Version data entries
4 entries across 4 versions & 1 rubygems