Sha256: fb9a5deaac0ddb79896ba40ebd1ff348dcc148d3a5c428c0880967719fd6f1ad

Contents?: true

Size: 522 Bytes

Versions: 3

Compression:

Stored size: 522 Bytes

Contents

require 'spec_helper'

describe ReverseMarkdown::Converters do
  before { ReverseMarkdown.config.unknown_tags = :raise }
  let(:converters) { ReverseMarkdown::Converters }

  describe '.register and .unregister' do
    it 'adds a converter mapping to the list' do
      expect { converters.lookup(:foo) }.to raise_error

      converters.register :foo, :foobar
      expect(converters.lookup(:foo)).to eq :foobar

      converters.unregister :foo
      expect { converters.lookup(:foo) }.to raise_error
    end
  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
reverse_markdown-0.8.2 spec/lib/reverse_markdown/converters_spec.rb
reverse_markdown-0.8.1 spec/lib/reverse_markdown/converters_spec.rb
reverse_markdown-0.8.0 spec/lib/reverse_markdown/converters_spec.rb