Sha256: 265f8c58a5a8f36a3563daac83a2c06330766703cc55e78f93b9c59c8ea3034f

Contents?: true

Size: 822 Bytes

Versions: 4

Compression:

Stored size: 822 Bytes

Contents

require 'test_helper'
require 'markdo/ics_command'

module Markdo
  describe IcsCommand do
    it 'outputs an iCalendar feed from the input Markdown, skipping invalid dates' do
      out = StringIO.new
      err = StringIO.new
      env = { 'MARKDO_ROOT' => 'test/fixtures' }

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

      out.string.must_equal <<-ICS
BEGIN:VCALENDAR
VERSION:2.0
CALSCALE:GREGORIAN
METHOD:PUBLISH
X-WR-CALNAME:Markdo Due Dates
BEGIN:VEVENT
DTSTART;VALUE=DATE:20140401
DTEND;VALUE=DATE:20140401
SUMMARY:Task with long-past due date
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:20160401
DTEND;VALUE=DATE:20160401
SUMMARY:Task with due date
END:VEVENT
BEGIN:VEVENT
DTSTART;VALUE=DATE:20160401
DTEND;VALUE=DATE:20160401
SUMMARY:Task with tag-style due date
END:VEVENT
END:VCALENDAR
      ICS
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
markdo-0.1.12.alpha test/ics_command_test.rb
markdo-0.1.11 test/ics_command_test.rb
markdo-0.1.10 test/ics_command_test.rb
markdo-0.1.9 test/ics_command_test.rb