Class: RSpec::Swag::ProjectInitializer
- Inherits:
-
Object
- Object
- RSpec::Swag::ProjectInitializer
- Defined in:
- lib/rspec/swag/project_initializer.rb
Instance Attribute Summary collapse
-
#destination ⇒ Object
readonly
Returns the value of attribute destination.
-
#source ⇒ Object
readonly
Returns the value of attribute source.
Instance Method Summary collapse
-
#initialize ⇒ ProjectInitializer
constructor
A new instance of ProjectInitializer.
- #run ⇒ Object
Constructor Details
#initialize ⇒ ProjectInitializer
Returns a new instance of ProjectInitializer.
10 11 12 13 |
# File 'lib/rspec/swag/project_initializer.rb', line 10 def initialize @destination = Dir.pwd @source = File.("templates", __dir__) end |
Instance Attribute Details
#destination ⇒ Object (readonly)
Returns the value of attribute destination.
8 9 10 |
# File 'lib/rspec/swag/project_initializer.rb', line 8 def destination @destination end |
#source ⇒ Object (readonly)
Returns the value of attribute source.
8 9 10 |
# File 'lib/rspec/swag/project_initializer.rb', line 8 def source @source end |
Instance Method Details
#run ⇒ Object
15 16 17 |
# File 'lib/rspec/swag/project_initializer.rb', line 15 def run copy_template "spec/swagger_helper.rb" end |