Skip to content

Commit

Permalink
testing
Browse files Browse the repository at this point in the history
  • Loading branch information
stephencpope authored Sep 18, 2024
1 parent 981fe87 commit 83aeae6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions descarteslabs/core/common/client/tests/test_attributes.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,10 @@ class TzTest(Document):

now = datetime.utcnow()
doc = TzTest(date=now.isoformat())
print(f"doc {type(doc)} {doc}")
print(f"doc.date {type(doc.date)} {doc.date}")
print(f"doc.date.tzinfo {type(doc.date.tzinfo)} {doc.date.tzinfo}")
print(f"pytz.timezone(MST)" {type(pytz.timezone('MST'))} {pytz.timezone('MST')}")
assert doc.date.tzinfo == pytz.timezone("MST")
assert doc.date.astimezone(tz=timezone.utc) == now.replace(tzinfo=timezone.utc)

Expand Down

0 comments on commit 83aeae6

Please sign in to comment.