Sha256: f743ff96b3587e2810b665911fc94bc4b49452cb2b5df90c616ee597f8bb5633
Contents?: true
Size: 913 Bytes
Versions: 2
Compression:
Stored size: 913 Bytes
Contents
require 'test_helper' class FlashHelperTest < EaselHelpers::ViewTestCase context "render_flash" do should "default with the correct structure" do show_view %(<%= render_flash(:structure => "Flash message") %>) do assert_select "p.structure.box.single-line", "Flash message" end end should "display all flash messages present" do show_view %(<%= render_flash(:structure => "Flash message", :error => "Warning message") %>) do assert_select "p.structure.box.single-line", "Flash message" assert_select "p.error.box.single-line", "Warning message" end end should "not display a flash if it is blank" do show_view %(<%= render_flash(:structure => "", :error => nil) %>) do assert_select "p.structure.box.single-line", false assert_select "p.error.box.single-line", false end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
fusionary-easel_helpers-0.2.2 | test/flash_helper_test.rb |
fusionary-easel_helpers-0.2.4 | test/flash_helper_test.rb |