Method: ArtifactFile::Matcher::Helper#handle_view

Defined in:
lib/rails_app_spec/matchers/artifact/shared/artifact_file_helper.rb

#handle_view(artifact_type, names) ⇒ Object



22
23
24
25
26
27
28
29
# File 'lib/rails_app_spec/matchers/artifact/shared/artifact_file_helper.rb', line 22

def handle_view artifact_type, names
  if artifact_type == :view
    lang_option = last_arg({:lang => 'erb.html'}, names)
    raise ArgumentException, ':folder option must be specified in the last hash argument for #have_views' if !lang_option[:folder]          
    @folder = lang_option[:folder]
    @view_ext = get_view_ext(lang_option[:lang] || :erb)        
  end
end