hiccup 0.4.2 → 0.4.3

Sign up to get free protection for your applications and to get access to all the features.
@@ -72,7 +72,7 @@ module Hiccup
72
72
  end
73
73
 
74
74
  def n_occurrences_on_or_before(limit, date)
75
- return nil if date < start_date
75
+ return [] if date < start_date
76
76
 
77
77
  occurrences = []
78
78
  enum = enumerator.new(self, date)
@@ -1,3 +1,3 @@
1
1
  module Hiccup
2
- VERSION = "0.4.2"
2
+ VERSION = "0.4.3"
3
3
  end
@@ -198,8 +198,8 @@ class EnumerableTest < ActiveSupport::TestCase
198
198
  :end_date => Date.new(2011, 1, 31)})
199
199
  assert_equal nil, schedule.first_occurrence_before(Date.new(2011,1,3))
200
200
  assert_equal nil, schedule.first_occurrence_on_or_before(Date.new(2011,1,2))
201
- assert_equal nil, schedule.n_occurrences_before(10, Date.new(2011,1,3))
202
- assert_equal nil, schedule.n_occurrences_on_or_before(10, Date.new(2011,1,2))
201
+ assert_equal [], schedule.n_occurrences_before(10, Date.new(2011,1,3))
202
+ assert_equal [], schedule.n_occurrences_on_or_before(10, Date.new(2011,1,2))
203
203
  end
204
204
 
205
205
  test "should not predict dates after the end of a schedule" do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hiccup
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.2
4
+ version: 0.4.3
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -179,7 +179,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
179
179
  version: '0'
180
180
  segments:
181
181
  - 0
182
- hash: -4462698178818777430
182
+ hash: -936135857702157052
183
183
  required_rubygems_version: !ruby/object:Gem::Requirement
184
184
  none: false
185
185
  requirements:
@@ -188,7 +188,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
188
188
  version: '0'
189
189
  segments:
190
190
  - 0
191
- hash: -4462698178818777430
191
+ hash: -936135857702157052
192
192
  requirements: []
193
193
  rubyforge_project: hiccup
194
194
  rubygems_version: 1.8.24