[FIX] payment_paypal: external tests
All dates in the backend must be naive (=in utc, without timezone) closes odoo/odoo#36230 Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
This commit is contained in:
@@ -211,7 +211,7 @@ class TxPaypal(models.Model):
|
||||
'PST': -8 * 3600,
|
||||
'PDT': -7 * 3600,
|
||||
}
|
||||
date = dateutil.parser.parse(data.get('payment_date'), tzinfos=tzinfos).astimezone(pytz.utc)
|
||||
date = dateutil.parser.parse(data.get('payment_date'), tzinfos=tzinfos).astimezone(pytz.utc).replace(tzinfo=None)
|
||||
except:
|
||||
date = fields.Datetime.now()
|
||||
res.update(date=date)
|
||||
|
||||
@@ -131,7 +131,7 @@ class PaypalForm(PaypalCommon):
|
||||
'protection_eligibility': u'Ineligible',
|
||||
'last_name': u'Poilu',
|
||||
'txn_id': u'08D73520KX778924N',
|
||||
'receiver_email': self.env.user.email,
|
||||
'receiver_email': 'dummy',
|
||||
'payment_status': u'Pending',
|
||||
'payment_gross': u'',
|
||||
'tax': u'0.00',
|
||||
|
||||
Reference in New Issue
Block a user