Class: RspecGenerator

Inherits:
Generator
  • Object
show all
Defined in:
lib/generators/rspec/rspec_generator.rb

Instance Method Summary collapse

Methods inherited from Generator

#android?, #args, #axe?, #cross_platform?, #cucumber?, #ios?, #mobile?, #rspec?, #selenium?, #selenium_based?, #single_platform?, source_paths, #visual?, #watir?, #web?

Instance Method Details

#generate_account_specObject



18
19
20
21
22
# File 'lib/generators/rspec/rspec_generator.rb', line 18

def 
  return unless visual?

  template('spec.tt', "#{name}/spec/account_page_spec.rb")
end

#generate_login_specObject



6
7
8
9
10
# File 'lib/generators/rspec/rspec_generator.rb', line 6

def 
  return unless web? && !visual?

  template('spec.tt', "#{name}/spec/login_page_spec.rb")
end

#generate_pdp_specObject



12
13
14
15
16
# File 'lib/generators/rspec/rspec_generator.rb', line 12

def generate_pdp_spec
  return unless mobile?

  template('spec.tt', "#{name}/spec/pdp_page_spec.rb")
end