Class: Cucumber::InstallGenerator
- Inherits:
-
Rails::Generators::Base
- Object
- Rails::Generators::Base
- Cucumber::InstallGenerator
show all
- Includes:
- Generators::InstallBase
- Defined in:
- lib/generators/cucumber/install/install_generator.rb
Constant Summary
collapse
- DEFAULT_SHEBANG =
File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name'])
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
#check_upgrade_limitations, #configure_gemfile, #create_database, #create_feature_support, #create_scripts, #create_step_definitions, #create_tasks, #create_templates, #print_instructions
Instance Attribute Details
#driver ⇒ Object
Returns the value of attribute driver.
19
20
21
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 19
def driver
@driver
end
|
#framework ⇒ Object
Returns the value of attribute framework.
19
20
21
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 19
def framework
@framework
end
|
Class Method Details
.gem_root ⇒ Object
37
38
39
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 37
def self.gem_root
File.expand_path("../../../../../", __FILE__)
end
|
.source_root ⇒ Object
41
42
43
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 41
def self.source_root
File.join(gem_root, 'templates/install')
end
|
Instance Method Details
21
22
23
24
25
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 21
def configure_defaults
@language ||= 'en'
@framework = framework_from_options || detect_current_framework || detect_default_framework
@driver = driver_from_options || detect_current_driver || detect_default_driver
end
|
#cucumber_rails_env ⇒ Object
45
46
47
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 45
def cucumber_rails_env
'test'
end
|
#generate ⇒ Object
27
28
29
30
31
32
33
34
35
|
# File 'lib/generators/cucumber/install/install_generator.rb', line 27
def generate
check_upgrade_limitations
create_templates
create_scripts
create_step_definitions
create_feature_support
create_tasks
create_database unless options[:skip_database]
end
|