diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2004-11-24 01:04:44 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2004-11-24 01:04:44 +0000 |
commit | db045dbbf60b53dbe013ef25554fd013baf88134 (patch) | |
tree | 257830e3c76458c8ff3d1329de83f32b23926028 /railties/helpers | |
download | rails-db045dbbf60b53dbe013ef25554fd013baf88134.tar.gz rails-db045dbbf60b53dbe013ef25554fd013baf88134.tar.bz2 rails-db045dbbf60b53dbe013ef25554fd013baf88134.zip |
Initial
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'railties/helpers')
-rw-r--r-- | railties/helpers/abstract_application.rb | 5 | ||||
-rw-r--r-- | railties/helpers/application_helper.rb | 3 | ||||
-rw-r--r-- | railties/helpers/test_helper.rb | 16 |
3 files changed, 24 insertions, 0 deletions
diff --git a/railties/helpers/abstract_application.rb b/railties/helpers/abstract_application.rb new file mode 100644 index 0000000000..fa26cd0399 --- /dev/null +++ b/railties/helpers/abstract_application.rb @@ -0,0 +1,5 @@ +# The filters added to this controller will be run for all controllers in the application. +# Likewise will all the methods added be available for all controllers. +class AbstractApplicationController < ActionController::Base + helper :application +end
\ No newline at end of file diff --git a/railties/helpers/application_helper.rb b/railties/helpers/application_helper.rb new file mode 100644 index 0000000000..0392b53b46 --- /dev/null +++ b/railties/helpers/application_helper.rb @@ -0,0 +1,3 @@ +# The methods added to this helper will be available to all templates in the application. +module ApplicationHelper +end diff --git a/railties/helpers/test_helper.rb b/railties/helpers/test_helper.rb new file mode 100644 index 0000000000..d348f26517 --- /dev/null +++ b/railties/helpers/test_helper.rb @@ -0,0 +1,16 @@ +ENV["RAILS_ENV"] ||= "test" +require File.dirname(__FILE__) + "/../config/environment" + +require 'test/unit' +require 'active_record/fixtures' +require 'action_controller/test_process' + +# Make rubygems available for testing if possible +begin require('rubygems'); rescue LoadError; end +begin require('dev-utils/debug'); rescue LoadError; end + +def create_fixtures(*table_names) + Fixtures.create_fixtures(File.dirname(__FILE__) + "/fixtures", table_names) +end + +Test::Unit::TestCase.fixture_path = File.dirname(__FILE__) + "/fixtures/"
\ No newline at end of file |