Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
devel:languages:python:django
python-django-request
do-not-fail-on-day-one-of-month.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File do-not-fail-on-day-one-of-month.patch of Package python-django-request
Index: django-request-1.6.3/tests/test_managers.py =================================================================== --- django-request-1.6.3.orig/tests/test_managers.py +++ django-request-1.6.3/tests/test_managers.py @@ -66,6 +66,7 @@ class RequestQuerySetTest(TestCase): qs = Request.objects.all().year(self.request.time.year + 1) self.assertEqual(qs.count(), 0) + @override_settings(USE_TZ=True, TIME_ZONE='Africa/Nairobi') def test_month(self): qs = Request.objects.all().month(year=None, month=None, date=now()) self.assertEqual(qs.count(), 1) @@ -78,6 +79,7 @@ class RequestQuerySetTest(TestCase): ) self.assertEqual(qs.count(), 0) + @override_settings(USE_TZ=True, TIME_ZONE='Africa/Nairobi') def test_month_without_date(self): now_month = now().strftime('%b') qs = Request.objects.all().month( @@ -103,7 +105,7 @@ class RequestQuerySetTest(TestCase): def test_month_is_december(self): # setUp - december_time = now().replace(month=12) + december_time = now().replace(month=12, day=15) self.request.time = december_time self.request.save() # Test @@ -112,7 +114,7 @@ class RequestQuerySetTest(TestCase): def test_month_is_not_december(self): # setUp - november_time = now().replace(month=11) + november_time = now().replace(month=11, day=15) self.request.time = november_time self.request.save() # Test
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor