Skip to content

Commit 776275f

Browse files
authored
use latest rocket hash in scaffold_generator.rb
1 parent ed18131 commit 776275f

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

lib/generators/rspec/scaffold/scaffold_generator.rb

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,17 @@ module Generators
77
class ScaffoldGenerator < Base
88
include ::Rails::Generators::ResourceHelpers
99
source_paths << File.expand_path('../helper/templates', __dir__)
10-
argument :attributes, :type => :array, :default => [], :banner => "field:type field:type"
10+
argument :attributes, type: :array, default: [], banner: "field:type field:type"
1111

12-
class_option :orm, :desc => "ORM used to generate the controller"
13-
class_option :template_engine, :desc => "Template engine to generate view files"
14-
class_option :singleton, :type => :boolean, :desc => "Supply to create a singleton controller"
15-
class_option :api, :type => :boolean, :desc => "Skip specs unnecessary for API-only apps"
12+
class_option :orm, desc: "ORM used to generate the controller"
13+
class_option :template_engine, desc: "Template engine to generate view files"
14+
class_option :singleton, type: :boolean, desc: "Supply to create a singleton controller"
15+
class_option :api, type: :boolean, desc: "Skip specs unnecessary for API-only apps"
1616

17-
class_option :controller_specs, :type => :boolean, :default => true, :desc => "Generate controller specs"
18-
class_option :view_specs, :type => :boolean, :default => true, :desc => "Generate view specs"
19-
class_option :helper_specs, :type => :boolean, :default => true, :desc => "Generate helper specs"
20-
class_option :routing_specs, :type => :boolean, :default => true, :desc => "Generate routing specs"
17+
class_option :controller_specs, type: :boolean, default: true, desc: "Generate controller specs"
18+
class_option :view_specs, type: :boolean, default: true, desc: "Generate view specs"
19+
class_option :helper_specs, type: :boolean, default: true, desc: "Generate helper specs"
20+
class_option :routing_specs, type: :boolean, default: true, desc: "Generate routing specs"
2121

2222
def initialize(*args, &blk)
2323
@generator_args = args.first
@@ -60,7 +60,7 @@ def generate_routing_spec
6060
template 'routing_spec.rb', template_file
6161
end
6262

63-
hook_for :integration_tool, :as => :integration
63+
hook_for :integration_tool, as: :integration
6464

6565
protected
6666

0 commit comments

Comments
 (0)