Type:
Module
Constants:

DEFAULT_ALIASES : { rails: { actions: '-a', orm: '-o', javascripts: '-j', javascript_engine: '-je', resource_controller: '-c', scaffold_controller: '-c', stylesheets: '-y', stylesheet_engine: '-se', template_engine: '-e', test_framework: '-t' }, test_unit: { fixture_replacement: '-r', } }

DEFAULT_OPTIONS : { rails: { assets: true, force_plural: false, helper: true, integration_tool: nil, javascripts: true, javascript_engine: :js, orm: false, resource_controller: :controller, resource_route: true, scaffold_controller: :scaffold_controller, stylesheets: true, stylesheet_engine: :css, test_framework: false, template_engine: :erb } }
RAILS_DEV_PATH : File.expand_path("../../../../../..", File.dirname(__FILE__))

We need to store the RAILS_DEV_PATH in a constant, otherwise the path can change in Ruby 1.8.7 when we FileUtils.cd.

RESERVED_NAMES : %w[application destroy plugin runner test]
test_add_gem_with_version
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators

test_add_gem_with_version() Instance Public methods

2025-01-10 15:47:30
default_source_root
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::Base

default_source_root() Class Public methods Returns the default source root for

2025-01-10 15:47:30
run_generator
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::Testing/Rails::Generators::Testing::Behaviour

run_generator(args=self.default_arguments, config={}) Instance Public methods Runs

2025-01-10 15:47:30
assert_field_type
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::Testing/Rails::Generators::Testing::Assertions

assert_field_type(attribute_type, field_type) Instance Public methods Asserts

2025-01-10 15:47:30
test_two_filters
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators

test_two_filters() Instance Public methods

2025-01-10 15:47:30
pluralize_table_names?
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::NamedBase

pluralize_table_names?() Instance Protected methods

2025-01-10 15:47:30
gem
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::Actions

gem(*args) Instance Public methods Adds an entry into Gemfile for

2025-01-10 15:47:30
plural_name
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::NamedBase

plural_name() Instance Protected methods

2025-01-10 15:47:30
existing_migration
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::Actions/Rails::Generators::Actions::CreateMigration

existing_migration() Instance Public methods Also aliased as:

2025-01-10 15:47:30
tests
  • References/Ruby on Rails/Rails/Classes/Rails/Rails::Generators/Rails::Generators::Testing/Rails::Generators::Testing::Behaviour/Rails::Generators::Testing::Behaviour::ClassMethods

tests(klass) Instance Public methods Sets which generator should be tested:

2025-01-10 15:47:30