icalendar 1.1.2 → 1.1.3

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,3 +1,8 @@
1
+ === 1.1.3 2010-03-15
2
+ * Revert component sorting behavior that I was trying to make
3
+ the tests run more consistantly on different platforms.
4
+ * Added new test for multiple events in a calendar which caught that break.
5
+
1
6
  === 1.1.2 2010-03-10
2
7
 
3
8
  * Convert project to newgem to make for easier publishing
@@ -9,7 +9,7 @@ require 'logger'
9
9
 
10
10
  module Icalendar #:nodoc:
11
11
 
12
- VERSION = '1.1.2'
12
+ VERSION = '1.1.3'
13
13
 
14
14
  # A simple error class to differentiate iCalendar library exceptions
15
15
  # from ruby language exceptions or others.
@@ -103,8 +103,8 @@ module Icalendar
103
103
  def to_ical
104
104
  print_component do
105
105
  s = ""
106
- @components.sort.each do |key, comps|
107
- comps.sort.each { |component| s << component.to_ical }
106
+ @components.each do |key, comps|
107
+ comps.each { |component| s << component.to_ical }
108
108
  end
109
109
  s
110
110
  end
@@ -39,7 +39,10 @@ class TestTimezone < Test::Unit::TestCase
39
39
  timezone.add(standard)
40
40
  timezone.add(daylight)
41
41
  @cal.add(timezone)
42
- assert_equal(@testTimezone, @cal.timezones.first.to_ical)
42
+
43
+ array1 = @testTimezone.split("\r\n").sort
44
+ array2 = @cal.timezones.first.to_ical.split("\r\n").sort
45
+ assert_equal(array1, array2)
43
46
  end
44
47
 
45
48
  def test_block_creation
@@ -43,6 +43,23 @@ class TestCalendar < Test::Unit::TestCase
43
43
  end
44
44
  end
45
45
 
46
+ def test_create_multiple_event_calendar
47
+ # Create a fresh calendar
48
+ cal = Calendar.new
49
+ [1,2,3].each do |t|
50
+ cal.event do
51
+ self.dtend = "1997090#{t}T190000Z"
52
+ self.summary = "This is summary #{t}"
53
+ end
54
+ end
55
+ [1,2,3].each do |t|
56
+ cal.todo do
57
+ self.summary = "test #{t} todo"
58
+ end
59
+ end
60
+ cal.to_ical
61
+ end
62
+
46
63
  def test_find
47
64
  cal = Calendar.new
48
65
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: icalendar
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Dague
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2010-03-10 00:00:00 -05:00
12
+ date: 2010-03-15 00:00:00 -04:00
13
13
  default_executable:
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency