提交 d761eab4 编写于 作者: A AvnerCohen

Moving code base to 1.9 hash syntax

上级 b8dafa31
......@@ -61,7 +61,7 @@ def self.hide!
#
# module Rails::Generators
# class ControllerGenerator < Base
# hook_for :test_framework, :aliases => "-t"
# hook_for :test_framework, aliases: "-t"
# end
# end
#
......@@ -102,7 +102,7 @@ def self.hide!
# :as option:
#
# class AwesomeGenerator < Rails::Generators::Base
# hook_for :test_framework, :as => :controller
# hook_for :test_framework, as: :controller
# end
#
# And now it will lookup at:
......@@ -113,7 +113,7 @@ def self.hide!
# need to provide the :base value:
#
# class AwesomeGenerator < Rails::Generators::Base
# hook_for :test_framework, :in => :rails, :as => :controller
# hook_for :test_framework, in: :rails, as: :controller
# end
#
# And the lookup is exactly the same as previously:
......@@ -137,7 +137,7 @@ def self.hide!
# developers might want to have webrat available on controller generator.
# This can be achieved as:
#
# Rails::Generators::ControllerGenerator.hook_for :webrat, :type => :boolean
# Rails::Generators::ControllerGenerator.hook_for :webrat, type: :boolean
#
# Then, if you want webrat to be invoked, just supply:
#
......
......@@ -169,7 +169,7 @@ def pluralize_table_names?
#
# ==== Examples
#
# check_class_collision :suffix => "Observer"
# check_class_collision suffix: "Observer"
#
# If the generator is invoked with class name Admin, it will check for
# the presence of "AdminObserver".
......
......@@ -3,8 +3,8 @@
class <%= class_name %>Test < ActionDispatch::PerformanceTest
# Refer to the documentation for all available options
# self.profile_options = { :runs => 5, :metrics => [:wall_time, :memory],
# :output => 'tmp/performance', :formats => [:flat] }
# self.profile_options = { runs: 5, metrics: [:wall_time, :memory],
# output: 'tmp/performance', formats: [:flat] }
test "homepage" do
get '/'
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册