Top Level Namespace

Includes:
FileUtils, Java

Defined Under Namespace

Modules: AbstractController, ActionController, ActionDispatch, ActionMailer, ActionPack, ActionView, ActiveModel, ActiveRecord, ActiveResource, ActiveSupport, ArJdbcMySQL, Css, Enumerable, Erb, HTML, I18n, Js, Kernel, LibXML, Mime, Process, Prof, QualifiedConstUtils, REXML, Rack, Rails, Sprockets, TestUnit, URI Classes: Array, Benchmark, BenchmarkerTest, BigDecimal, Class, CodeStatistics, Date, DateTime, ERB, FalseClass, File, FixtureClassNotFound, Float, Hash, IO, Integer, LoadError, Logger, Module, Mysql, NameError, NilClass, Numeric, Object, Plugin, Proc, ProfilerTest, RailsEnvironment, Range, RecursiveHTTPFetcher, Regexp, SourceAnnotationExtractor, String, Struct, Symbol, Time, TrueClass

Constant Summary collapse

MissingSourceFile =
LoadError
HashWithIndifferentAccess =
ActiveSupport::HashWithIndifferentAccess

Instance Method Summary collapse

Instance Method Details

#create_fixtures(*table_names, &block) ⇒ Object



41
42
43
# File 'railties/lib/rails/test_help.rb', line 41

def create_fixtures(*table_names, &block)
  Fixtures.create_fixtures(ActiveSupport::TestCase.fixture_path, table_names, {}, &block)
end

#optionsObject



6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# File 'railties/lib/rails/commands/profiler.rb', line 6

def options
  options = {}
  defaults = ActiveSupport::Testing::Performance::DEFAULTS

  OptionParser.new do |opt|
    opt.banner = "Usage: rails benchmarker 'Ruby.code' 'Ruby.more_code' ... [OPTS]"
    opt.on('-r', '--runs N', Numeric, 'Number of runs.', "Default: #{defaults[:runs]}") { |r| options[:runs] = r }
    opt.on('-o', '--output PATH', String, 'Directory to use when writing the results.', "Default: #{defaults[:output]}") { |o| options[:output] = o }
    opt.on('-m', '--metrics a,b,c', Array, 'Metrics to use.', "Default: #{defaults[:metrics].join(",")}") { |m| options[:metrics] = m.map(&:to_sym) }
    opt.on('-f', '--formats x,y,z', Array, 'Formats to output to.', "Default: #{defaults[:formats].join(",")}") { |m| options[:formats] = m.map(&:to_sym) }
    opt.parse!(ARGV)
  end

  options
end