def test_datetime(self):
    d = self.datetime()
    result = self.loads(json.dumps(d))
    d.pop('__type__')
    self.assertEqual(result, datetime(tzinfo=timezone.utc, **d))
def test_datetime(self):
    d = self.datetime()
    result = self.loads(json.dumps(d))
    d.pop('__type__')
    self.assertEqual(result, datetime(tzinfo=timezone.utc, **d))