Sha256: dd68ad4602a22e68d42e5207a8d0d48ece88c258f5f3925556903a2536a013a0

Contents?: true

Size: 990 Bytes

Versions: 1

Compression:

Stored size: 990 Bytes

Contents

require 'test_helper'
require 'markdo/rss_command'

module Markdo
  describe RssCommand do
    it 'outputs RSS from the input Markdown' do
      out = StringIO.new
      err = StringIO.new
      env = { 'MARKDO_ROOT' => 'test/fixtures' }

      RssCommand.new(out, err, env).run

      out.string.must_equal <<-XML
        <?xml version=\"1.0\" encoding=\"UTF-8\"?>
        <rss>
          <channel>
            <title>Links in Markdo</title>
          <item>
            <title>Task with HTTP URL http://www.example.com/</title>
            <link>http://www.example.com/</link>
          </item>
          <item>
            <title>Task with HTTPS URL https://www.example.com/</title>
            <link>https://www.example.com/</link>
          </item>
          <item>
            <title>Task with HTTP URL http://www.example.com/ and trailing text</title>
            <link>http://www.example.com/</link>
          </item>
          </channel>
        </rss>
      XML
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
markdo-0.1.3 test/rss_command_test.rb