search for: haml_tag

Displaying 1 result from an estimated 1 matches for "haml_tag".

Did you mean: yaml_tag
2008 Jul 03
0
Testing HAML in helper rspec
...}.should match(/<div class=''#{name.to_s}''>\s*#{flash[name]}\s*<\/div>/) flash[name]= nil end end ... Which tests this in application_helpers.rb def display_flash for name in [:notice, :warning, :error] if flash[name] haml_tag :div, flash[name], {:class => name.to_s} end end nil end I also updated my blog post on this topic to cover the new syntax... http://blog.wolfman.com/articles/2007/07/14/using-rspec-to-test-haml-helpers -- Jim Morris, http://blog.wolfman.com