Type:
Class
Constants:
FIXTURE_LOAD_PATH : File.expand_path('fixtures', File.dirname(__FILE__))
AppRoutes : ActionDispatch::Routing::RouteSet.new
ORIGINAL_LOCALES : I18n.available_locales.map {|locale| locale.to_s }.sort
FIXTURES : Pathname.new(FIXTURE_LOAD_PATH)
SharedTestRoutes : ActionDispatch::Routing::RouteSet.new
CACHE_DIR : 'test_cache'
FILE_STORE_PATH : File.join(File.dirname(__FILE__), '/../temp/', CACHE_DIR)

Don't change '/../temp/' cavalierly or you might hose something you don't want hosed

ROUTING : ActionDispatch::Routing

#<RDoc::Comment:0x007fdda5b7e320>


#<RDoc::Comment:0x007fdda580f888>


#<RDoc::Comment:0x007fddaa65daf8>


#<RDoc::Comment:0x007fdda7513c68>


#<RDoc::Comment:0x007fdda9f6fe08>


#<RDoc::Comment:0x007fdda96d08b0>


#<RDoc::Comment:0x007fdda91ad7c0>


#<RDoc::Comment:0x007fdda7b550e0>

PATH_TO_AR : "#{File.dirname(__FILE__)}/../../activerecord/lib"
Neckbeard : lambda {|template| template.source }
Bowtie : lambda {|template| template.source }
TEST_ROOT : File.expand_path(File.dirname(__FILE__))
FIXTURES_ROOT : TEST_ROOT + "/fixtures"
SCHEMA_FILE : TEST_ROOT + "/schema.rb"
TIME : (ENV['BENCHMARK_TIME'] || 20).to_i
RECORDS : (ENV['BENCHMARK_RECORDS'] || TIME*1000).to_i
QUOTED_TYPE : ActiveRecord::Base.connection.quote_column_name('type')

Quote âtypeâ if it's a reserved word for the current connection.

EXPECTED_ZONE : nil

This method makes sure that tests don't leak global state related to time zones.

EXPECTED_DEFAULT_TIMEZONE : :utc
EXPECTED_TIME_ZONE_AWARE_ATTRIBUTES : false
ASSETS_ROOT : TEST_ROOT + "/assets"
MIGRATIONS_ROOT : TEST_ROOT + "/migrations"
SCHEMA_ROOT : TEST_ROOT + "/schema"
DeveloperSalary : Struct.new(:amount)
MissingSourceFile : LoadError
HashWithIndifferentAccess : ActiveSupport::HashWithIndifferentAccess

Implements a hash where keys :foo and "foo" are considered to be the same.

rgb = ActiveSupport::HashWithIndifferentAccess.new

rgb[:black] = '#000000'
rgb[:black]  # => '#000000'
rgb['black'] # => '#000000'

rgb['white'] = '#FFFFFF'
rgb[:white]  # => '#FFFFFF'
rgb['white'] # => '#FFFFFF'

Internally symbols are mapped to strings when used as keys in the entire writing interface (calling []=, merge, etc). This mapping belongs to the public interface. For example, given:

hash = ActiveSupport::HashWithIndifferentAccess.new(a: 1)

You are guaranteed that the key is returned as a string:

hash.keys # => ["a"]

Technically other types of keys are accepted:

hash = ActiveSupport::HashWithIndifferentAccess.new(a: 1)
hash[0] = 0
hash # => {"a"=>1, 0=>0}

but this class is intended for use cases where strings or symbols are the expected keys and it is convenient to understand both as the same. For example the params hash in Ruby on Rails.

Note that core extensions define Hash#with_indifferent_access:

rgb = { black: '#000000', white: '#FFFFFF' }.with_indifferent_access

which may be handy.

ORIG_ARGV : ARGV.dup
ApplicationController : 10
Conflict : 2
MultipleConstantFile : 10
SiblingConstant : MultipleConstantFile * 2
ShouldNotBeAutoloaded : 0
Payment : Struct.new(:price)
Somewhere : Struct.new(:street, :city) do attr_accessor :name end
Invoice : Struct.new(:client) do delegate :street, :city, :name, :to => :client, :prefix => true delegate :street, :city, :name, :to => :client, :prefix => :customer end
Project : Struct.new(:description, :person) do delegate :name, :to => :person, :allow_nil => true delegate :to_f, :to => :description, :allow_nil => true end
Developer : Struct.new(:client) do delegate :name, :to => :client, :prefix => nil end
Tester : Struct.new(:client) do delegate :name, :to => :client, :prefix => false end

Product : Struct.new(:name) do delegate :name, :to => :manufacturer, :prefix => true delegate :name, :to => :type, :prefix => true def manufacturer @manufacturer ||= begin nil.unknown_method end end def type @type ||= begin nil.type_name end end end

MTIME_FIXTURES_PATH : File.expand_path("../fixtures", __FILE__)
DEFAULT_APP_FILES : %w( .gitignore README.rdoc Gemfile Rakefile config.ru app/assets/javascripts app/assets/stylesheets app/assets/images app/controllers app/controllers/concerns app/helpers app/mailers app/models app/models/concerns app/views/layouts bin/bundle bin/rails bin/rake config/environments config/initializers config/locales db lib lib/tasks lib/assets log test/test_helper.rb test/fixtures test/controllers test/models test/helpers test/mailers test/integration vendor vendor/assets vendor/assets/stylesheets vendor/assets/javascripts tmp/cache tmp/cache/assets )
ObjectHelper : Class.new
AnotherObjectHelperTest : Class.new
DEFAULT_PLUGIN_FILES : %w( .gitignore Gemfile Rakefile README.rdoc bukkits.gemspec MIT-LICENSE lib lib/bukkits.rb lib/tasks/bukkits_tasks.rake lib/bukkits/version.rb test/bukkits_test.rb test/test_helper.rb test/dummy )
RAILS_FRAMEWORK_ROOT : File.expand_path("#{File.dirname(__FILE__)}/../../..")
RAILS_ISOLATED_ENGINE : true
FRAMEWORKS : %w( activesupport activemodel activerecord actionview actionpack actionmailer railties )
test_inheritance_find

test_inheritance_find() Instance Public methods

2015-06-20 00:00:00
test_new_with_ar_base

test_new_with_ar_base() Instance Public methods

2015-06-20 00:00:00
try!

try!(*a, &b) Instance Public methods Same as

2015-06-20 00:00:00
test_alt_find_first_within_inheritance

test_alt_find_first_within_inheritance() Instance Public methods

2015-06-20 00:00:00
test_inheritance_without_mapping

test_inheritance_without_mapping() Instance Public methods

2015-06-20 00:00:00
test_alt_eager_loading

test_alt_eager_loading() Instance Public methods

2015-06-20 00:00:00
instance_variable_names

instance_variable_names() Instance Public methods Returns an array of instance

2015-06-20 00:00:00
test_finding_incorrect_type_data

test_finding_incorrect_type_data() Instance Public methods

2015-06-20 00:00:00
test_alt_finding_incorrect_type_data

test_alt_finding_incorrect_type_data() Instance Public methods

2015-06-20 00:00:00
load_schema

load_schema() Instance Public methods

2015-06-20 00:00:00