mirror of
https://github.com/django-helpdesk/django-helpdesk.git
synced 2025-06-20 01:27:44 +02:00
Accommodate "Z" being appended to a datetime string in certain
environments.
This commit is contained in:
parent
4067abb07e
commit
27857149de
@ -293,7 +293,8 @@ class TicketTest(APITestCase):
|
|||||||
self.assertEqual(response.status_code, HTTP_201_CREATED)
|
self.assertEqual(response.status_code, HTTP_201_CREATED)
|
||||||
# Check all fields with data returned from the response
|
# Check all fields with data returned from the response
|
||||||
self.maxDiff = None
|
self.maxDiff = None
|
||||||
# followup_set = response.data.pop("followup_set")
|
# The date string generated sometimes has a "Z" appended so until they why is figured out...
|
||||||
|
date_suffix_hack = "Z" if response.data["followup_set"][0]["date"].endswith("Z") else ""
|
||||||
self.assertDictEqual(
|
self.assertDictEqual(
|
||||||
response.data,
|
response.data,
|
||||||
{
|
{
|
||||||
@ -320,7 +321,7 @@ class TicketTest(APITestCase):
|
|||||||
"new_status": None,
|
"new_status": None,
|
||||||
"time_spent": None,
|
"time_spent": None,
|
||||||
"followupattachment_set": [],
|
"followupattachment_set": [],
|
||||||
"date": frozen_date_time_str,
|
"date": frozen_date_time_str + date_suffix_hack,
|
||||||
"message_id": None,
|
"message_id": None,
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
Loading…
x
Reference in New Issue
Block a user