Code review comment for lp:~pkunal-parmar/ubuntu-calendar-app/today

Revision history for this message
Kunal Parmar (pkunal-parmar) wrote :

> 165 + if goToNextMonth is True:
> 166 + self.assertThat(dayAfterMonthChange.month,
> 167 + (Equals(startDay.month + count)))
> 168 + else:
> 169 + self.assertThat(dayAfterMonthChange.month,
> 170 + (Equals(startDay.month - count)))
>
> This currently works because we’re in July, but when you run the tests in
> December they’re gonna start failing because 12 + n > 12 (for n being an
> integer > 0).
> If you want to see it for yourself without changing your current date, add the
> following test:
>
> def test_monthview_change_month_fail(self):
> self.test_monthview_change_month(True, 9)

ok, not only month it also affect year, I fixed that as well. Now I am not trying to calculate month by arithmetic but by using python-dateutil.

testDate = startDay + relativedelta( months = +count )

I added dependency for python-dateutil under Package: calendar-app-autopilot, is that correct ?

I also added dependency

« Back to merge proposal