move recurrence text helpers into patterns. move next_date calculation into

respective models
This commit is contained in:
Reinier Balt 2014-02-27 16:01:01 +01:00
parent d8507bf8b7
commit b84adfc172
13 changed files with 291 additions and 289 deletions

View file

@ -64,6 +64,16 @@ module RecurringTodos
assert !rt.valid?, "should not be valid since day_of_week is empty"
end
def test_pattern_text
rt = recurring_todos(:birthday_reinier)
assert_equal "every year on June 08", rt.recurrence_pattern
rt.recurrence_selector = 1
rt.every_count = 3
rt.every_other3 = 3
assert_equal "every year on the third wednesday of June", rt.recurrence_pattern
end
end
end