Sha256: 6f483d96a0c33b6e32874598c454424a947ba3dd89e1b7909ddaa590f3e0ab45

Contents?: true

Size: 331 Bytes

Versions: 3

Compression:

Stored size: 331 Bytes

Contents

module Helpers
  def example_event(ics_name)
    ics_path = File.expand_path "#{File.dirname(__FILE__)}/fixtures/#{ics_name}_event.ics"
    ics_string = File.read(ics_path)
    calendars = Icalendar::Calendar.parse(ics_string)
    Array(calendars).first.events.first
  end
end

class Integer
  def days
    self*60*60*24
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
icalendar-recurrence-1.2.0 spec/support/helpers.rb
icalendar-recurrence-1.1.3 spec/support/helpers.rb
icalendar-recurrence-1.1.2 spec/support/helpers.rb