Sha256: 3aa5772af727cb94ce4283997d79f396da2301e4541fdc0634e8366fd68ae2bd

Contents?: true

Size: 574 Bytes

Versions: 10

Compression:

Stored size: 574 Bytes

Contents

require "spec_helper"

module BitCore
  describe Slide do
    fixtures :"bit_core/slideshows", :"bit_core/slides"

    describe "#render_body" do
      it "should render a nil body" do
        expect(subject.render_body).to eq("")
      end

      it "should render markdown as html" do
        subject.body = "# header"

        expect(subject.render_body).to match(/<h1>header<\/h1>/)
      end

      it "should escape html" do
        subject.body = "<div>my content</div>"

        expect(subject.render_body).to match(/<p>my content<\/p>/)
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
bit_core-1.2.2 spec/models/bit_core/slide_spec.rb
bit_core-1.2.1 spec/models/bit_core/slide_spec.rb
bit_core-1.2.0 spec/models/bit_core/slide_spec.rb
bit_core-1.1.6 spec/models/bit_core/slide_spec.rb
bit_core-1.1.5 spec/models/bit_core/slide_spec.rb
bit_core-1.1.4 spec/models/bit_core/slide_spec.rb
bit_core-1.1.3 spec/models/bit_core/slide_spec.rb
bit_core-1.1.2 spec/models/bit_core/slide_spec.rb
bit_core-1.1.1 spec/models/bit_core/slide_spec.rb
bit_core-1.1.0 spec/models/bit_core/slide_spec.rb