require File.join(File.dirname(__FILE__), '..', 'spec_helper') describe HtmlEmailCreator::Formatter do describe "Markdown" do let(:md) { HtmlEmailCreator::Formatters::Markdown.id } it "should convert correctly" do HtmlEmailCreator::Formatter.new("**I am strong**").find(md).format.should eql("
I am strong
") end it "should support table extension" do markdown = <<-eos | First | Second | Third | |:------|:-------|:------| | 1 | 2 | 3 | eos html = <