Class: Atrium::ServiceGenerator
- Inherits:
-
Rails::Generators::NamedBase
- Object
- Rails::Generators::NamedBase
- Atrium::ServiceGenerator
- Defined in:
- lib/generators/atrium/service/service_generator.rb
Instance Method Summary collapse
Instance Method Details
#create_service ⇒ Object
4 5 6 7 8 9 |
# File 'lib/generators/atrium/service/service_generator.rb', line 4 def create_service template( 'service.rb.erb', File.join('app/services/', "#{file_name}.rb") ) end |
#create_service_spec ⇒ Object
10 11 12 13 14 15 |
# File 'lib/generators/atrium/service/service_generator.rb', line 10 def create_service_spec template( 'service_spec.rb.erb', File.join('spec/services/', "#{file_name}_spec.rb") ) end |