Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions .Pipelines/template-pipeline-stages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -121,16 +121,15 @@ stages:
--benchmark-skip \
--timeout=120 \
--junitxml=test-results/junit-unit.xml \
--log-file=test-results/pytest-unit.log \
--ignore=tests/test_e2e.py \
--ignore=tests/test_e2e_manual.py \
--ignore=tests/test_fmi_e2e.py \
--deselect tests/test_cryptography.py::CryptographyTestCase::test_ceiling_should_be_latest_cryptography_version_plus_three \
--deselect tests/test_cryptography.py::CryptographyTestCase::test_should_be_run_with_latest_version_of_cryptography \
2>&1 | tee test-results/pytest-unit.log
--deselect tests/test_cryptography.py::CryptographyTestCase::test_should_be_run_with_latest_version_of_cryptography
displayName: 'Run pytest (unit)'
timeoutInMinutes: 5
env:
# Force unbuffered stdout so ADO logs stream in real time through the tee pipe.
PYTHONUNBUFFERED: '1'

# Run cryptography version-gating tests separately as a warning-only check.
Expand Down
4 changes: 2 additions & 2 deletions msal/wstrust_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#------------------------------------------------------------------------------

import uuid
from datetime import datetime, timedelta
from datetime import datetime, timedelta, timezone
import logging

from .mex import Mex
Expand Down Expand Up @@ -76,7 +76,7 @@ def wsu_time_format(datetime_obj):


def _build_rst(username, password, cloud_audience_urn, endpoint_address, soap_action):
now = datetime.utcnow()
now = datetime.now(timezone.utc)
return """<s:Envelope xmlns:s='{s}' xmlns:wsa='{wsa}' xmlns:wsu='{wsu}'>
<s:Header>
<wsa:Action s:mustUnderstand='1'>{soap_action}</wsa:Action>
Expand Down
Loading