Пример #1
0
    def create_from_string(cls, string, task_filter):
        dates = DateUtils.date_range_from_string(string)
        weeks = cls.create_array_of_weeks_between_dates(dates[0], dates[1],
                                                        task_filter)

        cls.fetch_tasks_for_all(weeks)

        return weeks
Пример #2
0
 def test_date_range(self):
     dates = DateUtils.date_range_from_string("w11-")
     self.assertEqual(dates[0], DateUtils.date_from_string("w11")[0])
     self.assertEqual(dates[1], datetime.date.today())