Sha256: 92c8aac34718fde72fcd2decd3f8bdcbf30c10892c29087a5efe33e82aa6dd98
Contents?: true
Size: 601 Bytes
Versions: 28
Compression:
Stored size: 601 Bytes
Contents
require 'spec_helper' describe 'alchemy/essences/_essence_html_view' do let(:essence) { Alchemy::EssenceHtml.new(source: '<script>alert("hacked");</script>') } let(:content) { Alchemy::Content.new(essence: essence) } context 'without value' do let(:essence) { Alchemy::EssenceHtml.new(source: nil) } it "renders nothing" do render content, content: content expect(rendered).to eq('') end end context 'with value' do it "renders the raw html source" do render content, content: content expect(rendered).to have_selector("script") end end end
Version data entries
28 entries across 28 versions & 2 rubygems