Sha256: 740ab63d2a5c174f14b2a3bd85d68639269a98b0109c9cbf70aa568f9328c7e2
Contents?: true
Size: 708 Bytes
Versions: 16
Compression:
Stored size: 708 Bytes
Contents
require 'spec_helper' describe Qbrick::TextBrick, type: :model do let :text_brick do Qbrick::TextBrick.new end describe '#bricks' do it 'can not have childs' do expect(text_brick).not_to respond_to(:bricks) end end describe '#user_can_add_childs?' do it 'returns false' do expect(text_brick.user_can_add_childs?).to be_falsey end end describe '#collect_fulltext' do before do text_brick.text = '<div><b>foo</b> <b>bar</b></div>' text_brick.read_more_text = '<div><span>foo</span><span>bar</span></div>' end it 'sanitizes text and read_more_text' do expect(text_brick.collect_fulltext).to eq('foo bar foobar') end end end
Version data entries
16 entries across 16 versions & 1 rubygems