mirror of
https://gitea.publichub.eu/oscar.krause/fastapi-dls.git
synced 2025-11-02 09:46:04 +00:00
moved from deprecated "datetime.utcnow()" to "datetime.now(UTC)"
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import sys
|
||||
from base64 import b64encode as b64enc
|
||||
from calendar import timegm
|
||||
from datetime import datetime
|
||||
from datetime import datetime, UTC
|
||||
from hashlib import sha256
|
||||
from os.path import dirname, join
|
||||
from uuid import uuid4, UUID
|
||||
@@ -142,7 +142,7 @@ def test_auth_v1_code():
|
||||
|
||||
|
||||
def test_auth_v1_token():
|
||||
cur_time = datetime.utcnow()
|
||||
cur_time = datetime.now(UTC)
|
||||
access_expires_on = cur_time + relativedelta(hours=1)
|
||||
|
||||
payload = {
|
||||
|
||||
Reference in New Issue
Block a user